CN118132471A - Hard disk control method and device - Google Patents

Hard disk control method and device Download PDF

Info

Publication number
CN118132471A
CN118132471A CN202410382437.XA CN202410382437A CN118132471A CN 118132471 A CN118132471 A CN 118132471A CN 202410382437 A CN202410382437 A CN 202410382437A CN 118132471 A CN118132471 A CN 118132471A
Authority
CN
China
Prior art keywords
expander
management controller
hard disk
baseboard management
multiplexer
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202410382437.XA
Other languages
Chinese (zh)
Inventor
张海成
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Suzhou Metabrain Intelligent Technology Co Ltd
Original Assignee
Suzhou Metabrain Intelligent Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Suzhou Metabrain Intelligent Technology Co Ltd filed Critical Suzhou Metabrain Intelligent Technology Co Ltd
Priority to CN202410382437.XA priority Critical patent/CN118132471A/en
Publication of CN118132471A publication Critical patent/CN118132471A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F13/00Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
    • G06F13/14Handling requests for interconnection or transfer
    • G06F13/16Handling requests for interconnection or transfer for access to memory bus
    • G06F13/1668Details of memory controller
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F13/00Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
    • G06F13/38Information transfer, e.g. on bus
    • G06F13/42Bus transfer protocol, e.g. handshake; Synchronisation
    • G06F13/4282Bus transfer protocol, e.g. handshake; Synchronisation on a serial bus, e.g. I2C bus, SPI bus
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2213/00Indexing scheme relating to interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
    • G06F2213/0016Inter-integrated circuit (I2C)

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Hardware Redundancy (AREA)

Abstract

The application relates to the technical field of storage servers, in particular to a hard disk control method and device, comprising the following steps: the first baseboard management controller is positioned in the first system and used for detecting whether the first system is in an abnormal state or not; under the condition that the first system is in an abnormal state, sending a take-over request to a second baseboard management controller of the second system; and releasing the control authority of the multiplexer of the first system; the second baseboard management controller is used for controlling the first hard disk of the first system after switching the uplink opening and closing states of the first expander of the first system through the multiplexer of the first system according to the takeover request; wherein a first expander first upstream port of the first expander is configured to be controlled by the first system and a first expander second upstream port is configured to be controlled by the second system. By the embodiment of the application, the hard disk in the fault system can still normally execute access operation, thereby ensuring the normal operation of the service and improving the safety of the storage server system.

Description

