Server and control method applied to server

Through the dual-node architecture and network synchronization mechanism, the complex problem of multiple SSD management is solved, the access performance and data availability of the AFA server are improved, and efficient data management and failover are achieved.

CN113342261BActive Publication Date: 2024-10-25SILICON MOTION INC
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202110226132.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Priority Date
2021-01-20
Filing Date
2021-03-01
Publication Date
2024-10-25
Estimated Expiration
2041-03-01

Smart Images

  • Figure CN113342261B_ABST
    Figure CN113342261B_ABST
Patent Text Reader

Abstract

The present invention relates to a server and a control method for the server. The server comprises a solid state drive, a first node and a second node, wherein the first node comprises a first processor and a first memory, and the second node comprises a second processor and a second memory. When the first processor receives data from other devices via a network, the first processor stores the data in the first memory and further sends the data to the second node. When the second processor receives the data from the first node, the second processor stores the data in the second memory and further sends a notification to the first node to report that the data has been successfully stored in the second memory. Only after the first processor receives the notification, the first processor starts to write the data into the solid state drive.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to memory control, and more particularly to a method for executing data access management of an All Flash Array (AFA) server and related apparatus such as an AFA server and a control circuit thereof. Background Art

[0002] A data storage server may be configured to store user data of one or more users, and various control methods for data storage servers have been proposed in the prior art to provide users with a good user experience. Since non-volatile (NV) memory such as flash memory has been widely used in various data storage devices such as solid state drives (SSDs), the prior art has proposed to implement a data storage server using a non-volatile memory as its storage medium, such as an AFA server in which multiple SSDs are installed. However, some problems may arise. For example, the management of accessing the flash memory of any of the multiple SSDs may be complicated. In order to ensure that the access control of the flash memory in this SSD complies with relevant specifications, the controller of the flash memory in this SSD is usually equipped with certain management mechanisms to properly manage its internal operations. Although SSD manufacturers may try to make SSDs look like a good solution to replace hard disk drives (HDDs), some characteristics of SSDs are completely different from HDDs. As a result, the above control method may become inappropriate or ineffective for an AFA server equipped with multiple SSDs, thereby causing the overall performance of the AFA server to decrease. Therefore, it is necessary to provide a novel method and related architecture to solve these problems without or with less side effects. Summary of the invention

[0003] An object of the present invention is to provide a control method for a server to solve the above-mentioned problem.

[0004] An embodiment of the present invention discloses a solid state drive (SSD) drive, SSD), a first node and a second node server, the first node includes a first network module for communicating with another electronic device via a network, a first processor, a first memory and a first communication circuit coupled to the first processor and the first memory, the second node includes a second network module for communicating with the other electronic device via a network, a second processor, a second memory and a second communication circuit coupled to the second processor, the second memory and the first communication circuit, when the first processor receives a data from the other electronic device via the first network module, the first processor stores the data in the first memory, and the first processor further sends the data to the second node; when the second processor receives the data from the first node via the second communication circuit, the second processor stores the data in the second memory, and the second processor further sends a notification to the first node to report that the data has been successfully stored in the second memory; and only after the first processor receives the notification from the second node, the first processor starts to write the data to the solid state drive.

[0005] An embodiment of the present invention discloses a control method applied to a server, comprising: setting a first node in the server as a master device; setting a second node in the server as a slave device; controlling the first node to receive data from another electronic device via a network; storing the data in a first memory in the first node; sending the data from the first node to the second node; storing the data in a second memory in the second node, and the second node sending a notification to the first node to report that the data has been successfully stored in the second memory; and starting to write the data to a solid state drive (SSD) only after the first processor receives the notification from the second node. BRIEF DESCRIPTION OF THE DRAWINGS

[0006] Figure 1 FIG. 4 is a schematic diagram of an all flash array (AFA) server according to an embodiment of the present invention.

[0007] Figure 2 According to one embodiment of the present invention, Figure 1 A schematic diagram of some implementation details of the AFA server is shown.

[0008] Figure 3 According to an embodiment of the present invention, Figure 1 A schematic diagram of a dual-node architecture of the AFA server is shown.

