CN111142779B - Device information providing method for cluster storage system - Google Patents

Device information providing method for cluster storage system Download PDF

Info

Publication number
CN111142779B
CN111142779B CN201811306560.4A CN201811306560A CN111142779B CN 111142779 B CN111142779 B CN 111142779B CN 201811306560 A CN201811306560 A CN 201811306560A CN 111142779 B CN111142779 B CN 111142779B
Authority
CN
China
Prior art keywords
hard disk
expansion interface
name
host
address
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.)
Active
Application number
CN201811306560.4A
Other languages
Chinese (zh)
Other versions
CN111142779A (en
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.)
Mitac Computer Shunde Ltd
Mitac Computing Technology Corp
Original Assignee
Mitac Computer Shunde Ltd
Mitac Computing Technology Corp
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 Mitac Computer Shunde Ltd, Mitac Computing Technology Corp filed Critical Mitac Computer Shunde Ltd
Priority to CN201811306560.4A priority Critical patent/CN111142779B/en
Publication of CN111142779A publication Critical patent/CN111142779A/en
Application granted granted Critical
Publication of CN111142779B publication Critical patent/CN111142779B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0602Interfaces specially adapted for storage systems specifically adapted to achieve a particular effect
    • G06F3/0604Improving or facilitating administration, e.g. storage management
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0628Interfaces specially adapted for storage systems making use of a particular technique
    • G06F3/0629Configuration or reconfiguration of storage systems
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0668Interfaces specially adapted for storage systems adopting a particular infrastructure
    • G06F3/0671In-line storage system
    • G06F3/0683Plurality of storage devices
    • G06F3/0689Disk arrays, e.g. RAID, JBOD

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Human Computer Interaction (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Debugging And Monitoring (AREA)

Abstract

A device information providing method of cluster storage system includes the following steps: a host executes a first instruction to obtain the universal device name corresponding to each hard disk expansion interface and the hard disk; the host executes a second instruction according to the universal device name of each hard disk expansion interface to obtain the name of the storage equipment where the hard disk expansion interface is located; the host executes a third instruction according to the universal device name of each hard disk to obtain the address of each hard disk; the host executes a fourth instruction according to the universal device name of each hard disk expansion interface to obtain the address of the hard disk expansion interface and the address of each hard disk connected with the hard disk expansion interface; the host generates hard disk corresponding information including the name of the storage device where the hard disk expansion interface to which each hard disk is connected according to the information obtained in the above steps.

Description

Device information providing method for cluster storage system
[ field of technology ]
The present invention relates to a method for providing device information of a storage system, and more particularly to a method for providing device information of a clustered storage system.
[ background Art ]
The conventional cluster storage system comprises a host, a disk array card electrically connected with the host, and at least one storage device electrically connected with the disk array card. The host is provided with a Linux operating system for operating the host and the at least one storage device. Each storage device is, for example, a simple disk binding disk server (just a bunch of disks, JBOD) and includes at least one hard disk expansion interface (expander), a plurality of hard disks each having at least one unique address and electrically connected to the at least one hard disk expansion interface, and a plurality of device slots each for mounting the hard disks.
In the cluster storage system, the acquisition of the connection correspondence between the storage devices and the hard disk can help the system manager to manage and maintain the hard disk, and also help the system manager to determine which storage devices are to be allocated as main storage devices and which storage devices are to be allocated as backup storage devices. However, for each hard disk installed in the cluster storage system, if the corresponding relationship between each hard disk and the at least one storage device is to be known, the corresponding relationship can only be obtained by manual query, which is inconvenient in practice.
[ invention ]
The present invention provides a device information providing method for clustered storage system to obtain related device information of hard disk installed in clustered storage system.
In order to solve the above-mentioned problems, the present invention provides a device information providing method of a clustered storage system, which is suitable for providing device information of a clustered storage system, the clustered storage system includes a host, a disk array card electrically connected to the host, and at least one storage device electrically connected to the disk array card, the host is installed with an operating system for operating the host and the storage device, each storage device includes at least one hard disk expansion interface, and a plurality of hard disks each electrically connected to the at least one hard disk expansion interface and each having at least one unique address, each hard disk expansion interface corresponds to a generic device name in the operating system, and all hard disk expansion interfaces correspond to a same logical device name in the operating system, each hard disk corresponds to at least one generic device name in the operating system, the device information providing method of the clustered storage system includes the steps of:
(A) The host executes a first instruction corresponding to the mapping of the device and the name in the operating system according to the same logical equipment name of the hard disk expansion interfaces so as to obtain a universal device name corresponding to each hard disk expansion interface;
(B) The host executes the first instruction to obtain a generic device name corresponding to each hard disk;
(C) The host executes a second instruction related to the hard disk expansion interface and the storage device in the operating system according to the universal device name corresponding to the hard disk expansion interface,
obtaining the name of the storage device where the hard disk expansion interface is located;
(D) The host executes a third instruction related to the hard disk information acquired in the operating system according to the universal device name corresponding to each hard disk to acquire the address of the hard disk;
(E) The host executes a fourth instruction related to the hard disk expansion interface and the hard disk in the operating system according to the name of the universal device corresponding to the hard disk expansion interface so as to obtain the address of the hard disk expansion interface and the address of each hard disk connected with the hard disk expansion interface; a kind of electronic device with high-pressure air-conditioning system
(F) The host generates a piece of hard disk corresponding information according to the common device names of the hard disk expansion interfaces, the names of the storage devices where the hard disk expansion interfaces are located, the address of each hard disk expansion interface and the address of the corresponding hard disk, and the common device names of the hard disks, wherein the hard disk corresponding information comprises the names of the storage devices where the hard disk expansion interfaces connected to each hard disk are located.
Compared with the prior art, the invention generates the corresponding information of the hard disk by the host according to the names of the universal devices of the hard disk expansion interfaces, the names of the storage devices where the hard disk expansion interfaces are positioned, the address of each hard disk expansion interface and the address of the corresponding hard disk, and the names of the universal devices of the hard disks, so as to obtain the related device information such as the names of the storage devices where the hard disk expansion interfaces connected with each hard disk are positioned.
[ description of the drawings ]
FIG. 1 is a block diagram illustrating a clustered storage system implementing an embodiment of a device information providing method of a clustered storage system of the present invention;
FIG. 2 is a flowchart illustrating a hard disk correspondence information generating process in an embodiment of a device information providing method of a clustered storage system according to the present invention;
FIG. 3 is a flowchart illustrating a redundancy function determination procedure in an embodiment of a device information providing method of a clustered storage system according to the present invention; a kind of electronic device with high-pressure air-conditioning system
FIG. 4 is a flowchart illustrating an abnormal hard disk location procedure in an embodiment of a device information providing method of a clustered storage system according to the present invention.
[ detailed description ] of the invention
Referring to fig. 1, an embodiment of a device information providing method of a clustered storage system according to the present invention is adapted to provide device information of a clustered storage system and is performed by the clustered storage system. The clustered storage system comprises a host 10, a disk array (Redundant Array of Inexpensive Disks, RAID) card 12 electrically connected to the host 10, and two storage devices J1, J2. The host 10 is a computer and is equipped with a Linux operating system to operate the host 10 itself and the storage devices J1, J2. It should be noted that, in the present embodiment, the number of storage devices J1, J2 of the cluster storage system is two, however, the number of storage devices J1, J2 of the cluster storage system may be one or more than three.
Each storage device J1, J2 is a simple disk binding disk server (Just a Bunch of Disks, JBOD for short). One of the storage devices J1 and J2J 1 includes two hard disk expansion interfaces 13 (expanders), twenty-four hard disks electrically connected to the hard disk expansion interfaces 13, twenty-four device slots 11 for respectively installing the hard disks and respectively corresponding to a slot number, and twenty-four warning lamps (not shown) respectively corresponding to the device slots 11. Each hard disk expansion interface 13 corresponds to a generic device name (generic device name) in Linux and has an address, here a serial small computer system interface (Serial Attached SCSI, SAS) address; and all the hard disk expansion interfaces 13 correspond to the same logical device name (logical device name), i.e. "13", in Linux, and each hard disk included in the storage device J1 has two SAS ports (ports), and when the SAS ports are connected to the host 10 through the hard disk expansion interface of the storage device J1, the host 10 assigns a unique serial small computer system interface (SAS) address to the hard disk for each SAS port; since each hard disk contained in the storage device J1 is connected to the host through the two SAS ports, each hard disk has two unique SAS addresses; furthermore, each hard disk contained in the storage device J1 corresponds to two generic device names and two logical device names in Linux, and corresponds to a unique hard disk product serial number. For example, as shown in fig. 1, the common device names of the hard disk expansion interfaces 13 included in the storage apparatus J1 are "sg 24" and "sg 49", respectively; "sg 1" and "sg 26" are common device names corresponding to the same hard disk, and "sg 0" and "sg 25" are common device names corresponding to the same hard disk, and so on.
The other one of the storage devices J1, J2 includes a hard disk expansion interface 13 (expander), twenty-four hard disks electrically connected to the hard disk expansion interface 13, twenty-four device slots 11 for respectively installing the hard disks and respectively corresponding to a slot number, twenty-four warning lamps (not shown) respectively corresponding to the device slots 11, wherein the hard disk expansion interface 13 corresponds to a common device name (generic device name) in Linux and has a SAS address; and the corresponding logical device name (logical device name) of the hard disk expansion interface 13 in the other storage device J2 in Linux is the same as the corresponding logical device name in the hard disk expansion interface 13 in the storage device J1, and is "13", in addition, although each hard disk included in the other storage device J2 has two SAS ports (ports), each hard disk included in the storage device J2 is connected to the host only through one of the two SAS ports, so the host 10 assigns only one unique serial small computer system interface (SAS) address corresponding to the connected SAS port to the hard disk, so each hard disk in the other storage device J2 has only one SAS address, and all SAS addresses of the hard disks are different; in addition, each hard disk contained in the other storage device J2 corresponds to only one generic device name and one logical device name in Linux, and corresponds to a unique hard disk product serial number. For example, as shown in fig. 1, the generic device name of the hard disk expansion interface 13 contained in the other storage apparatus J2 is "sg 74"; the "sg 50" to "sg 73" are common device names corresponding to the 24 hard disks, respectively.
The warning lamp corresponding to each device slot 11 is controlled by a hard disk expansion interface 13 connected with a hard disk arranged in the device slot 11; and each warning lamp is arranged near the corresponding device groove 11, so that when the warning lamp is lightened, the position of the device groove 11 corresponding to the warning lamp can be indicated by the warning lamp.
As shown in fig. 1, the host 10 is connected to the hard disk expansion interface 13 of each storage device J1, J2 through the disk array card 12. However, it should be specifically noted that the connection manner between the host 10 and the storage devices J1 and J2, the number of the storage devices J1 and J2, and the number of the hard disk expansion interfaces 13 and the hard disks in the storage devices J1 and J2 are not limited to the above embodiments, and the device information providing method of the clustered storage system of the present invention is applicable to various existing Linux-based clustered storage systems.
The following describes the procedure of the device information providing method of the clustered storage system according to the present invention, which includes a hard disk correspondence information generating program, a redundancy function determining program and an abnormal hard disk positioning program in sequence. It should be noted that the device information providing method of the clustered storage system of the present invention is performed when the disk array card 12 is switched to JBOD mode by software.
Referring to fig. 1 and 2, the clustered storage system implements a hard disk correspondence information generation procedure of the device information providing method of the clustered storage system of the present invention. The hard disk correspondence information generating program describes how to generate a hard disk correspondence information, and includes the following steps.
First, in step 201, the host 10 executes a first instruction corresponding to mapping between devices and names in the Linux operating system according to the same logical device names ("13") of the hard disk expansion interfaces 13 of the storage devices J1 and J2 to obtain a generic device name corresponding to each hard disk expansion interface 13. In this embodiment, the first instruction is sg_map, and the host 10 executes "sg_map-x|grep13$" on Linux to obtain the generic device names corresponding to the hard disk expansion interfaces 13 listed in the following list. Note that the names of the common devices listed in table one are used only for convenience of description in the present specification, and are not actually used in Linux.
List one
Universal device name corresponding to hard disk expansion interface Logical equipment name corresponding to hard disk expansion interfaceWeighing scale
sg24
13
sg49 13
sg74 13
Next, in step 202, the host 10 executes the first instruction to obtain a generic device name corresponding to each hard disk. In this embodiment, the host 10 can obtain the common device names and the logical device names corresponding to the hard disks listed in the following two list by executing "sg_map-x-i|awk '{ print $0" "$6}' |grep 13$ -v" on Linux. Because each hard disk in the storage apparatus J1 is connected to two hard disk expansion interfaces 13 through two SAS ports, each hard disk in the storage apparatus J1 corresponds to two common device names and two logical device names, for example, referring to fig. 1, the hard disk corresponding to the common device name "sg 0" and the hard disk corresponding to the common device name "sg 25" are the same hard disk, the hard disk corresponding to the common device name "sg 1" and the hard disk corresponding to the common device name "sg 26" are the same hard disk, and so on; referring to table two, the hard disk corresponding to the logical device name "sda" and the hard disk corresponding to the logical device name "sdy" are the same hard disk, the hard disk corresponding to the logical device name "sdb" and the hard disk corresponding to the logical device name "sdz" are the same hard disk, etc., so that each hard disk in the other storage device J2 is connected to a hard disk expansion interface 13 through an SAS port, so that each hard disk in the other storage device J2 corresponds to a generic device name and a logical device name, for example, referring to fig. 1, the "sg 50" to "sg 73" are the generic device names corresponding to the 24 hard disks, respectively; referring to Table II, the names "sdaw" to "sdbt" are common device names corresponding to the 24 hard disks, respectively. It should be noted that the names of the common device names and the logical device names listed in table two are used only for convenience of description in the present specification, and are not actual names in Linux.
Watch II
Figure GDA0004112616650000051
Next, in step 203, the host 10 executes a second instruction related to the hard disk expansion interface 13 and the storage devices J1 and J2 in the Linux operating system according to the generic device name corresponding to the hard disk expansion interface 13 for each hard disk expansion interface 13, so as to obtain the name of the storage device J1/J2 where the hard disk expansion interface 13 is located. In this embodiment, the second instruction is sg_ses, and as shown in the following list three, the host 10 obtains the name of the storage device J1/J2 where the hard disk expansion interface 13 corresponding to the generic device name "sg 24" is located by executing "sg_ses-p 1{ sg24} |grep-i" identifier "on Linux, and similarly, the host 10 obtains the name of the storage device J1/J2 where the hard disk expansion interface 13 corresponding to the generic device names" sg49 "and" sg74 "are located by executing" sg_ses-p 1{ sg49} |grep-i "identifier" and "sg_ses-p 1{ grep-i" on Linux, respectively. It should be noted that the names of the general devices and the names of the storage devices J1 and J2 listed in table three are used for convenience of description in the present specification, and are not actual names in Linux.
Watch III
Figure GDA0004112616650000052
Figure GDA0004112616650000061
/>
Next, in step 204, the host 10 executes a third instruction related to obtaining hard disk information in the Linux operating system according to the generic device name corresponding to the hard disk for each hard disk to obtain the SAS address of the hard disk. In this embodiment, the third instruction is sg_ vpd. As shown in the following Table IV, the host 10 obtains the hard disk SAS address corresponding to the hard disk common device name "sg 0" by executing "sg_ vpd-pdi_port sg0|grep-E-o [0-9a-f ] {16 }" on Linux; similarly, the host 10 may obtain the hard disk SAS address corresponding to the other hard disk generic device name by executing sg_ vpd.
Table four
Figure GDA0004112616650000062
Next, in step 205, the host 10 executes a fourth instruction related to the hard disk expansion interface and the hard disk in the Linux operating system according to the generic device name corresponding to the hard disk expansion interface 13 for each hard disk expansion interface 13 to obtain the address of the hard disk expansion interface 13, the SAS address of each hard disk connected to the hard disk expansion interface 13, and the slot number corresponding to the SAS address. In the present embodiment, the fourth instruction is sg_ses, and as shown in the following list five, the host 10 obtains the address of the hard disk expansion interface 13 corresponding to the generic device name "sg 24", the SAS address of each hard disk connected to the hard disk expansion interface 13 corresponding to the generic device name "sg 24", and the slot number corresponding to the SAS address by executing "sg_ses-p 0x0a sg49 i grep i address" and "sg_ses-p 0x0a sg74 i grep i address" on Linux, respectively, and similarly, the host 10 can obtain the addresses corresponding to the generic device names "sg 49" and "sg 74", the SAS address of the hard disk connected thereto, and the slot number corresponding to the SAS address by executing "sg_ses-p 0a sg49 i address" and "sg_0 a sg74 i address" on Linux, respectively. Because each hard disk in the storage device J1 is connected to two hard disk expansion interfaces 13 through two SAS ports, and each hard disk in the storage device J2 is connected to one hard disk expansion interface 13 through one SAS port, seventy-two hard disk SAS addresses are listed in table two, and each hard disk expansion interface 13 corresponds to twenty-four hard disk SAS addresses. Note that the names of the universal device names, the hard disk expansion interface SAS addresses, the hard disk SAS addresses, and the slot numbers listed in table five are used only for convenience of description in the present specification, and are not actual names in Linux.
TABLE five
Figure GDA0004112616650000071
Next, in step 206, for each hard disk, the host 10 executes a fifth instruction related to the information of the hard disk in the Linux operating system according to the generic device name corresponding to the hard disk, so as to obtain the hard disk product serial number of the hard disk. In this embodiment, the fifth instruction is sg_inq. As shown in the following Table six, the host 10 obtains the hard disk product number of the hard disk corresponding to the common device name "sg 0" by executing "sg_inq sg 0" on Linux; similarly, the host 10 can obtain the hard disk product serial number of the hard disk corresponding to the other hard disk generic device name by executing sg_inq. Each hard disk corresponds to a unique hard disk product serial number, that is, although the same hard disk may have different logical device names and different common device names, the hard disk product serial number of the same hard disk is unique, so it is known from the sixth table that the hard disk corresponding to the common device name "sg 1" and the hard disk corresponding to the common device name "sg 26" are the same hard disk, the hard disk corresponding to the common device name "sg 0" and the hard disk corresponding to the common device name "sg 25" are the same hard disk, and so on. It should be noted that the naming of the hard disk product numbers listed in table six is used only for convenience of description in the present specification, and is not an actual naming in Linux.
TABLE six
Figure GDA0004112616650000081
Next, in step 207, the host 10 executes a sixth instruction related to information of the raid card 12 in the Linux operating system to obtain the port number of the raid card 12 connected to each of the hard disk expansion interfaces 13. In this embodiment, the sixth instruction is MegaCli, and as shown in the following table seven, the host 10 obtains the port number of the disk array card 12 to which each hard disk expansion interface 13 is connected by executing "MegaCli 64-adpalilfo-aALL" on Linux.
Watch seven
Port number of disk array card SAS address of hard disk expansion interface
0 X00
1 X01
2 X02
Finally, in step 208, the host 10 uses the common device name of each hard disk expansion interface 13 as an association element, integrates the information listed in table three and table five, uses the SAS address of each hard disk as an association element, integrates the information listed in table four and table six, uses the common device name of each hard disk as an association element, integrates the SAS address of each hard disk expansion interface 13 as an association element, and integrates the information listed in table five and table seven to obtain the corresponding hard disk information including the information listed in table eight, wherein the corresponding hard disk information includes the name of the storage device J1/J2 where each hard disk expansion interface 13 is located, the common device name corresponding to each hard disk expansion interface 13, the common device name corresponding to each hard disk connected to each hard disk expansion interface 13, the hard disk product serial number corresponding to each hard disk, the SAS address corresponding to each hard disk, the slot number corresponding to the SAS address of each hard disk expansion interface 13, and the disk port number of the array connected to each hard disk expansion interface 13. Referring to Table five together with FIG. 1, it can be seen that logical device names "sg 0" and "sg 25" correspond to the same hard disk, so that both correspond to the same slot number "S1" and the same hard disk product number "00000"; logical device names "sg 1" and "sg 26" correspond to the same hard disk, so that both correspond to the same slot number "S0" and the same hard disk product number "00001", etc.
Table eight
Figure GDA0004112616650000091
Figure GDA0004112616650000101
Referring to fig. 1 and 3, the clustered storage system implements a redundancy function determination procedure of the device information providing method of the clustered storage system of the present invention. The redundancy function determination program describes how to determine whether each storage device J1, J2 provides a redundancy function, and includes the following steps.
In step 301, the host 10 determines whether each storage device J1, J2 provides a backup function according to the hard disk correspondence information. For each storage device J1, J2, the host 10 determines whether the storage device J1/J2 provides a backup function by determining whether the names of the storage devices J1/J2 in the hard disk correspondence information correspond to two hard disks having the same hard disk product serial number but different common device names.
Finally, in step 302, the host 10 records the spare capacity status corresponding to each storage device J1, J2 according to the determination result of each storage device J1, J2 in step 301. When the host 10 determines that the name of the storage device J1/J2 in the corresponding information of the hard disk corresponds to two hard disks having the same hard disk product serial number but different common device names, it determines that the storage device J1/J2 has a backup function, so that the backup capability status of the storage device J1/J2 recorded by the host 10 indicates that the storage device J1/J2 has a backup capability; when the host 10 determines that the name of the storage device J1/J2 in the corresponding information of the hard disk does not correspond to two hard disks having the same hard disk product serial number but different common device names, it determines that the storage device J1/J2 does not have a spare function, so that the spare capability status of the storage device J1/J2 recorded by the host 10 indicates that the storage device J1/J2 does not have a spare capability.
Referring to fig. 1 and 4, the clustered storage system implements an abnormal hard disk positioning procedure of the device information providing method of the clustered storage system of the present invention. The abnormal hard disk positioning program describes how to position each abnormal hard disk and includes the following steps.
In step 401, the host 10 executes a test procedure to detect whether at least one of the hard disks is abnormal, wherein the determination of the abnormal operation of the hard disk may be, for example, "read/write command under the hard disk according to the common device name corresponding to the hard disk", and if the hard disk corresponding to the common device name is wrong in reading/writing data, the abnormal operation of the hard disk corresponding to the common device name may be determined. When the host 10 detects that the at least one hard disk is abnormal, the process proceeds to step 402; when the host 10 detects that there is no abnormal operation of the at least one hard disk, the process returns to step 401.
Next, in step 402, for each abnormal operation hard disk, the host 10 determines the common device name corresponding to the hard disk expansion interface 13 connected to the abnormal operation hard disk and the slot number corresponding to the abnormal operation hard disk according to the common device name corresponding to the abnormal operation hard disk and the corresponding information of the hard disk. For example, as shown in the above list eight, when the host 10 detects the abnormal operation of the hard disk corresponding to the generic device name "sg 0", the generic device name "sg 24" corresponding to the hard disk expansion interface 13 connected to the abnormal operation of the hard disk can be rapidly determined by the information listed in the lookup table eight, and the slot number "S1" corresponding to the abnormal operation of the hard disk.
Next, in step 403, for each hard disk with abnormal operation, the host 10 executes a seventh instruction related to lighting the warning lamp according to the universal device name of the hard disk expansion interface 13 corresponding to the hard disk with abnormal operation and the slot number corresponding to the hard disk with abnormal operation, so that the hard disk expansion interface 13 connected to the hard disk with abnormal operation controls the warning lamp corresponding to the device slot 11 with abnormal operation to be lighted. In this embodiment, the seventh instruction is sg_sendbias. In the above example and referring to fig. 1, when the host 10 detects that the hard disk corresponding to the generic device name "sg 0" is abnormal, the hard disk expansion interface 13 corresponding to the generic device name "sg 24" can control the alarm lamp corresponding to the device slot 11 (S1) in which the hard disk corresponding to the generic device name "sg 0" is installed to illuminate by executing "sg_sendiag-pf-r 2,0,0,0c,0,0,0,0,0,0,0,0,80,0,0,20sg24 S1" on Linux, so as to indicate the installation position of the hard disk having the abnormal operation.
In addition, in another embodiment, the method for determining the installation location of an abnormal hard disk in a clustered storage system of the present invention has its efficacy when the storage devices J1, J2 do not have the warning lamps and the step 403 is not performed. For example, step 402 may be modified in implementation to determine, based on the common device name corresponding to the hard disk with abnormal operation and the information corresponding to the hard disk, not only the common device name corresponding to the hard disk expansion interface 13 connected to the hard disk with abnormal operation and the slot number corresponding to the hard disk with abnormal operation, but also the name of the storage device J1/J2 corresponding to the hard disk expansion interface 13 connected to the hard disk with abnormal operation, and generate a warning output related to the common device name corresponding to the hard disk expansion interface 13 connected to the hard disk with abnormal operation, the name of the storage device J1/J2 corresponding to the hard disk expansion interface 13 connected to the hard disk with abnormal operation, and the slot number of the device slot 11 in which the preset hard disk is installed, so that a manager can quickly find the installation position of the hard disk with abnormal operation according to the warning output.
In summary, according to the device information providing method of the cluster storage system of the present invention, the host 10 generates the corresponding information of the hard disk including the information listed in table eight by integrating the information obtained by the instructions such as sg_map, sg_ses, sg_vpd, sg_inq, and MegaCLI on Linux, so that when the host 10 detects the hard disk operating abnormally by executing the test program, the general device name of the hard disk expansion interface 13 connected to the hard disk operating abnormally, the name of the storage device J1/J2 where the hard disk expansion interface 13 connected to the hard disk operating abnormally, and the slot number of the device slot 11 in which the hard disk operating abnormally is installed can be rapidly judged according to the corresponding information of the hard disk, thereby achieving the purpose of locating the position of the hard disk operating abnormally. In addition, the number of the storage devices J1 and J2 mounted on the disk array card 12 and the relationship between each storage device J1 and J2 and the hard disk thereof can be obtained by the corresponding information of the hard disk, and the spare capacity of which storage devices can be obtained, so that the manager can be assisted in determining which storage devices are to be allocated as the main storage device and which storage devices are to be allocated as the spare storage device, thereby achieving the purpose of the present invention.
The foregoing is merely illustrative of the present invention, and the present invention is not limited thereto, and any person skilled in the art will readily recognize that variations or substitutions are within the scope of the present invention. Therefore, the protection scope of the invention is subject to the protection scope of the claims.

Claims (10)

1. The clustered storage system device information providing method is suitable for providing clustered storage system device information, the clustered storage system comprises a host, a disk array card electrically connected with the host and at least one storage device electrically connected with the disk array card, the host is provided with an operating system for operating the host and the storage device, each storage device comprises at least one hard disk expansion interface, and a plurality of hard disks which are electrically connected with the at least one hard disk expansion interface and respectively have at least one unique address, each hard disk expansion interface corresponds to a common device name in the operating system, all hard disk expansion interfaces correspond to the same logical device name in the operating system, and each hard disk corresponds to at least one common device name in the operating system, and the clustered storage system device information providing method comprises the following steps:
(A) The host executes a first instruction corresponding to the mapping of the device and the name in the operating system according to the same logical equipment name of the hard disk expansion interface so as to obtain a universal device name corresponding to each hard disk expansion interface;
(B) The host executes the first instruction to obtain a generic device name corresponding to each hard disk;
(C) The host executes a second instruction related to the hard disk expansion interface and the storage equipment in the operating system according to the name of the universal device corresponding to the hard disk expansion interface aiming at each hard disk expansion interface so as to obtain the name of the storage equipment where the hard disk expansion interface is located;
(D) The host executes a third instruction related to the hard disk information acquired in the operating system according to the universal device name corresponding to each hard disk to acquire the address of the hard disk;
(E) The host executes a fourth instruction related to the hard disk expansion interface and the hard disk in the operating system according to the name of the universal device corresponding to the hard disk expansion interface so as to obtain the address of the hard disk expansion interface and the address of each hard disk connected with the hard disk expansion interface; a kind of electronic device with high-pressure air-conditioning system
(F) The host generates a corresponding information of the hard disk according to the general device name of the hard disk expansion interface, the name of the storage device where the hard disk expansion interface is located, the address of each hard disk expansion interface and the address of the corresponding hard disk, and the general device name of the hard disk, wherein the corresponding information of the hard disk comprises the name of the storage device where the hard disk expansion interface connected to each hard disk is located.
2. The device information providing method of a clustered storage system according to claim 1, wherein each hard disk corresponds to a unique hard disk product serial number, the device information providing method of a clustered storage system further comprising the steps of:
(G) The host executes a fifth instruction related to the inquiry of the hard disk information in the operating system according to the universal device name corresponding to each hard disk to obtain the hard disk product serial number of the hard disk;
in the step (F), the host computer further generates the corresponding information of the hard disk according to the hard disk product serial number of the hard disk, so that the corresponding information of the hard disk includes the hard disk product serial number of each hard disk; a kind of electronic device with high-pressure air-conditioning system
(H) The host computer judges whether each storage device provides a backup function according to the corresponding information of the hard disk.
3. The device information providing method of clustered storage system according to claim 2, wherein in the step (H), for each storage device, the host determines whether the storage device provides a spare function by determining whether the name of the storage device in the hard disk correspondence information corresponds to two hard disks having the same hard disk product serial number but different common device names.
4. The device information providing method of clustered storage system of claim 2 wherein the operating system is Linux and the fifth instruction is sg_inq.
5. The device information providing method of a cluster storage system according to claim 1, further comprising the steps of, after step (E):
(I) The host executes a sixth instruction related to the information of the query disk array card in the operating system so as to obtain the port number of the disk array card connected with each hard disk expansion interface;
in the step (F), the host computer further generates the corresponding information of the hard disk according to the port number of the disk array card connected to the hard disk expansion interface, so that the corresponding information of the hard disk includes the port number of the disk array card corresponding to the hard disk expansion interface connected to each hard disk.
6. The device information providing method of clustered storage system of claim 5 wherein said operating system is Linux and said sixth instruction is MegaCLI instruction.
7. The device information providing method of a cluster type storage system according to claim 1, wherein each storage apparatus further comprises a plurality of device slots for respectively mounting the hard disk and respectively corresponding to a slot number, wherein:
in step (E), the host computer executes the fourth instruction to obtain not only the address of the hard disk expansion interface and the address of each hard disk connected with the hard disk expansion interface, but also a slot number corresponding to the address of each hard disk; a kind of electronic device with high-pressure air-conditioning system
In step (F), the host computer further generates the corresponding information of the hard disk according to the slot number corresponding to the address of each hard disk, so that the corresponding information of the hard disk includes the slot number corresponding to each hard disk.
8. The device information providing method of a clustered storage system of claim 7, further comprising the steps of:
(J) The host computer judges the name of the storage equipment where the hard disk expansion interface connected with the preset hard disk is located, the universal device name of the hard disk expansion interface connected with the preset hard disk and the slot number of the device slot provided with the preset hard disk according to the universal device name of the preset hard disk and the corresponding information of the hard disk generated in the step (F) so as to position the preset hard disk.
9. The device information providing method of a clustered storage system of claim 8, further comprising the steps of:
(K) When the host detects that the preset hard disk is abnormal, the host generates a warning output corresponding to the universal device name corresponding to the hard disk expansion interface connected with the preset hard disk, the name of the storage equipment where the hard disk expansion interface connected with the preset hard disk is located, and the slot number of the device slot provided with the preset hard disk.
10. The device information providing method of claim 1, wherein the operating system is Linux, the first command is sg_map, the third command is sg_ vpd, and the second command and the fourth command are sg_ses.
CN201811306560.4A 2018-11-05 2018-11-05 Device information providing method for cluster storage system Active CN111142779B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811306560.4A CN111142779B (en) 2018-11-05 2018-11-05 Device information providing method for cluster storage system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811306560.4A CN111142779B (en) 2018-11-05 2018-11-05 Device information providing method for cluster storage system

Publications (2)

Publication Number Publication Date
CN111142779A CN111142779A (en) 2020-05-12
CN111142779B true CN111142779B (en) 2023-05-09

Family

ID=70516395

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811306560.4A Active CN111142779B (en) 2018-11-05 2018-11-05 Device information providing method for cluster storage system

Country Status (1)

Country Link
CN (1) CN111142779B (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102207829A (en) * 2011-03-25 2011-10-05 浪潮(北京)电子信息产业有限公司 Disk positioning method and disk positioning device for realizing high-end disk array
CN105700986A (en) * 2014-11-27 2016-06-22 英业达科技有限公司 Server system for monitoring operational information
CN107102695A (en) * 2016-02-22 2017-08-29 佛山市顺德区顺达电脑厂有限公司 The method of the installation position of the abnormal hard disk of judgement for cluster type stocking system
CN107305474A (en) * 2016-04-21 2017-10-31 佛山市顺德区顺达电脑厂有限公司 The stocking system of linking relationship can visually be indicated

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102207829A (en) * 2011-03-25 2011-10-05 浪潮(北京)电子信息产业有限公司 Disk positioning method and disk positioning device for realizing high-end disk array
CN105700986A (en) * 2014-11-27 2016-06-22 英业达科技有限公司 Server system for monitoring operational information
CN107102695A (en) * 2016-02-22 2017-08-29 佛山市顺德区顺达电脑厂有限公司 The method of the installation position of the abnormal hard disk of judgement for cluster type stocking system
CN107305474A (en) * 2016-04-21 2017-10-31 佛山市顺德区顺达电脑厂有限公司 The stocking system of linking relationship can visually be indicated

Also Published As

Publication number Publication date
CN111142779A (en) 2020-05-12

Similar Documents

Publication Publication Date Title
US6883073B2 (en) Virtualized volume snapshot formation method
US6725331B1 (en) Method and apparatus for managing the dynamic assignment resources in a data storage system
US9747036B2 (en) Tiered storage device providing for migration of prioritized application specific data responsive to frequently referenced data
US7275133B2 (en) Storage system
JP5023018B2 (en) Storage system and data management method
US7305670B2 (en) Method of installing software on storage device controlling apparatus, method of controlling storage device controlling apparatus, and storage device controlling apparatus
US7028216B2 (en) Disk array system and a method of avoiding failure of the disk array system
US7660946B2 (en) Storage control system and storage control method
US8086896B2 (en) Dynamically tracking virtual logical storage units
US20080320258A1 (en) Snapshot reset method and apparatus
US20090070541A1 (en) Automated information life-cycle management with thin provisioning
US7958328B2 (en) Computer system, storage system and method for saving storage area by integrating same data
US9846718B1 (en) Deduplicating sets of data blocks
EP0723223A2 (en) Identifying controller pairs in a dual controller disk array
CN107102695B (en) Method for determining mounting position of abnormal hard disk for cluster storage system
US20130061013A1 (en) Storage system, and apparatus and method for controlling storage
US20070245113A1 (en) Storage system and data storage method
US10108362B2 (en) Validation of storage arrays based on information stored in global metadata
US20050010722A1 (en) Multi-volume disk array management method and system
US20060053287A1 (en) Storage apparatus, system and method using a plurality of object-based storage devices
US7840755B2 (en) Methods and systems for automatically identifying a modification to a storage array
JP2015049633A (en) Information processing apparatus, data repair program, and data repair method
CN111142779B (en) Device information providing method for cluster storage system
US7827269B2 (en) System and method for managing networked storage devices with a plurality of logical units
US6996752B2 (en) System, method, and computer program product within a data processing system for converting a spare storage device to a defined storage device in a logical volume

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
GR01 Patent grant
GR01 Patent grant