Hard disk control method and device
Technical Field
The application relates to the technical field of storage servers, in particular to a hard disk control method and device.
Background
Because the internal hard disk is controlled by the independent operating system in the storage server, the control of the hard disk is lost under the condition that the operating system of the storage server system fails, and the hard disk of the storage server cannot work normally; if multiple operating system configurations are performed, there is a significant negative impact on the performance of the storage server system. Therefore, how to control the hard disk to improve the security of the storage server system and ensure the normal operation of the service is still a problem to be solved.
Disclosure of Invention
One of the objects of the present application is to propose a hard disk control method to solve or at least partially solve the problems in the related art. Another object of the present application is to provide another method for controlling a hard disk, and a third object of the present application is to provide a hard disk control device.
In order to achieve the above object, the technical scheme of the present application is as follows:
the hard disk control method is applied to a first baseboard management controller, wherein the first baseboard management controller is positioned in a first system; comprising the following steps:
detecting whether the first system is in an abnormal state;
sending a take-over request to a second baseboard management controller of a second system under the condition that the first system is in an abnormal state;
And releasing control authority of a multiplexer of the first system; the second baseboard management controller switches the uplink opening and closing states of the first expander of the first system through the multiplexer according to the takeover request, and then controls the first hard disk of the first system;
the upstream port of the first expander comprises a first upstream port of the first expander and a second upstream port of the first expander, the first upstream port of the first expander is configured to be controlled by the first system, and the second upstream port of the first expander is configured to be controlled by the second system.
Optionally, a takeover request signal endpoint in a first interface module of the first system is connected with a takeover interrupt signal endpoint of a second interface module of the second system; and sending a take-over request to a second baseboard management controller of a second system under the condition that the first system is in an abnormal state, wherein the take-over request comprises the following steps:
Transmitting a take-over request signal to the second interface module through the first interface module;
converting the takeover request signal into a takeover interrupt signal through the takeover request signal endpoint and the takeover interrupt signal endpoint; and transmitting the takeover interrupt signal to the second baseboard management controller.
Optionally, the releasing the control authority of the multiplexer of the first system includes:
And enabling the I2C channel connected with the multiplexer by the second baseboard management controller to be effective and enabling the I2C channel connected with the multiplexer by the first baseboard management controller to be ineffective by controlling the gating signal of the multiplexer.
Optionally, after releasing the control authority for the multiplexer, the method further comprises:
Forwarding, by the multiplexer, a switching signal sent by the second baseboard management controller to the first expander; and the first expander closes the first uplink port of the first expander according to the switching signal, and opens the second uplink port of the first expander.
Optionally, the detecting whether the first system is in an abnormal state includes:
Detecting whether the communication between the operating system of the first system and the first baseboard management controller is abnormal or not;
And determining that the first system is in an abnormal state under the condition that the operating system of the first system is abnormal in communication with the first baseboard management controller.
Optionally, the first uplink port of the first expander is connected with a first interface of a first HBA card of the first system; the second uplink port of the first expander is connected with a second interface of a second HBA card of the second system through a first interface module of the first system and a second interface module of the second system; the second interface of the first HBA card of the first system is connected with a second upstream port of a second expander of the second system through a first interface module of the first system and a second interface module of the second system; a first uplink port of a second expander of the second expander is connected with a first interface of a second HBA card of the second system; the method further comprises the steps of:
Under the condition that the first system and the second system are in a normal state, a first uplink port of the first expander and a first uplink port of the second expander are opened, a second uplink port of the first expander and a second uplink port of the second expander are closed, so that the first system controls the first hard disk through the first expander, and the second system controls the second hard disk of the second system through the second expander.
The hard disk control method is applied to a second baseboard management controller, and the second baseboard management controller is positioned in a second system; the method comprises the following steps:
Receiving a take-over request, wherein the take-over request is sent to the second baseboard management controller by the first baseboard management controller of the first system under the condition that the first system is in an abnormal state;
switching an uplink port switching state of a first expander of the first system through a multiplexer of the first system according to the takeover request; the control authority of the multiplexer is obtained after the first baseboard management controller is released under the condition that the first system is in an abnormal state;
controlling a first hard disk of the first system according to the first expander after the uplink port switch state is switched;
the upstream port of the first expander comprises a first upstream port of the first expander and a second upstream port of the first expander, the first upstream port of the first expander is configured to be controlled by the first system, and the second upstream port of the first expander is configured to be controlled by the second system.
Optionally, a takeover request signal endpoint in a first interface module of the first system is connected with a takeover interrupt signal endpoint of a second interface module of the second system; the receiving a take over request includes:
receiving a take-over interrupt signal transmitted to the second baseboard management controller by the second interface module; the take-over interrupt signal is obtained by converting the take-over request signal sent by the first interface module to the second interface module through the take-over request signal endpoint and the take-over interrupt signal endpoint.
Optionally, the switching, according to the takeover request, the uplink port switch state of the first expander of the first system through the multiplexer of the first system includes:
According to the takeover request, a switching signal is sent to the multiplexer;
And forwarding the switching signal to the first expander through the multiplexer so that the first expander closes a first uplink port of the first expander and opens a second uplink port of the first expander according to the switching signal.
A hard disk control device, the device comprising:
A first system, comprising:
A first hard disk, a multiplexer, a first expander, and a first baseboard management controller; the first baseboard management controller is used for executing the hard disk control method;
A second system, comprising:
And the second baseboard management controller is used for controlling the first hard disk under the condition that the first system is in an abnormal state.
The application has the beneficial effects that:
In the application, whether the first system is in an abnormal state is detected by a first baseboard management controller positioned in the first system; under the condition that the first system is in an abnormal state, sending a take-over request to a second baseboard management controller of the second system; and releasing the control authority of the multiplexer of the first system; so that the second system controls the first hard disk of the first system after switching the uplink port switch state of the first expander of the first system through the multiplexer according to the takeover request; the first expander comprises a first expander first uplink port and a first expander second uplink port, the first expander first uplink port is configured to be controlled by the first system, and the first expander second uplink port is configured to be controlled by the second system, so that when the first system is abnormal, the second system can control the first hard disk of the first system by switching the uplink port switch state of the first expander of the first system and utilizing the first expander after switching the uplink port switch state to realize control right switching of the first hard disk. Therefore, under the condition that the first system fails, the hard disk of the first system is accessed through the second system, and the hard disk of the first system can still normally support service operation at the moment, so that the safety of the storage server system is improved, and the normal operation of the service is ensured.
Drawings
In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings that are needed in the description of the embodiments will be briefly described below, it being obvious that the drawings in the following description are only some embodiments of the present application, and that other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
FIG. 1 is a flow chart of a method for controlling a hard disk according to an embodiment of the application;
FIG. 2 is a schematic diagram of an architecture of a storage server system according to an embodiment of the present application;
FIG. 3 is a schematic diagram illustrating the connection of the interconnection device according to an embodiment of the present application;
FIG. 4 is a partial logic diagram of a method for controlling a hard disk according to an embodiment of the application.
Detailed Description
Further advantages and effects of the present application will become readily apparent to those skilled in the art from the disclosure herein, by referring to the accompanying drawings and the preferred embodiments. The application may be practiced or carried out in other embodiments that depart from the specific details, and the details of the present description may be modified or varied from the spirit and scope of the present application. It should be understood that the preferred embodiments are presented by way of illustration only and not by way of limitation.
In the present application, BMC: baseboard Management Controller, a baseboard management controller; HBA: host Bus Adapter, host Bus Adapter; CPU: central Processing Unit, a central processing unit; HDD: HARD DISK DRIVE, a hard disk drive; PCIe: PERIPHERAL COMPONENT INTERCONNECT EXPRESS, high speed serial computer expansion bus standard; SAS: SERIAL ATTACHED SCSI serial attached SCSI interface; I2C: inter-INTEGRATED CIRCUIT, a simple, bi-directional two-wire synchronous serial bus.
The requirements on storage capacity, speed and safety of a storage server are higher and higher due to the rapid development of cloud computing and big data. The current common topology of storage servers is CPU-HBA-SAS Expander-HDD, where the HBA converts the PCIe signals of the CPU into SAS signals, which are expanded by the SAS Expander to support a greater number of hard disks.
The core concept of the application is that the optimization is carried out on the basis of the topology structure of a CPU-HBA-SAS Expander-HDD of the storage server system, and two storage server systems with the same configuration are arranged: the system comprises a first system and a second system, wherein two uplink ports of an expander of each system are configured to be controlled by the system, one uplink port is controlled by an opposite terminal system, when one system fails, the control right of the expander in the failure system is switched by switching the on-off state of the expander of the failure system, so that the opposite terminal system can control a hard disk in the failure system through the control of the expander in the failure system, and therefore, the hard disk in the failure system can still normally respond to service requirements to execute access operation through the opposite terminal system, the normal operation of a service is ensured, and the safety of a storage server system is improved.
Specifically, referring to fig. 1, fig. 1 is a flowchart of a method for controlling a hard disk according to an embodiment of the application. In one embodiment of the application, a hard disk control method is applied to a first Baseboard Management Controller (BMC) of a first system. As shown in fig. 1, in one embodiment of the present application, a hard disk control method is performed according to the following steps:
Step S101, detecting whether the first system is in an abnormal state.
Specifically, the first system is a storage server system. The operating system in the storage server system communicates with the baseboard management controller BMC. And the baseboard management controller of the first system can detect whether the first system is in an abnormal state or not and monitor whether the hard disk of the first system works normally or not. For example, if the baseboard management controller in the first system detects that the operating system is blocked and cannot normally access the data in the hard disk, it is determined that the first system is abnormal.
In a possible implementation manner, the step S101 detects whether the first system is in an abnormal state, and specifically includes:
Detecting whether the communication between the operating system of the first system and the first baseboard management controller is abnormal or not;
And under the condition that the operating system of the first system is abnormal in communication with the first baseboard management controller, determining that the first system is in an abnormal state.
Specifically, when the operating system of the storage server system fails, the program running on the storage server system cannot perform service processing any more, and the hard disk of the storage server cannot work normally. When the first baseboard management controller monitors that communication with the operating system is interrupted, it is determined that the first system is abnormal, the hard disk cannot work normally, and the opposite terminal system is required to take over the local hard disk.
In this embodiment, by detecting the communication state between the operating system of the first system and the first baseboard management controller, it is determined whether the current first system is in an abnormal state, and the storage server system is monitored by using the original BMC communication mode in the storage server system, so that the optimization cost is reduced.
Step S102, when the first system is in an abnormal state, a take-over request is sent to a second baseboard management controller of a second system.
Specifically, in the present application, the first system and the second system are each configured with an interface module, and the interface module of the first system and the interface module of the second system are connected by an interconnection cable to form an interconnection device, and in the case of a failure of the first system, the first baseboard management controller of the first system can communicate with the second baseboard management controller of the second system through the interconnection device. After the base plate management controller in the first system determines that the system fails, a take-over request is sent to the base plate management controller of the second system at the opposite end; the second system may receive the take over request of the first system. In the present application, the take-over request may be sent by a REQ (request) signal to request the peer second system to take over the hard disk controlled by the first system (i.e. the first hard disk).
Step S103, releasing the control authority of the multiplexer; and the second baseboard management controller controls the first hard disk of the first system after switching the uplink opening and closing states of the first expander of the first system through the multiplexer according to the takeover request.
Specifically, in a default state, that is, under the condition that the first system works normally, the first baseboard management controller of the first system controls the multiplexer (also called I2C Mux) through an I2C channel between the first baseboard management controller and the multiplexer, so as to realize the management of the first hard disk by the first baseboard management controller; under the condition that the first system is abnormal, the first baseboard management controller releases the control right to the multiplexer, so that the second baseboard management controller of the second system obtains the control right to the multiplexer. The multiplexer is connected to the first expander. After the second baseboard management controller receives the take-over request, the uplink port switch state of the first expander is switched through the multiplexer based on the control authority of the multiplexer according to the take-over request.
In the present application, the upstream port of the first expander includes a first expander first upstream port configured to be controlled by the first system and a first expander second upstream port configured to be controlled by the second system. After the second baseboard management controller makes the uplink switch state of the first expander switch, the management right of the first expander can be switched, namely, the second system can control the first expander.
In the related art, the expander reads and writes to the hard disk through the connected HDD, and at this time, the second baseboard management controller of the second system can control the first hard disk of the first system after controlling the first expander.
In this embodiment, whether the first system is in an abnormal state is detected by a first baseboard management controller located in the first system; under the condition that the first system is detected to be in an abnormal state, sending a take-over request to a second baseboard management controller of the second system; and releasing the control authority of the multiplexer of the first system; so that the second system controls the first hard disk of the first system after switching the uplink port switch state of the first expander of the first system through the multiplexer according to the takeover request; the first expander comprises a first expander first uplink port and a first expander second uplink port, the first expander first uplink port is configured to be controlled by the first system, and the first expander second uplink port is configured to be controlled by the second system, so that when the first system is abnormal, the second system can control the first hard disk of the first system by switching the uplink port switch state of the first expander of the first system and utilizing the first expander after switching the uplink port switch state to realize control right switching of the first hard disk. Therefore, under the condition that the first system fails, the hard disk of the first system is accessed through the second system, and the hard disk of the first system can still normally support service operation at the moment, so that the safety of the storage server system is improved, and the normal operation of the service is ensured.
In a possible implementation manner, the first upstream port of the first expander is connected with a first interface of a first HBA card of the first system; the second uplink port of the first expander is connected with a second interface of a second HBA card of the second system through a first interface module of the first system and a second interface module of the second system; the second interface of the first HBA card of the first system is connected with a second upstream port of a second expander of the second system through a first interface module of the first system and a second interface module of the second system; a first uplink port of a second expander of the second expander is connected with a first interface of a second HBA card of the second system;
the hard disk control method further comprises the following steps:
Under the condition that the first system and the second system are in a normal state, a first uplink port of the first expander and a first uplink port of the second expander are opened, a second uplink port of the first expander and a second uplink port of the second expander are closed, so that the first system controls the first hard disk through the first expander, and the second system controls the second hard disk of the second system through the second expander.
Specifically, the expander in the first system is a first expander, the expander in the second system is a second expander, the HBA card in the first system is a first HBA card, and the HBA card in the second system is a second HBA card. In one embodiment of the present application, a schematic architecture of the first system and the second system is shown in fig. 2, and an interconnection device formed by respective interface modules of the first system and the second system is shown in fig. 3.
The technical architecture and connection of the first system and the second system will be further described with reference to fig. 2 and 3. Fig. 2 is a schematic diagram of an architecture of the storage server system according to an embodiment of the application, and fig. 3 is a schematic diagram of connection of the interconnection device according to an embodiment of the application. The interconnection device in fig. 3 is composed of the interface module of the first system and the interface module of the second system, and an interconnection cable.
In the present application, the first system and the second system are storage server systems of the same configuration. The first system includes a CPU, HBA card, expander module, BMC module, multiplexer module, interface module, and HDD module (hard disk drive control module for operating a first hard disk of the first system).
The first interface module of the first system is positioned in the first system, the second interface module of the second system is positioned in the second system, and the first interface module is connected with the second interface module through an interconnection cable. The first interface module of the first system, the second interface module of the second system and the interconnection cable form an interconnection device.
The CPU of the first system is connected with a first HBA card of the first system through PCIe signals, and the first HBA converts the PCIe signals into SAS signals.
The first HBA card of the first system is connected to an Expander of the first system through SAS signals, the first interface P0 of the first HBA card is connected to the first upstream port U1 of the Expander of the first system, the second interface P1 of the first HBA card is connected to the second upstream port U2 of the Expander of the second system through interconnection means, and likewise, the second upstream port U2 of the Expander of the first system is connected to the second interface P1 of the second HBA card of the second system.
However, the second upstream port U2 of the Expander of the first system is closed in a default state (the first system is in a normal state), and only the first upstream port U1 is opened. Similarly, in the second system, the second upstream port U2 of the Expander is closed in a default state (the second system is in a normal state), and only the first upstream port U1 is opened. Therefore, when the first system works normally, the first hard disk is controlled through the opened first uplink port of the first expander, the second uplink port of the first expander connected with the second system is closed, and the second system does not have control right on the first hard disk.
In this embodiment, by connecting the configuration of the expander and the modules in the first system and the second system, when the first system and the second system perform the service normally, the first system and the second system do not affect each other, and each controls the hard disk of the system. Therefore, the security of the storage server system can be improved without using the opposite-end system as redundancy, and the utilization rate of the storage server system resources can be improved.
In a possible embodiment, the takeover request signal endpoint in the first interface module of the first system is connected with the takeover interrupt signal endpoint of the second interface module of the second system;
And sending a take-over request to a second baseboard management controller of a second system under the condition that the first system is in an abnormal state, wherein the take-over request comprises the following steps:
Transmitting a takeover request signal through the first interface module;
converting the takeover request signal into a takeover interrupt signal through the takeover request signal endpoint and the takeover interrupt signal endpoint; and transmitting the takeover interrupt signal to the second baseboard management controller.
Specifically, in the interconnection device formed by the first interface module of the first system and the second interface module of the second system, the endpoint of the takeover request signal REQ of the first interface module is connected with the endpoint of the takeover interrupt signal INT of the second interface module of the second system. As shown in fig. 2 and fig. 3, for the first system and the second system, the takeover request signal REQ of the system itself is connected to the takeover interrupt signal of the opposite-end BMC module through the interconnection device, and likewise, the takeover interrupt signal INT of the system itself is connected to the takeover request signal REQ of the opposite-end BMC module.
When the first baseboard management controller sends a takeover request signal to the second baseboard management controller, the first baseboard management controller sends the takeover request signal through a takeover request signal endpoint of the first interface module, and as the takeover request signal endpoint of the first interface module is connected with a takeover interrupt signal endpoint of a second interface module of the second system, in the interconnection device, the takeover request signal is converted into a takeover interrupt signal of the second interface, and the second interface module transmits the takeover interrupt signal to the second baseboard management controller. And triggering the take-over interrupt signal of the second baseboard management controller, and starting the process of taking over the first hard disk after the second baseboard management controller receives the take-over request sent by the first baseboard management controller.
For example, when a first system fails, the BMC module of the first system requests a second system to take over the hard disk module of the first system by transmitting a REQ (request) signal, and switches the hard disk management right to the second system. After the second system receives the INT (interrupt) signal, the hard disk module of the first system is taken over by switching the uplink port switch state of the Expander of the first system (the first uplink port U1 of the first Expander is closed, and the second uplink port U2 of the first Expander is opened).
In this embodiment, by connecting the request signal endpoint in the first interface module of the first system with the interrupt signal endpoint of the second interface module of the second system, the speed of the first baseboard management controller sending the take-over request to the second baseboard management controller of the second system can be increased, and the take-over interrupt signal of the second baseboard management controller can be triggered quickly, so as to inform the second system that the hard disk of the first system needs to be taken over. Therefore, the control right switching speed of the first hard disk is improved, and the normal operation of the follow-up service is ensured.
In a possible embodiment, the releasing the control authority of the multiplexer of the first system includes:
And enabling the I2C channel connected with the multiplexer by the second baseboard management controller to be effective and enabling the I2C channel connected with the multiplexer by the first baseboard management controller to be ineffective by controlling the gating signal of the multiplexer.
Specifically, referring to fig. 2 and 3, the i2c_out endpoint of the first interface is connected to the i2c_in endpoint of the second interface, and the i2c_out endpoint of the second interface is connected to the i2c_in endpoint of the second interface. The BMC module of the first system is provided with a 2-way management I2C channel, and the I2C1 way is connected with the Expander of the first system through a multiplexer to monitor the HDD module of the first system. I2c_outis connected to I2C2 of the second system by way of an interconnection means.
The BMC module of the first system is connected with a gating signal SEL of the multiplexer, the I2C1 path can be controlled to be invalid, the I2C2 path is enabled, and the output I2C3 of the multiplexer is managed by the I2C 2. Therefore, the control right switching of the first expander is realized, and the control right switching of the first hard disk is further realized.
As shown in fig. 2, when the first system controls the hard disk of the first system, the hard disk of the first system is managed by the I2C1 from the BMC module of the present system, and after the switch, the hard disk of the first system is managed by the I2C2 from the BMC module of the second system at the opposite end.
In this embodiment, under the condition that the first system is abnormal, by configuring the multiplexer, under the condition that the operating system of the storage server system fails, communication between the first system and the second system can still be ensured on the basis of the hardware connection link, which is favorable for realizing hard disk control right switching of the failed system.
In a possible embodiment, after releasing the control authority of the multiplexer of the first system, the method further comprises:
Forwarding, by the multiplexer, a switching signal sent by the second baseboard management controller to the first expander; and the first expander closes the first uplink port of the first expander according to the switching signal, and opens the second uplink port of the first expander.
Specifically, after the first baseboard management controller releases the control authority to the multiplexer of the first system, the multiplexer of the first system is controlled by the second baseboard manager of the second system. At this time, the multiplexer of the first system may receive the switching signal sent by the second baseboard management controller, and then the multiplexer forwards and transmits the switching signal to the first expander. The switching signal comprises configuration information of an uplink port of the first expander, and the configuration information is used for indicating the first expander to switch the switching state of the uplink port according to the switching signal. The first expander can switch the states of opening the first uplink port of the first expander and closing the second uplink port of the first expander in the default state into the states of closing the first uplink port of the first expander and opening the second uplink port of the first expander according to the switching signal.
Referring to fig. 2 and 3, an output I2C3 of the multiplexer of the first system is connected to an Expander of the first system, and an uplink port enabled by the Expander is configured by default as a first uplink port U1 connected to the HBA card of the first system, and after receiving a switching signal, the Expander switches to enable a second uplink port U2 connected to the HBA card of the second system at the opposite end. The HDD module of the first system is connected with the Expander of the first system through an SAS signal, so that the hard disk of the first system is controlled.
In this embodiment, the control right of the multiplexer of the first system is switched to the second system, so that the multiplexer of the first system receives the switching signal sent by the second baseboard management controller, and then the switching signal is transmitted to the first expander, and the switching states of the two uplink ports of the first expander are changed accordingly, thereby realizing the control right switching of the first hard disk controlled by the first expander. The multiplexer and the first expander are applied to open a control link of the second system to the first hard disk, when one storage server system fails, the storage server system at the opposite end can take over the hard disk of the failed system, technical support is provided for guaranteeing the safety of the storage server system, and the problem that the hard disk of the storage server system cannot work continuously when the storage server system fails is avoided.
Referring to fig. 4, fig. 4 is a schematic diagram of part of the hard disk control method according to an embodiment of the present application, as shown in fig. 4, the default U1 (the first uplink port) of the expander uplink port of each of the first system and the second system is opened, the default U2 (the second uplink port) is closed, and when the BMC (i.e. the first baseboard management controller) of the first system detects that the first system is abnormal, a take-over request signal is sent to the second system to request the second system to take over the hard disk (i.e. the first hard disk) of the first system, and the strobe signal of the multiplexer of the first system is controlled to release the control right of the multiplexer to the second system; the takeover interrupt signal of the BMC (i.e., the second baseboard management controller) of the second system is triggered, and receives the takeover request of the first system, and the second baseboard management controller of the second system configures the uplink port state of the first expander chip of the first system through the multiplexer of the first system, so that the uplink port U1 (first uplink port) of the first expander chip is closed, and U2 (second uplink port) is opened.
In the technical architecture of the present application, the uplink port U2 of the first expander chip is connected to the second interface of the HBA card in the second system, and then the second system can take over the hard disk of the first system after the uplink port U2 of the first expander chip is opened. In the application, the management right of the expander is switched through the state switching of the uplink port of the expander, so that the management right of the hard disk connected with the expander is finally switched, the fault system hard disk is accessed through the opposite terminal system, and the normal operation of the service is ensured.
In one embodiment of the present application, after the first hard disk of the first system is controlled by the second system, if the first baseboard management controller detects that the first system is restored to the normal state, the control right of the first hard disk may be switched to the first system by the first baseboard management controller. Specifically, when the first baseboard management controller detects that the first system is recovered from an abnormal state to a normal state, the control authority of the multiplexer of the first system is obtained again, the switch state of the uplink port of the first expander is switched through the multiplexer of the first system, the first uplink port of the first expander is opened, and the second uplink port of the first expander is closed. The recovered first system controls the first hard disk through the first uplink port of the first expander, and after the second uplink port of the first expander connected with the second system is closed, the second system loses the control authority to the first hard disk. Based on the technical conception of the application, two storage server systems can be regarded as a node, under the default state, the system manages and controls the internal hard disk, and when a certain system fails, the system at the opposite end can take over the hard disk of the failed system, so as to ensure the normal operation of the service and improve the safety of the storage server.
In one embodiment of the present application, a hard disk control method is applied to a second baseboard management controller, where the second baseboard management controller is located in a second system. Specifically, the hard disk control method includes:
Step S501, a take over request is received.
And when the takeover request is that the first system is in an abnormal state, the first baseboard management controller of the first system sends the takeover request to the second baseboard management controller.
Specifically, when the first system is in an abnormal state, the first baseboard management controller located in the first system sends a take-over request to the second baseboard management controller, and the second baseboard management controller knows that the first system is abnormal and triggers the second system to take over the hard disk of the first system.
Step S502, switching the uplink opening switch state of a first expander of the first system through a multiplexer of the first system according to the takeover request;
the control authority of the multiplexer is obtained after the first baseboard management controller is released under the condition that the first system is abnormal.
Specifically, after receiving the take-over request, the baseboard management controller of the second system triggers the control of the hard disk of the first system according to the take-over request: since the multiplexer of the first system releases the control right of the multiplexer under the condition of the first system failure, the second system can acquire the control right of the multiplexer of the first system, and when the second system is required to take over the control right of the hard disk of the first system, the multiplexer of the first system can be used for configuring the uplink port switch state of the first expander of the first system.
Step S503, controlling the first hard disk of the first system according to the first expander after the uplink port switch state is switched.
Specifically, the upstream port of the first expander includes a first expander first upstream port configured to be controlled by the first system and a first expander second upstream port configured to be controlled by the second system. The first expander reads and writes the first hard disk through the connected HDD. The application optimizes the topology structure of the CPU-HBA-SAS Expander-HDD of the storage server system, switches the on-off state of the uplink port of the first Expander of the first system, can switch the control of the first Expander, and can switch the control of the hard disk of the first system by switching the control of the first Expander. Therefore, after the state switching of the uplink port of the first expander is completed, the second system can further control the first hard disk of the first system through the control of the first expander, and thus, after the first system fails, the first hard disk of the first system can be normally accessed through the second system.
In this embodiment, in the case that the first system is in an abnormal state, receiving, by the baseboard management controller of the second system, a takeover request sent by the first baseboard management controller of the first system; after the first baseboard management controller releases the control right of the multiplexer of the first system, the control right of the multiplexer is obtained, according to the takeover request, the uplink opening and closing state of the first expander of the first system is switched through the multiplexer, and as the uplink opening of the first expander comprises a first uplink opening of the first expander and a second uplink opening of the first expander, the first uplink opening of the first expander is configured to be controlled by the first system, the second uplink opening of the first expander is configured to be controlled by the second system, the control right of the first expander can be switched through switching the uplink opening and closing state of the first expander, and after the uplink opening and closing state of the first expander is switched, the first hard disk of the first system can be controlled through switching the first expander after the uplink opening and closing state of the first expander. Therefore, under the condition that the first system is abnormal, the opposite end system takes over the hard disk of the abnormal system, the hard disk of the abnormal system can still support service operation, and the safety of the storage server system is improved.
In one embodiment of the application, a takeover request signal endpoint in a first interface module of a first system is connected with a takeover interrupt signal endpoint of a second interface module of a second system; in the step S501, the receiving the take-over request specifically includes:
Receiving a take-over interrupt signal transmitted to a second baseboard management controller by a second interface module; the take-over interrupt signal is obtained by converting the take-over request signal sent by the first interface module to the second interface module through the take-over request signal endpoint and the take-over interrupt signal endpoint.
Specifically, referring to fig. 2 and 3, in the interconnection device formed by the first interface module of the first system and the second interface module of the second system, the endpoint of the takeover request signal REQ of the first interface module is connected to the endpoint of the takeover interrupt signal INT of the second interface module of the second system. As shown in fig. 2 and fig. 3, for the first system and the second system, the system's own takeover request signal REQ is connected to the takeover interrupt signal of the opposite-end BMC module through the interconnection device, and likewise, the system's own takeover interrupt signal INT is connected to the takeover request signal of the opposite-end BMC module.
In this embodiment, a takeover request signal endpoint in a first interface module of a first system is connected with a takeover interrupt signal endpoint of a second interface module of the second system in advance, when the first baseboard management controller sends a takeover request to the second baseboard management controller, the takeover request signal of the first interface directly triggers a takeover terminal signal of the second baseboard management controller through connection of the takeover request signal endpoint and the takeover interrupt signal endpoint, so that the second baseboard management controller can receive the takeover request sent by the first baseboard management controller, the timeliness of the second baseboard management controller receiving the takeover request is improved, the second baseboard management controller can quickly know a first hard disk needing to take over the first system, the control right switching speed of the first hard disk is improved, and normal operation of subsequent services is ensured.
In one embodiment of the present application, the step S502, according to the takeover request, switches an uplink port switch state of a first expander of the first system through a multiplexer of the first system, specifically includes:
According to the takeover request, a switching signal is sent to the multiplexer;
And forwarding the switching signal to the first expander through the multiplexer so that the first expander closes a first uplink port of the first expander and opens a second uplink port of the first expander according to the switching signal.
Specifically, when the first system is in an abnormal state, the control authority of the multiplexer of the first system is switched to the first system, and after receiving the takeover request, the second baseboard management controller sends a switching signal to the multiplexer of the first system through the control authority of the multiplexer. Referring to fig. 2, after the multiplexer receives the switching signal, the switching signal is transmitted to the first expander through the I2C3 path between the multiplexer and the first expander, and the first expander can switch the uplink switch state of the first expander according to the switching signal: and closing a first upstream port of the first expander controlled by the first system, and opening a second upstream port of the first expander controlled by the second system. Therefore, after the first expander switches the uplink opening and closing state of the first expander according to the switching signal, the second system can control the hard disk of the first system through the first expander after switching the uplink opening and closing state.
In this embodiment, the control authority of the multiplexer in the first system is switched, so as to implement the switching of the uplink port management authority of the expander of the failure system, thereby enabling the link of the hard disk of the failure system to be controlled by the opposite end system, and implementing that the opposite end storage server system takes over the hard disk of the failure storage server system in the case of failure of the storage server system.
In one embodiment of the present application, the architecture of the second system and the first system is shown in fig. 2, and the connection schematic of the first interface module of the first system and the second interface module of the second system is shown in fig. 3.
In one embodiment of the present application, a hard disk control device is also provided based on the same or similar technical concept of the present application. Specifically, the device comprises:
A first system, comprising:
The first hard disk, the multiplexer, the first expander and the first baseboard management controller, wherein the first baseboard management controller is used for executing the hard disk control method described in the above embodiment;
A second system, comprising:
And the second baseboard management controller is used for controlling the first hard disk under the condition that the first system is in an abnormal state.
In this embodiment, the hard disk control device is composed of the first system and the second system. The first system and the second system are the same server system, so that when one system is abnormal, the opposite end system takes over the hard disk of the fault system, and the opposite end system is used for controlling the hard disk of the fault system, so that the safety of the storage server system is improved, and the normal operation of the service is ensured.
In the present application, the description of the device embodiments is less, and specific reference may be made to the above method embodiments, which are not described herein.
In this specification, each embodiment is described in a progressive manner, and each embodiment is mainly described by differences from other embodiments, and identical and similar parts between the embodiments are all enough to be referred to each other.
It will be apparent to those skilled in the art that embodiments of the present application may be provided as a method, apparatus, or computer program product. Accordingly, embodiments of the present application may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, embodiments of the application may take the form of a computer program product on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) having computer-usable program code embodied therein.
Embodiments of the present application are described with reference to flowchart illustrations and/or block diagrams of methods, terminal devices (systems), and computer program products according to embodiments of the application. It will be understood that each flow and/or block of the flowchart illustrations and/or block diagrams, and combinations of flows and/or blocks in the flowchart illustrations and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing terminal device to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing terminal device, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
While preferred embodiments of the present application have been described, additional variations and modifications in those embodiments may occur to those skilled in the art once they learn of the basic inventive concepts. It is therefore intended that the following claims be interpreted as including the preferred embodiment and all such alterations and modifications as fall within the scope of the embodiments of the application.
Finally, it is further noted that relational terms such as first and second, and the like are used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Moreover, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or terminal that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or terminal. Without further limitation, an element defined by the phrase "comprising one … …" does not exclude the presence of other like elements in a process, method, article, or terminal device that comprises the element.
The foregoing has described in detail the method and apparatus for hard disk control, and specific examples have been presented herein to illustrate the principles and embodiments of the present application, the above description of embodiments being only for the purpose of aiding in the understanding of the method and core idea of the present application; meanwhile, as those skilled in the art will have variations in specific embodiments and application scope in light of the ideas of the present application, the present description should not be construed as limiting the present application.