[0009] Figure 4 According to an embodiment of the present invention, Figure 1 A schematic diagram of certain program modules in any one of the multiple nodes shown.

[0010] Figure 5 is a flow chart of a write control scheme for executing an AFA server according to an embodiment of the present invention.

[0011] Figure 6 is a schematic diagram of a cache mirroring mechanism for executing an AFA server according to an embodiment of the present invention.

[0012]

Explanation of symbols

[0013] 10A, 10B: Top-of-rack switches

[0014] 12A, 12B: Solid State Drive Group

[0015] 100: All Flash Memory Array Server

[0016] 100A, 100B: Node

[0017] 100S: Solid State Drive

[0018] 100R: Backplane circuit

[0019] 110A, 110B: Processor

[0020] 112: Program module

[0021] 112A, 112B: Program module

[0022] 120A, 120B: Dynamic Random Access Memory

[0023] 122A, 122B: Copy to flash memory solid state drive

[0024] 130A, 130B: Network interface module

[0025] 132A, 132B, 134A, 134B: Network interface circuit

[0026] 140A, 140B: Non-transparent bridge communication circuit

[0027] 150A,150B: Motherboard Management Controller

[0028] 152A, 152B: Register circuit

[0029] 160A, 160B: Storage interface module

[0030] 162A, 162B, 164A, 164B: Storage interface circuit

[0031] 170A,170B: Backup power supply unit

[0032] 610A,610B:Table

[0033] 500,502,504,506,508,510,512,514: Steps DETAILED DESCRIPTION

[0034] Figure 11 is a schematic diagram of an All Flash Array (AFA) server 100 according to an embodiment of the present invention. The AFA server 100 may include a plurality of nodes, such as two nodes, namely, a node 100A and a node 100B, wherein any one of the plurality of nodes (e.g., one of the node 100A and the node 100B) may have the same or similar architecture as another one of the plurality of nodes (e.g., another one of the node 100A and the node 100B). For example, the node 100A may include at least one processor (e.g., one or more processors such as one or more central processing units (CPUs)) that may be collectively referred to as a processor 110A, and may include a dynamic random access memory (DRAM) 120A, a copy-to-Flash (C2F) solid state drive (SSD) 122A, a network interface (IF) module 130A including one or more network interface (IF) circuits such as network interface circuits 132A and 134A (respectively labeled as “network IF CKT” for simplicity), a non-transparent bridge (NTB) module (or NTB) such as an NTB communication circuit 140A (labeled as “NTB CKT” for simplicity), and a board management controller (BMC). The node 100A includes a memory controller (BMC) 150A, a register circuit 152A (labeled as "REG CKT" for simplicity) coupled to the BMC 150A, a storage interface (IF) module 160A including one or more storage interface circuits such as storage interface circuits 162A and 164A (labeled as "Storage IF CKT" for simplicity) and a backup power supply such as a backup power supply unit 170A (e.g., a battery), wherein at least a portion (e.g., a portion or all) of these components can be coupled to each other via a bus of the node 100A, but the present invention is not limited thereto. According to some embodiments, the architecture of the node 100A can be varied in different ways.