Claims (10)

1. The hard disk control method is characterized by being applied to a first baseboard management controller, wherein the first baseboard management controller is positioned in a first system; the method comprises the following steps:
detecting whether the first system is in an abnormal state;
sending a take-over request to a second baseboard management controller of a second system under the condition that the first system is in an abnormal state;
And releasing control authority of a multiplexer of the first system; the second baseboard management controller switches the uplink opening and closing states of the first expander of the first system through the multiplexer according to the takeover request, and then controls the first hard disk of the first system;
the upstream port of the first expander comprises a first upstream port of the first expander and a second upstream port of the first expander, the first upstream port of the first expander is configured to be controlled by the first system, and the second upstream port of the first expander is configured to be controlled by the second system.
2. The method of claim 1, wherein a takeover request signal endpoint in a first interface module of the first system is connected to a takeover interrupt signal endpoint of a second interface module of the second system;
And sending a take-over request to a second baseboard management controller of a second system under the condition that the first system is in an abnormal state, wherein the take-over request comprises the following steps:
Transmitting a take-over request signal to the second interface module through the first interface module;
converting the takeover request signal into a takeover interrupt signal through the takeover request signal endpoint and the takeover interrupt signal endpoint; and transmitting the takeover interrupt signal to the second baseboard management controller.
3. The hard disk control method according to claim 2, wherein the releasing the control authority to the multiplexer of the first system includes:
And enabling the I2C channel connected with the multiplexer by the second baseboard management controller to be effective and enabling the I2C channel connected with the multiplexer by the first baseboard management controller to be ineffective by controlling the gating signal of the multiplexer.
4. The hard disk control method according to claim 1, wherein after releasing the control authority for the multiplexer, the method further comprises:
Forwarding, by the multiplexer, a switching signal sent by the second baseboard management controller to the first expander; and the first expander closes the first uplink port of the first expander according to the switching signal, and opens the second uplink port of the first expander.
5. The hard disk control method according to claim 1, wherein the detecting whether the first system is in an abnormal state comprises:
Detecting whether the communication between the operating system of the first system and the first baseboard management controller is abnormal or not;
And determining that the first system is in an abnormal state under the condition that the operating system of the first system is abnormal in communication with the first baseboard management controller.
6. The method according to any one of claims 1 to 5, wherein the first upstream port of the first expander is connected to a first interface of a first HBA card of the first system;
the second uplink port of the first expander is connected with a second interface of a second HBA card of the second system through a first interface module of the first system and a second interface module of the second system;
The second interface of the first HBA card of the first system is connected with a second upstream port of a second expander of the second system through a first interface module of the first system and a second interface module of the second system;
A first uplink port of a second expander of the second expander is connected with a first interface of a second HBA card of the second system;
The method further comprises the steps of:
Under the condition that the first system and the second system are in a normal state, a first uplink port of the first expander and a first uplink port of the second expander are opened, a second uplink port of the first expander and a second uplink port of the second expander are closed, so that the first system controls the first hard disk through the first expander, and the second system controls the second hard disk of the second system through the second expander.
7. The hard disk control method is characterized by being applied to a second baseboard management controller, wherein the second baseboard management controller is positioned in a second system; the method comprises the following steps:
Receiving a take-over request, wherein the take-over request is sent to the second baseboard management controller by the first baseboard management controller of the first system under the condition that the first system is in an abnormal state;
switching an uplink port switching state of a first expander of the first system through a multiplexer of the first system according to the takeover request; the control authority of the multiplexer is obtained after the first baseboard management controller is released under the condition that the first system is in an abnormal state;
controlling a first hard disk of the first system according to the first expander after the uplink port switch state is switched;
the upstream port of the first expander comprises a first upstream port of the first expander and a second upstream port of the first expander, the first upstream port of the first expander is configured to be controlled by the first system, and the second upstream port of the first expander is configured to be controlled by the second system.
8. The method of claim 7, wherein a takeover request signal endpoint in a first interface module of the first system is connected to a takeover interrupt signal endpoint of a second interface module of the second system;
the receiving a take over request includes:
receiving a take-over interrupt signal transmitted to the second baseboard management controller by the second interface module; the take-over interrupt signal is obtained by converting the take-over request signal sent by the first interface module to the second interface module through the take-over request signal endpoint and the take-over interrupt signal endpoint.
9. The hard disk control method according to claim 7, wherein switching the upstream port switching state of the first expander of the first system by the multiplexer of the first system according to the takeover request comprises:
According to the takeover request, a switching signal is sent to the multiplexer;
And forwarding the switching signal to the first expander through the multiplexer so that the first expander closes a first uplink port of the first expander and opens a second uplink port of the first expander according to the switching signal.
10. A hard disk control device, characterized in that the device comprises:
A first system, comprising:
A first hard disk, a multiplexer, a first expander, and a first baseboard management controller; the first baseboard management controller is configured to execute the hard disk control method of any one of claims 1 to 6;
A second system, comprising:
And the second baseboard management controller is used for controlling the first hard disk under the condition that the first system is in an abnormal state.
CN202410382437.XA 2024-03-29 2024-03-29 Hard disk control method and device Pending CN118132471A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202410382437.XA CN118132471A (en) 2024-03-29 2024-03-29 Hard disk control method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202410382437.XA CN118132471A (en) 2024-03-29 2024-03-29 Hard disk control method and device