[0035] Similarly, the node 100B may include at least one processor (e.g., one or more processors such as one or more CPUs) which may be collectively referred to as a processor 110B, and may include a DRAM 120B, a C2F SSD 122B, a network interface (IF) module 130B including one or more network interface (IF) circuits such as network interface circuits 132B and 134B (respectively labeled as “Network IF CKT” for simplicity), an NTB module (or NTB) such as an NTB communication circuit 140B labeled as “NTBCKT” for simplicity), a BMC 150B, a register circuit 152B (labeled as “Register CKT” for simplicity) coupled to the BMC 150B, a storage interface (IF) module 160B including one or more storage interface circuits such as storage interface circuits 162B and 164B (respectively labeled as “Storage IF CKT" for simplicity) and a backup power source such as a backup power source unit 170B (e.g., a battery), wherein at least a portion (e.g., a portion or all) of these components can be coupled to each other via a bus of the node 100B, but the present invention is not limited thereto. According to certain embodiments, the architecture of the node 100B can be varied differently.

[0036] like Figure 1 As shown, the AFA server 100 may further include a plurality of SSDs coupled to the nodes 100A and 100B, such as an SSD group 12A and an SSD group 12B, the SSD groups 12A and 12B may be coupled to the nodes 100A and 100B, and may be preset to be connected / linked to the nodes 100A and 100B, respectively, wherein the dotted lines between the nodes 100A and 100B and the SSD groups 12B and 12A may indicate a plurality of optional connections. For example, the node 100A may use the storage interface module 160A to activate the connection between the storage interface circuit 164A and the SSD group 12A to access data in the SSD group 12A, and the node 100B may use the storage interface module 160B to activate the connection between the storage interface circuit 164B and the SSD group 12B to further access data in the SSD group 12B. When necessary, the connection relationship between nodes 100A and 100B and SSD groups 12A and 12B can be changed. For example, node 100A can use storage interface module 160A to start the connection between storage interface circuit 162A and SSD group 12B to access data in SSD group 12B, and node 100B can use storage interface module 160B to start the connection between storage interface circuit 162B and SSD group 12A to access data in SSD group 12A.

[0037] The processor 110A running the program module 112A can be used to control the operation of the node 100A. The DRAM 120A can be used to buffer data (e.g., data to be written to the SSD group 12A), and the C2F SSD 122A can be used to copy the buffered data (referred to as "buffered data") in the DRAM 120A to the flash memory in the C2F SSD 122A to prevent data loss of the buffered data when necessary. For example, the C2F SSD 122A can be implemented by an expansion card such as an M.2 module (e.g., a circuit board with a connector that complies with the M.2 specification) installed on a main circuit board (e.g., a motherboard or a motherboard) in the node 100A, wherein the C2F SSD 122A can include a storage controller, one or more flash memory chips, etc., but the present invention is not limited thereto. In addition, the network interface module 130A including the network interface circuits 132A and 134A can be used to couple the node 100A (e.g., the processor 110A on the main circuit board, the DRAM 120A, etc.) to at least one network (e.g., a local area network (LAN), a wide area network (WAN), the Internet, etc.) through at least one network switch such as a top-of-rack (TOR) switch 10A and 10B. In addition, the storage interface module 160A including the storage interface circuits 162A and 164A can be used to couple the node 100A (e.g., the processor 110A on the main circuit board, the DRAM 120A, etc.) to multiple flash storage devices (e.g., SSD groups 12A and 12B shared by the nodes 100A and 100B) to access (e.g., read or write) data in the multiple flash storage devices. In this way, the AFA server 100 can be used to provide user storage services through the node 100A.

[0038] Similarly, the processor 110B running the program module 112B can be used to control the operation of the node 100B. The DRAM 120B can be used to buffer data (e.g., data to be written to the SSD group 12B), and the C2F SSD 122B can be used to copy the buffered data in the DRAM 120B (referred to as "buffered data") to the flash memory in the C2F SSD 122B to prevent the data loss of the buffered data when necessary. For example, the C2F SSD 122B can be implemented by an expansion card such as an M.2 module (e.g., a circuit board with a connector that complies with the M.2 specification) installed on a main circuit board (e.g., a motherboard or a motherboard) in the node 100B, wherein the C2F SSD 122B can include a storage controller, one or more flash memory chips, etc., but the present invention is not limited thereto. In addition, the network interface module 130B including network circuits 132B and 134B can be used to couple the node 100B (e.g., the processor 110B on the main circuit board, DRAM 120B, etc.) to at least one network (e.g., LAN, WAN, Internet, etc.) through at least one network switch such as TOR switches 10A and 10B. In addition, the storage interface module 160B including storage interface circuits 162B and 164B can be used to couple the node 100B (e.g., the processor 110B on the main circuit board, DRAM 120B, etc.) to multiple flash storage devices (e.g., SSD groups 12A and 12B shared by nodes 100A and 100B) to access (e.g., read or write) data in the multiple flash storage devices. In this way, the AFA server 100 can be used to provide user storage services through the node 100B.

[0039] Regarding the communication between the node 100A and its peer node (e.g., the node 100B), the NTB module (e.g., the NTB communication circuit 140A) can be used to communicate with the corresponding NTB module (e.g., the NTB communication circuit 140B) through an NTB path (labeled as "NTB" for simplicity) between the nodes 100A and 100B, so as to synchronize the data and storage states of the nodes 100A and 100B, and further make them the same. Similarly, regarding the communication between the node 100B and its peer node (e.g., the node 100A), the NTB module (e.g., the NTB communication circuit 140B) can be used to communicate with the corresponding NTB module (e.g., the NTB communication circuit 140A) through the NTB path (labeled as "NTB" for simplicity) between the nodes 100A and 100B, so as to synchronize the data and storage states of the nodes 100A and 100B, and further make them the same. In particular, the NTB modules such as the NTB communication circuits 140A and 140B can provide a function of a transmission bridge between the nodes 100A and 100B and separate the respective address domains of the nodes 100A and 100B so that the nodes 100A and 100B have independent address domains from each other, so as to provide / enhance the communication between the nodes 100A and 100B without any address conflict. For example, the respective buses of the nodes 100A and 100B can comply with the Peripheral Component Interconnect Express (PCIe) standard, and the NTB module of each of the nodes 100A and 100B can be considered as an endpoint of the node, wherein the nodes 100A and 100B can communicate with each other and share devices through the transmission bridge, but the present invention is not limited thereto. According to some embodiments, NTB modules such as NTB communication circuits 140A and 140B may be implemented through a customized network interface circuit to control nodes 100A and 100B to communicate with each other as if they are communicating through the network interface circuit.

[0040] Under the control of processor 110A running program module 112A and processor 110B running program module 112B, nodes 100A and 100B may maintain and monitor the pulse on the NTB to determine the availability of peer nodes for high availability (HA) control. For example, node 100B may be used to send a pulse signal to node 100A, and node 100A may be used to detect and monitor the pulse signal from node 100B to determine the availability of node 100B, wherein the presence or absence of the pulse signal from node 100B may indicate whether node 100B is available (or healthy). For another example, node 100A may be used to send a pulse signal to node 100B, and node 100B may be used to detect and monitor the pulse signal from node 100A to determine the availability of node 100A, wherein the presence or absence of the pulse signal from node 100A may indicate whether node 100A is available (or healthy). Based on Figure 1 The architecture shown, Figure 1 As shown, when one of the nodes 100A and 100B is unavailable, the other one of the nodes 100A and 100B can continue to provide the storage service of the AFA server 100 to the user.

[0041] It should be noted that the AFA server 100 is equipped with more than one inter-node communication path (e.g., more than one inter-communication path between nodes). In addition to the NTB path, the AFA server 100 may also be configured to have one or more other communication paths, such as a BMC path between BMCs 150A and 150B, wherein BMC 150A may be used to manage at least a portion (e.g., a portion or all) of the hardware layer of node 100A, and BMC 150B may be used to manage at least a portion (e.g., a portion or all) of the hardware layer of node 100B. With respect to communication between node 100A and its peer node (e.g., node 100B), BMC 150A may be used to communicate with BMC 150B via the BMC path to access (e.g., read or write) one or more register values ​​of one or more registers in register circuit 152B to perform status check operations on node 100B, etc. Similarly, with respect to communication between the node 100B and its peer node (e.g., the node 100A), the BMC 150B may be used to communicate with the BMC 150A via the BMC path to access (e.g., read or write) one or more register values ​​of one or more registers in the register circuit 152A to perform status check operations on the node 100A, etc. In particular, the BMC 150A and the BMC 150B may independently manage the respective hardware layers of the nodes 100A and 100B without relying on the processors 110A and 110B. For example, when the processor 110A fails, the BMC 150A may process the unfinished work of the node 100A, and when the processor 110B fails, the BMC 150B may process the unfinished work of the node 100B, but the present invention is not limited thereto. According to some embodiments, BMCs 150A and 150B may be used to take over nodes 100A and 100B, respectively, to perform emergency processing operations to reduce the probability of data loss.

[0042] According to this embodiment, the AFA server 100 can be configured to be powered by multiple types of power supplies. Each of the nodes 100A and 100B can include at least one main power supply (e.g., at least one power supply) for providing power to other components of the node when the main power supply is in a normal power supply state. For example, the main power supply of the node 100A can supply power to the main circuit board of the node 100A, and the main power supply of the node 100B can supply power to the main circuit board of the node 100B. When an abnormal power supply condition of one or more nodes (e.g., the node 100A and / or the node 100B) is detected, one or more related backup power supplies (e.g., the backup power supply unit 170A and / or the backup power supply unit 170B) in the AFA server 100 can be used to provide backup power. For example, when a power failure occurs in the main power supply of node 100A, the backup power supply unit 170A can supply power to the main circuit board of node 100A (for example, processor 110A, DRAM 120A, C2F SSD 122A, NTB communication circuit 140A, BMC150A, register circuit 152A, etc.); when a power failure occurs in the main power supply of node 100B, the backup power supply unit 170B can supply power to the main circuit board of node 100B (for example, processor 110B, DRAM 120B, C2F SSD 122B, NTB communication circuit 140B, BMC150B, register circuit 152B, etc.).

[0043] According to some embodiments, each node of the nodes 100A and 100B (e.g., each node in the respective main circuit boards of the nodes 100A and 100B) may further include a plurality of sensors / detectors for detecting at least the components of the node to generate detection results (e.g., status information obtained from any one of the sensors / detectors). For example, a power detection result among the detection results may indicate the power status of the main power supply of the node, and in particular, may indicate whether an abnormal power supply condition occurs at the node, so as to trigger the node to start a backup power supply (e.g., backup power supply unit 170A or backup power supply unit 170B) to provide backup power.

[0044] Figure 2 According to an embodiment of the present invention, Figure 1 Certain implementation details of the AFA server 100 shown in FIG. 1 , wherein the SSD 100S may be used as Figure 1Examples of multiple SSDs mentioned in the illustrated embodiment. In addition to the nodes 100A and 100B and the SSD 100S, the AFA server 100 may further include a backplane circuit 100R. The backplane circuit 100R may be used to electrically connect the SSD 100S such as the SSD groups 12A and 12B to the nodes 100A and 100B. For example, the backplane circuit 100R may be implemented by a backplane circuit board with related connectors, etc. In addition, a partial path of the NTB path between the NTB communication circuits 140A and 140B and a partial path of the BMC path between the BMCs 150A and 150B may be implemented in the backplane circuit 100R. Since each of the BMC path and the NTB path does not pass through any cables that may be susceptible to damage, the communication path between the nodes 100A and 100B is robust, and thus the nodes 100A and 100B can maintain effective communication and related control to ensure the overall performance and normal operation of the AFA server 100.

[0045] According to some embodiments, each SSD in the SSD 100S may be a single port SSD, and in particular, may be a single port device-based SSD. In addition, with the backplane circuit 100R, the AFA server 100 may support hot swapping of each SSD in the SSD 100S.

[0046] According to some embodiments, one of the two nodes 100A and 100B can be used as an active node in the high availability (HA) architecture of the AFA server 100, that is, playing the role of the active node, and the other of the two nodes 100A and 100B can be used as a standby node in the HA architecture of the AFA server 100, that is, playing the role of the standby node. The two nodes 100A and 100B, such as the active node and the standby node, can interact with each other, and in particular, can exchange node information through at least two communication paths (such as the NTB path between the NTB communication circuits 140A and 140B and the BMC path between the BMCs 150A and 150B), and can synchronize data through the NTB path, but the present invention is not limited thereto. According to some embodiments, the AFA server 100 can be equipped with more than two inter-node communication paths (e.g., more than two inter-communication paths between nodes).

[0047] Figure 3 According to an embodiment of the present invention, Figure 1FIG. 1 is a schematic diagram of a dual-node architecture of an AFA server 100 shown in FIG. 1 . According to this embodiment, nodes 100A and 100B can be configured as the active node and the standby node, respectively, but the present invention is not limited thereto. For example, nodes 100A and 100B can exchange their roles when necessary. Figure 3 As shown, except for some hardware (HW) components such as Figure 1 or Figure 2 In addition to some of the components in the illustrated architecture, certain software (SW) programs / programs may also be illustrated, such as an HA framework program, a web server program, a database program, a storage control module program operating in a service mode, and a storage control module program operating in a standby mode (respectively labeled as "HA framework," "Web server," "database," "storage control module in service mode," and "storage control module in standby mode" for simplicity) to indicate the associated interactions in the AFA server 100, wherein the names of the above programs represent their respective related functions.

[0048] The software programs running on the node 100A (e.g., HA framework program, Web server program, database program, and storage control module program operating in the service mode) can be used as an example of the program module 112A, and the software programs running on the node 100B (e.g., HA framework program, Web server program, database program, and storage control module program operating in the standby mode) can be used as an example of the program module 112B, but the present invention is not limited thereto. In addition, the one or more network interface circuits of the network interface module 130A can further include a network interface circuit 136A, and the one or more network interface circuits of the network interface module 130B can further include a network interface circuit 136B. Therefore, the AFA server 100 can be equipped with at least three inter-node communication paths (e.g., at least three inter-communication paths between nodes), such as an NTB path, a BMC path, and a network path between the network interface circuits 136A and 136B. For example, the nodes 100A and 100B may be used to perform cache mirroring operations via the NTB path, check local / remote controller status via the BMC path, and perform additional communication operations via the network path between the network interface circuits 136A and 136B.

[0049] Figure 4 According to an embodiment of the present invention, Figure 1Schematic diagram of a program module 112 in any (e.g., each) of the plurality of nodes 100A and 100B shown. For example, the program module 112 may represent a program module 112A running on a processor 110A of the node 100A or a program module 112B running on a processor 110B of the node 100B. Figure 4 As shown, the program module 112 may include certain main program modules, such as a storage protocol and block input / output (IO) interface module, a storage cache module, a storage pool module, a storage service continuous HA module, a storage function module, and a storage management module (respectively labeled as "storage protocol and block IO interface", "storage cache", "storage pool", "storage service continuous HA", "storage function" and "storage management" for simplicity), wherein any of these main program modules may include one or more sub-modules. In addition, the arrows between certain program modules in the program module 112 indicate that these program modules may interact with each other between the program modules of the multiple layers to which they belong. For example, the storage protocol and block IO interface module may be regarded as an upper layer above the storage cache module (e.g., an upper layer program module), the storage pool module may be regarded as a lower layer below the storage cache module (e.g., a lower layer program module), the storage function module and the storage cache module may be arranged in an intermediate layer as an intermediate layer program module, wherein the storage protocol and block IO interface module and the storage pool module may be used to interact with the client device and the SSD group, but the present invention is not limited thereto. When necessary, the node can trigger other program modules to interact with one or more of these program modules.

[0050] The storage protocol and block IO interface module may include certain sub-modules such as a Small Computer System Interface (SCSI) module, an Internet SCSI (iSCSI) module, and a Block Device module (respectively labeled as "SCSI", "iSCSI", and "Block Device" for simplicity). The storage cache module may include certain sub-modules such as a Persistent Memory using SW implementation module and a Write Buffer module (also referred to as "Write Buffer module"), which are respectively labeled as "Persistent Memory (Software Implementation)" and "Write Buffer" in the figure for simplicity. The storage pool module may include a sub-module such as a Flash Array module (labeled as "Flash Array" for simplicity). The storage service continuity HA module may include a sub-module such as an HA framework module (labeled as "HA Framework" for simplicity). The storage function module may include certain submodules such as a volume manager module and a data reduction module (respectively labeled as "volume manager" and "data reduction" for simplicity), wherein the data reduction module may include certain submodules such as a compression engine module and a deduplication engine module, which may be respectively referred to as "compression engine" and "deduplication engine". The storage management module may include certain submodules such as a web user interface (UI) module, an application programming interface (API) server module, a request broker module and a database module (respectively labeled as "web UI", "API server", "request broker" and "database" for simplicity). The names of the above modules indicate their related functions respectively. For ease of understanding, for a certain module such as a volume manager module, a compression engine module, a deduplication engine module, etc., the operation of consulting the module mentioned in certain embodiments may include operations such as calling and querying the module to obtain corresponding processing results from it, but the present invention is not limited to this.

[0051] According to some embodiments, the AFA server 100 (eg, the active node, such as one of the nodes 100A and 100B) may be configured to receive requests such as write requests, read requests, etc. from client devices external to the AFA server 100 and operate in response to these requests.

[0052] Figure 5 1 is a flowchart of a write control scheme for executing the AFA server 100 according to an embodiment of the present invention. In step 500, the AFA server 100 is powered on, and the AFA server 100 can communicate with other electronic devices via at least one network (e.g., LAN, WAN, Internet, etc.) and TOR switches 10A and 10B. In step 502, one node of the AFA server 100 acts as a master device, and the other node acts as a slave device. In this embodiment, the node 100A acts as a master device that can communicate with other electronic devices via TOR switches 10A and 10B and access the SSD 100S, and when the node 100A is working normally, the node 100B acts as a slave device that is not allowed to access the SSD 100S. In step 504, the processor 110A allocates a DRAM space in the DRAM 120A for a write buffer, and the processor 110A further notifies the processor 110B of the node 100B to allocate a DRAM space in the DRAM 120B for a write buffer, wherein the write buffer in the DRAM 120A / 120B may have any suitable size, such as 16GB (gigabytes) or 32GB. In step 506, the node 100A receives data from a user, that is, the user writes the data to the AFA server 100 via the network. In step 508, the node 100A writes the data into the DRAM space in the DRAM 120A, and the processor 110A further establishes Figure 6 A table 610A is shown, wherein the table 610A includes a unique ID (e.g., a user ID), a logical address of the data on the user side, a data length, and a starting address of the data in DRAM 120A. In step 510, the node 100A executes a cache mirroring mechanism to send data and corresponding information to the node 100B through the NTB, wherein the corresponding information may be at least a part of the table 610A. In other words, the corresponding information may include the user ID, the logical address of the data on the user side, and the data length. In step 512, the processor 110B of the node 100B writes the data into the DRAM space in the DRAM 120B, and the processor 110B further establishes Figure 6Table 610B is shown, wherein table 610B includes the user ID, the logical address, the data length, and a starting address of the data in DRAM 120B. After the data is completely written to DRAM 120B, the processor 110B of node 100B sends a notification to node 100A to report that the cache mirroring operation has been completed. In step 514, after the processor 110A receives the notification from node 100B (and only after receiving the notification), node 100A will send a message (mass) to the user's electronic device via TOR switch 10A / 10B to notify that the data has been successfully received, and then processor 110A starts to move the data stored in DRAM 120A to SSD 100S. In one embodiment, when the size of the data stored in DRAM 120 and capable of being moved exceeds a predetermined value (such as 64KB (kilobytes)), the data stored in DRAM 120A will be moved to SSD 100S.

[0053] In addition, when the data stored in DRAM 120A is successfully moved to SSD 100S, processor 110A deletes the data in DRAM 120A and updates table 610A to remove the information of the data. Furthermore, processor 110A further informs node 100B that the data is stored in SSD 100S, so that processor 110B can delete the data in DRAM 120B, and table 610B is updated to remove the information of the data.

[0054] Figure 5 as well as Figure 6 The cache mirroring mechanism in the above-described embodiment is used as a failover mechanism to protect data that has been written to the DRAM 120A but has not yet been written to the SSD 100S. That is, once the master device stores the received data in the DRAM 120A, the master device immediately sends the data to the slave device so that both the master device and the slave device have the data. Therefore, since both the master device and the slave device have the data, once the master device fails to work properly, the slave device can immediately replace the master device to perform the operation that should be performed by the master device, that is, the slave device moves the data stored in the DRAM 120B to the SSD 100S at an appropriate time.

[0055] In detail, if the master device (e.g., node 100A) suddenly cannot access the SSD 100S, for example, the operating system of the master device crashes, the memory or a storage device in the master device is damaged, a downstream port is disabled, or any other failure reason, the AFA server 100 can immediately execute a failover mechanism, that is, the slave device (e.g., node 100B) replaces the master device. Specifically, the master device and the slave device are always communicating with each other, and the slave device can detect whether the master device can access the SSD 100S. For example, if the slave device receives a special signal indicating a failover instruction from the master device, and / or the slave device does not receive a signal sent regularly from the master device, and / or the slave device sends a signal to the master device but does not receive a response, or any other failure detection mechanism, the slave device can determine that the master device cannot access the SSD 100S.

[0056] To summarize briefly, in the cache mirroring mechanism and failover mechanism of the present invention, the AFA server has a master device and a slave device, and the master device and the slave device communicate by using NTB. Whenever the master device receives data that needs to be written to the SSD, the master device sends the data to the slave device so that both the master device and the slave device have the data. Once the master device fails to work properly, the slave device can immediately replace the master device to store the data in the SSD. In summary, by using the embodiments of the present invention, the AFA server can provide better protection for data.

[0057] The above description is only a preferred embodiment of the present invention. All equivalent changes and modifications made according to the scope of the patent application of the present invention should fall within the scope of the present invention.

Claims

1. A server, comprising: A solid state drive (SSD); A first node, comprising: a first network module, used to communicate with another electronic device via a network; a first processor; a first memory; a first non-transparent bridge communication circuit coupled to the first processor and the first memory; as well as a first motherboard management controller, coupled to the first processor; The first network module, the first processor, the first memory, the first non-transparent bridge communication circuit and the first motherboard management controller are located on a first circuit board; A second node, comprising: a second network module, used for communicating with the other electronic device via a network; a second processor; a second memory; and a second non-transparent bridge communication circuit coupled to the second processor, the second memory and the first non-transparent bridge communication circuit; a second motherboard management controller, coupled to the second processor; The second network module, the second processor, the second memory, the second non-transparent bridge communication circuit and the second motherboard management controller are located on a second circuit board; The first node and the second node perform a cache mirroring operation through the first non-transparent bridge communication circuit and the second non-transparent bridge communication circuit; when the first processor receives a data from the other electronic device through the first network module, the first processor stores the data in the first memory, and the first processor further sends the data to the second node through the first non-transparent bridge communication circuit and the second non-transparent bridge communication circuit; when the second processor receives the data from the first node, the second processor stores the data in the second memory, and the second processor further sends a notification to the first node to report that the data has been successfully stored in the second memory; and only after the first processor receives the notification from the second node, the first processor starts to write the data into the solid state drive; Each of the first node and the second node checks the status of the other through the first motherboard management controller and the second motherboard management controller; and the second node determines whether the first node cannot access the solid state drive by detecting whether a signal regularly sent from the first node is not received.

2. The server according to claim 1, wherein: Only after the first processor receives the notification from the second node, the first processor will send a notification to the other electronic device via the first network module to report that the data has been successfully received, and then the first processor will start writing the data to the solid state drive.

3. The server according to claim 1, wherein: The second non-transparent bridge communication circuit and the first non-transparent bridge communication circuit are connected to each other via a Peripheral Component Interconnect Express (PCIe) interface.

4. The server according to claim 1, wherein: When the first processor receives the data from the other electronic device via the first network module, the first processor further establishes a first table, which includes a user identifier corresponding to the other electronic device, a logical address of the data, a data length, and a starting address of the data in the first memory.

5. The server according to claim 4, wherein: The first processor sends the data and at least a portion of the first table to the second node.

6. The server according to claim 5, wherein: When the second processor receives the data from the first node via the second non-transparent bridge communication circuit, the second processor stores the data in the second memory, and the second processor further establishes a second table, which includes the user identifier corresponding to the other electronic device, the logical address of the data, the data length, and a starting address of the data in the second memory.

7. The server according to claim 1, wherein: After the data is successfully written into the solid state drive, the first processor deletes the data in the first memory, the first processor further notifies the second node that the data has been successfully written into the solid state drive, and then the second processor deletes the data in the second memory.

8. The server according to claim 1, wherein: If the first node fails to work properly and the first processor cannot successfully write the data to the SSD, the second node will enable a failover mechanism to replace the first node to move the data from the second memory to the SSD.