Publications (1)

Publication Number Publication Date
CN118132471A true CN118132471A (en) 2024-06-04

Family

ID=91233511

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202410382437.XA Pending CN118132471A (en) 2024-03-29 2024-03-29 Hard disk control method and device

Country Status (1)

Country Link
CN (1) CN118132471A (en)

Similar Documents

Publication Publication Date Title
US9298566B2 (en) Automatic cluster-based failover handling
JP5561622B2 (en) Multiplexing system, data communication card, state abnormality detection method, and program
JPH11232237A (en) Information processor having crossbar switch and method for controlling crossbar switch
US11573737B2 (en) Method and apparatus for performing disk management of all flash array server
JP3537281B2 (en) Shared disk type multiplex system
JP2004021556A (en) Memory control device and control process thereof
CN111767244A (en) Dual-redundancy computer equipment based on domestic Loongson platform
CN103475695A (en) Interconnection method and device for storage system
KR920004413B1 (en) Master slane type control system
CN110675614A (en) Transmission method of power monitoring data
CN116661688B (en) Service response method and device of SAS storage system
CN118132471A (en) Hard disk control method and device
WO2021238579A1 (en) Method for managing sata hard disk by means of storage system, and storage system
CN101145955A (en) Hot backup method, network management and network management system of network management software
CN114968873A (en) PCIE data exchange device
JP5176914B2 (en) Transmission device and system switching method for redundant configuration unit
CN110442094B (en) Distributed system arbitration method and device
CN112463670A (en) Storage controller access method and related device
JP2020086805A (en) Information processing system and information processing device
KR100440588B1 (en) Status Recognition and Alarm Device of Serial Bus Type Supporting hierarchical Structure
CN113345495B (en) Server and related control method
CN117094038B (en) Programmable logic device and server
CN113342260B (en) Server and control method applied to server
CN113190184B (en) Hardware cluster device and storage equipment management method
KR960010879B1 (en) Bus duplexing control of multiple processor

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination