CN109947622B - Server physical disk positioning method, device, equipment and medium - Google Patents
Server physical disk positioning method, device, equipment and medium Download PDFInfo
- Publication number
- CN109947622B CN109947622B CN201910217477.8A CN201910217477A CN109947622B CN 109947622 B CN109947622 B CN 109947622B CN 201910217477 A CN201910217477 A CN 201910217477A CN 109947622 B CN109947622 B CN 109947622B
- Authority
- CN
- China
- Prior art keywords
- physical disk
- disk
- physical
- flicker
- read
- 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
Links
- 238000000034 method Methods 0.000 title claims abstract description 43
- 238000009434 installation Methods 0.000 claims abstract description 40
- 238000013507 mapping Methods 0.000 claims abstract description 16
- 238000004590 computer program Methods 0.000 claims description 12
- 229910002056 binary alloy Inorganic materials 0.000 description 1
- 238000010586 diagram Methods 0.000 description 1
- 238000005516 engineering process Methods 0.000 description 1
- 230000006870 function Effects 0.000 description 1
- 230000000750 progressive effect Effects 0.000 description 1
Images
Landscapes
- Debugging And Monitoring (AREA)
- Measurement Of Radiation (AREA)
Abstract
The application discloses a server physical disk positioning method, a device, equipment and a medium, wherein a logical disk symbol of each physical disk of a server carries uniquely corresponding coded information, each coded information is N-bit binary codes, N indicator lights are arranged on each physical disk, and the N indicator lights on each physical disk correspond to the N-bit binary codes in the corresponding coded information one by one respectively; the method comprises the following steps: executing N rounds of physical disk read-write operations; recording a flicker statistic result; determining preset flicker characteristics corresponding to the N indicator lamps of each physical disk from a preset mapping table according to the coding information; and searching actual flicker characteristics consistent with the preset flicker characteristics and corresponding disk installation positions from the flicker statistical results, and determining the searched disk installation positions as the installation positions of the corresponding physical disks. Through the technical scheme, the time required for positioning the disk of the server can be effectively reduced.
Description
Technical Field
The present application relates to the field of server technologies, and in particular, to a method, an apparatus, a device, and a medium for locating a physical disk of a server.
Background
Currently, the simplest and most effective method for positioning a physical disk in a server is to use a disk read-write command in the system, for example, a dd command is used to read and write a disk under a linux system, a corresponding read-write indicator lamp is arranged on the disk, the indicator lamp of the disk of the server is checked when the dd command is operated, and the indicator lamp flickers to indicate that the disk is being read and written, so as to position the physical position of the disk.
Although the disk positioning method is simple and effective, and can determine the position of the physical disk corresponding to the logical drive letter very intuitively, the scheme has the disadvantage that each round of disk reading and writing operation only reads and writes one disk, that is, each round of reading and writing operation can only determine the position of one disk. This solution is very time consuming when the number of disks is high.
Disclosure of Invention
In view of the above, an object of the present application is to provide a method, an apparatus, a device, and a medium for positioning a physical disk of a server, which can effectively reduce the time required for positioning the disk of the server. The specific scheme is as follows:
in a first aspect, the application discloses a server physical disk positioning method, which is used for positioning physical disks in a server, wherein a logical disk symbol of each physical disk carries uniquely corresponding coded information, each coded information is an N-bit binary code, each physical disk is provided with N indicator lights, the N indicator lights on each physical disk correspond to the N-bit binary codes in the corresponding coded information one by one, and N is a positive integer smaller than the total number of the physical disks; the method comprises the following steps:
executing N rounds of physical disk read-write operations; when the ith round of physical disk read-write operation is executed, the physical disk with the ith binary symbol of 1 of the coded information is simultaneously read-write operated;
recording actual flicker characteristics of N indicator lamps of each physical disk in the N-round physical disk read-write operations and disk installation positions corresponding to the actual flicker characteristics to obtain corresponding flicker statistical results;
determining preset flicker characteristics corresponding to the N indicator lights of each physical disk from a preset mapping table according to the coding information corresponding to the logical drive letter of each physical disk;
and searching actual flicker characteristics consistent with the preset flicker characteristics corresponding to each physical disk and the corresponding disk installation position from the flicker statistical result, and determining the searched disk installation position as the installation position of the corresponding physical disk.
Optionally, the executing N rounds of physical disk read-write operations includes:
acquiring coding information of a logical drive letter of each physical disk;
according to each piece of coding information, determining a physical disk which needs to be subjected to writing operation and corresponds to each round of physical disk reading and writing operation from all physical disks, and obtaining statistical information of the disks to be read and written of the N rounds of physical disk reading and writing operations;
and automatically executing the N rounds of physical disk read-write operations according to the statistical information of the disk to be read-written.
Optionally, the executing N rounds of physical disk read-write operations includes:
acquiring a read-write instruction set input by a user through a preset read-write instruction interface;
and executing the N rounds of physical disk read-write operations according to the read-write instruction set.
Optionally, the recording actual flicker characteristics of the N indicator lights of each physical disk in the N rounds of physical disk read-write operations and the disk mounting positions corresponding to the actual flicker characteristics to obtain corresponding flicker statistics results includes:
recording the actual flicker characteristics of N indicator lamps of each physical disk in the N rounds of physical disk reading and writing operations by using a preset flicker characteristic acquisition device;
and binding the recorded actual flicker characteristics with the corresponding disk installation positions to obtain corresponding flicker statistical results.
Optionally, the recording actual flicker characteristics of the N indicator lights of each physical disk in the N rounds of physical disk read-write operations and the disk mounting positions corresponding to the actual flicker characteristics to obtain corresponding flicker statistics results includes:
and recording the actual flicker characteristics of the N indicator lights of each physical disk in the N rounds of physical disk read-write operations and the disk installation positions corresponding to the actual flicker characteristics in a manual recording mode to obtain corresponding flicker statistical results.
Optionally, before determining the preset flicker characteristics corresponding to the N indicator lights of each physical disk from the preset mapping table, the method further includes:
and recording the corresponding relation between each piece of coding information and the corresponding preset flicker characteristic in a table mode to obtain the preset mapping table.
Optionally, the method for positioning a physical disk of a server further includes:
and determining the bit number of the coded information of each physical disk according to the number of the physical disks in the server.
In a second aspect, the application discloses a server physical disk positioning device, which is used for positioning physical disks in a server, wherein a logical disk symbol of each physical disk carries uniquely corresponding coded information, each coded information is an N-bit binary code, each physical disk is provided with N indicator lights, the N indicator lights on each physical disk correspond to the N-bit binary codes in the corresponding coded information one by one, and N is a positive integer smaller than the total number of the physical disks; the device comprises:
the read-write execution module is used for executing N rounds of physical disk read-write operations; when the ith round of physical disk read-write operation is executed, the physical disk with the ith binary symbol of 1 of the coded information is simultaneously read-write operated;
the flicker counting module is used for recording the actual flicker characteristics of the N indicator lamps of each physical disk in the N-round physical disk read-write operations and the disk installation positions corresponding to the actual flicker characteristics to obtain corresponding flicker counting results;
the characteristic determining module is used for determining preset flicker characteristics corresponding to the N indicator lamps of each physical disk from a preset mapping table according to the coding information corresponding to the logical drive letter of each physical disk;
and the position determining module is used for searching the actual flicker characteristics consistent with the preset flicker characteristics corresponding to each physical disk and the corresponding disk installation position from the flicker statistical result, and determining the searched disk installation position as the installation position of the corresponding physical disk.
In a third aspect, the application discloses a server physical disk positioning device, configured to position physical disks in a server, where a logical disk identifier of each physical disk carries uniquely corresponding coded information, each coded information is an N-bit binary code, each physical disk is provided with N indicator lights, the N indicator lights on each physical disk correspond to the N-bit binary codes in the corresponding coded information one-to-one, and N is a positive integer smaller than the total number of the physical disks; the apparatus comprises:
a memory for storing a computer program;
and the processor is used for executing the computer program to realize the server physical disk positioning method disclosed in the foregoing.
In a fourth aspect, the present application discloses a computer readable storage medium for storing a computer program; wherein the computer program, when executed by a processor, implements the server physical disk location method disclosed above.
It can be seen that, in the present application, the logical drive letter of each physical disk carries unique corresponding coded information, each coded information is an N-bit binary code, and each physical disk is provided with N indicator lights, the N indicator lights on each physical disk correspond to the N-bit binary codes in the corresponding coded information one by one, respectively, and N is a positive integer less than the total number of the physical disks; when the disk of the server is positioned, only N rounds of physical disk reading and writing operations are needed, the physical disk with the ith binary system symbol of 1 of the coded information can be simultaneously read and written in each round of reading and writing operations, the flicker statistical result of the indicating lamp corresponding to the N rounds of reading and writing operations can be recorded, and the installation positions of all the physical disks in the server can be obtained based on the flicker statistical result and the preset mapping table. Therefore, according to the method and the device, all the physical disks in the server can be positioned only by performing N rounds of reading and writing operations (N is less than the total number of the physical disks), so that the time required for positioning the disks of the server is effectively reduced.
Drawings
In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings used in the embodiments or the prior art descriptions will be briefly described below, it is obvious that the drawings in the following description are only the embodiments of the present application, and for those skilled in the art, other drawings can be obtained according to the provided drawings without creative efforts.
Fig. 1 is a flowchart of a server physical disk positioning method disclosed in the present application;
fig. 2 is a schematic structural diagram of a server physical disk positioning device disclosed in the present application.
Detailed Description
The technical solutions in the embodiments of the present application will be described clearly and completely with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are only some embodiments of the present application, and not all embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
Currently, the simplest and most effective method for positioning a physical disk in a server is to read and write a disk by using a disk read-write command in the system, wherein the disk is provided with a corresponding read-write indicator lamp, the indicator lamp of the disk of the server is checked when the dd command is operated, and the indicator lamp flickers to indicate that the disk is being read and written, so that the physical position of the disk is positioned. Although the disk positioning method is simple and effective, and can determine the position of the physical disk corresponding to the logical drive letter very intuitively, the scheme has the disadvantage that each round of disk reading and writing operation only reads and writes one disk, that is, each round of reading and writing operation can only determine the position of one disk. This solution is very time consuming when the number of disks is high. Therefore, the application discloses a server physical disk positioning scheme, which can effectively solve the technical problem.
Referring to fig. 1, an embodiment of the present application discloses a method for positioning physical disks of a server, where a logical disk identifier of each physical disk carries uniquely corresponding coded information, each coded information is an N-bit binary code, each physical disk is provided with N indicator lights, the N indicator lights on each physical disk correspond to the N-bit binary codes in the corresponding coded information one by one, and N is a positive integer smaller than the total number of the physical disks; the method comprises the following steps:
step S11: executing N rounds of physical disk read-write operations; when the ith round of physical disk read-write operation is executed, the physical disk with the ith binary symbol of 1 of the coded information is simultaneously read-write operated; the value range of i is from 1 to N;
step S12: recording actual flicker characteristics of N indicator lamps of each physical disk in the N-round physical disk read-write operations and disk installation positions corresponding to the actual flicker characteristics to obtain corresponding flicker statistical results;
step S13: determining preset flicker characteristics corresponding to the N indicator lights of each physical disk from a preset mapping table according to the coding information corresponding to the logical drive letter of each physical disk;
step S14: and searching actual flicker characteristics consistent with the preset flicker characteristics corresponding to each physical disk and the corresponding disk installation position from the flicker statistical result, and determining the searched disk installation position as the installation position of the corresponding physical disk.
It should be noted that in this embodiment, when the indicator light flashes, the corresponding binary symbol is 1, and when the indicator light does not flash, the corresponding binary symbol is 0.
In the following, the location of 12 physical disks of a server under the linux system is taken as an example. Assuming that the disk logical drives are sda, sdb, scdc, sdd, sde, sdf, sdg, sdh, sdi, sdj, sdk, sdl, the 12 blocks of logical drives are encoded in binary as shown in table 1 below:
TABLE 1
Dish sign | Encoding |
sda | 0000 |
sdb | 0001 |
sdc | 0010 |
sdd | 0011 |
sde | 0100 |
sdf | 0101 |
sdg | 0110 |
sdh | 0111 |
sdi | 1000 |
sdj | 1001 |
sdk | 1010 |
sdl | 1011 |
According to 4-bit binary coding, 4 rounds of physical disk read-write operations are carried out altogether, a disk with the first bit being 1 is coded to carry out the first round of read-write operations, a disk with the second bit being 1 is coded to carry out the second round of disk read-write operations, a disk with the third bit being 1 is coded to carry out the third round of disk read-write operations, and a disk with the fourth bit being 1 is coded to carry out the fourth round of disk read-write operations. The four-wheel disk read/write operation in this example is as follows:
executing the instruction for the first time:
dd if=/dev/sdi of=/dev/zero&
dd if=/dev/sdj of=/dev/zero&
dd if=/dev/sdk of=/dev/zero&
dd if=/dev/sdl of=/dev/zero&
executing the instruction for the second time:
dd if=/dev/sde of=/dev/zero&
dd if=/dev/sdf of=/dev/zero&
dd if=/dev/sdg of=/dev/zero&
dd if=/dev/sdh of=/dev/zero&
executing the instruction for the third time:
dd if=/dev/sdc of=/dev/zero&
dd if=/dev/sdd of=/dev/zero&
dd if=/dev/sdg of=/dev/zero&
dd if=/dev/sdh of=/dev/zero&
dd if=/dev/sdk of=/dev/zero&
dd if=/dev/sdl of=/dev/zero&
fourth execution of the instruction:
dd if=/dev/sdb of=/dev/zero&
dd if=/dev/sdd of=/dev/zero&
dd if=/dev/sdf of=/dev/zero&
dd if=/dev/sdh of=/dev/zero&
dd if=/dev/sdj of=/dev/zero&
dd if=/dev/sdl of=/dev/zero&
after the four operations are performed, the statistical result of the four physical disk indicator light flashes can be obtained, and the following table 2 can be obtained through analysis according to the codes, so that the positions corresponding to all the physical disks can be obtained. The coding mode can be expanded to any number of disks, and according to the principle of binary coding, n-bit coding can represent n-th power different symbols of 2, so that only floor (log) is needed for k disks of the server 2 k) +1 round (wherein floor denotesA floor function) operation can locate all the physical disks in the server.
TABLE 2
First wheel | Second wheel | Third wheel | Fourth wheel | Corresponding magnetic disk |
Does not flicker | Does not flicker | Does not flicker | Does not flicker | sda |
Does not flicker | Does not flicker | Does not flicker | Flashing | sdb |
Does not flicker | Does not flicker | Flashing | Does not flicker | sdc |
Does not flicker | Does not flicker | Flashing | Flashing | sdd |
Does not flicker | Flashing | Does not flicker | Does not flicker | sde |
Does not flicker | Flashing | Does not flicker | Flashing | sdf |
Does not flicker | Flashing | Flashing | Does not flicker | sdg |
Does not flicker | Flashing | Flashing | Flashing | sdh |
Flashing | Does not flicker | Does not flicker | Does not flicker | sdi |
Flashing | Does not flicker | Does not flicker | Flashing | sdj |
Flashing | Does not flicker | Flashing | Does not flicker | sdk |
Flashing | Does not flicker | Flashing | Flashing | sdl |
It can be seen that, in the embodiment of the present application, the logical drive letter of each physical disk carries unique corresponding coded information, each coded information is an N-bit binary code, each physical disk is provided with N indicator lights, the N indicator lights on each physical disk correspond to the N-bit binary codes in the corresponding coded information one by one, and N is a positive integer smaller than the total number of the physical disks; when the disk of the server is positioned, only N rounds of physical disk reading and writing operations are needed, reading and writing operations can be simultaneously performed on the physical disk of which the ith binary symbol of the coded information is 1 in each round of reading and writing operations, the flicker statistical result of the indicator light corresponding to the N rounds of reading and writing operations can be recorded, and the installation positions of all the physical disks in the server can be obtained based on the flicker statistical result and the preset mapping table. Therefore, in the embodiment of the application, all the physical disks in the server can be positioned only by performing N rounds of reading and writing operations (N is less than the total number of the physical disks), so that the time required for positioning the disks of the server is effectively reduced.
On the basis of the foregoing embodiments, the embodiments of the present application further explain and optimize the technical solutions. The method comprises the following specific steps:
in a specific embodiment, the executing N rounds of physical disk read-write operations may specifically include:
acquiring a read-write instruction set input by a user through a preset read-write instruction interface;
and executing the N rounds of physical disk read-write operations according to the read-write instruction set.
In order to improve the execution efficiency of the read-write operation, in another specific embodiment, the executing N rounds of physical disk read-write operations may specifically include:
acquiring coding information of a logical drive letter of each physical disk;
according to each piece of coding information, determining a physical disk which needs to be subjected to writing operation and corresponds to each round of physical disk reading and writing operation from all physical disks, and obtaining statistical information of the disks to be read and written of the N rounds of physical disk reading and writing operations;
and automatically executing the N rounds of physical disk read-write operations according to the statistical information of the disk to be read-written.
In a specific embodiment, the recording actual flicker characteristics of N indicator lights of each physical disk in the N rounds of physical disk read-write operations and a disk installation position corresponding to the actual flicker characteristics to obtain a corresponding flicker statistical result may specifically include:
and recording the actual flicker characteristics of the N indicator lights of each physical disk in the N rounds of physical disk read-write operations and the disk installation positions corresponding to the actual flicker characteristics in a manual recording mode to obtain corresponding flicker statistical results.
In order to increase the statistical speed of the flicker, in another specific embodiment, the recording actual flicker characteristics of the N indicator lights of each physical disk in the N rounds of physical disk read-write operations and the disk installation positions corresponding to the actual flicker characteristics to obtain corresponding statistical results of the flicker may specifically include:
recording the actual flicker characteristics of N indicator lamps of each physical disk in the N rounds of physical disk reading and writing operations by using a preset flicker characteristic acquisition device;
and binding the recorded actual flicker characteristics with the corresponding disk installation positions to obtain corresponding flicker statistical results.
It is understood that the flicker characteristic collecting device may be a light sensor.
Further, before determining the preset flicker characteristics corresponding to the N indicator lights of each physical disk from the preset mapping table, the method further includes:
and recording the corresponding relation between each piece of coding information and the corresponding preset flicker characteristic in a table mode to obtain the preset mapping table.
Further, the method for positioning a physical disk of a server in this embodiment may further include: and determining the bit number of the coded information of each physical disk according to the number of the physical disks in the server.
Preferably, this embodiment can convert floor (log) 2 k) And the numerical value of +1 is used as the bit number of the coded information, wherein k is the number of the physical disks in the server.
As shown in fig. 2, the embodiment of the present application further discloses a server physical disk positioning apparatus, configured to position physical disks in a server, where a logical drive letter of each physical disk carries uniquely corresponding coded information, each coded information is an N-bit binary code, each physical disk is provided with N indicator lights, the N indicator lights on each physical disk correspond to the N-bit binary codes in the corresponding coded information one by one, and N is a positive integer smaller than the total number of the physical disks; the device comprises:
the read-write execution module 11 is used for executing N rounds of physical disk read-write operations; when the ith round of physical disk read-write operation is executed, the physical disk with the ith binary symbol of 1 of the coded information is simultaneously read-write operated;
the flicker statistic module 12 is configured to record actual flicker characteristics of the N indicator lights of each physical disk in the N rounds of physical disk read-write operations and a disk installation position corresponding to the actual flicker characteristics, so as to obtain a corresponding flicker statistic result;
the characteristic determining module 13 is configured to determine, according to the encoded information corresponding to the logical drive letter of each physical disk, preset flicker characteristics corresponding to the N indicator lights of each physical disk from a preset mapping table;
and a position determining module 14, configured to search, from the flicker statistical result, an actual flicker characteristic and a corresponding disk installation position that are consistent with the preset flicker characteristic corresponding to each physical disk, and determine the searched disk installation position as the installation position of the corresponding physical disk.
For more specific working processes of the modules, reference may be made to corresponding contents disclosed in the foregoing embodiments, and details are not repeated here.
It can be seen that, in the embodiment of the present application, the logical drive letter of each physical disk carries unique corresponding coded information, each coded information is an N-bit binary code, each physical disk is provided with N indicator lights, the N indicator lights on each physical disk correspond to the N-bit binary codes in the corresponding coded information one by one, and N is a positive integer smaller than the total number of the physical disks; when the disk of the server is positioned, only N rounds of physical disk reading and writing operations are needed, reading and writing operations can be simultaneously performed on the physical disk of which the ith binary symbol of the coded information is 1 in each round of reading and writing operations, the flicker statistical result of the indicator light corresponding to the N rounds of reading and writing operations can be recorded, and the installation positions of all the physical disks in the server can be obtained based on the flicker statistical result and the preset mapping table. Therefore, in the embodiment of the application, all the physical disks in the server can be positioned only by performing N rounds of reading and writing operations (N is less than the total number of the physical disks), so that the time required for positioning the disks of the server is effectively reduced.
Furthermore, the application also discloses server physical disk positioning equipment, which is used for positioning physical disks in a server, wherein a logical disk symbol of each physical disk carries uniquely corresponding coded information, each coded information is an N-bit binary code, each physical disk is provided with N indicator lights, the N indicator lights on each physical disk are respectively in one-to-one correspondence with the N-bit binary codes in the corresponding coded information, and N is a positive integer smaller than the total number of the physical disks; the apparatus comprises:
a memory for storing a computer program;
and the processor is used for executing the computer program to realize the server physical disk positioning method disclosed by the foregoing embodiment.
Further, the present application also discloses a computer readable storage medium for storing a computer program; wherein, the computer program realizes the server physical disk positioning method disclosed in the foregoing embodiment when being executed by a processor.
The embodiments are described in a progressive manner, each embodiment focuses on differences from other embodiments, and the same or similar parts among the embodiments are referred to each other. The device disclosed by the embodiment corresponds to the method disclosed by the embodiment, so that the description is simple, and the relevant points can be referred to the method part for description.
The steps of a method or algorithm described in connection with the embodiments disclosed herein may be embodied directly in hardware, in a software module executed by a processor, or in a combination of the two. A software module may reside in Random Access Memory (RAM), memory, Read Only Memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, hard disk, a removable disk, a CD-ROM, or any other form of storage medium known in the art.
The method, the device, the equipment and the medium for positioning the physical disk of the server provided by the application are introduced in detail, a specific example is applied in the description to explain the principle and the implementation of the application, and the description of the embodiment is only used for helping to understand the method and the core idea of the application; meanwhile, for a person skilled in the art, according to the idea of the present application, there may be variations in the specific embodiments and the application scope, and in summary, the content of the present specification should not be construed as a limitation to the present application.
Claims (10)
1. A server physical disk positioning method is characterized in that the method is used for positioning physical disks in a server, wherein a logical disk sign of each physical disk carries uniquely corresponding coded information, each coded information is an N-bit binary code, N indicator lights are arranged on each physical disk, the N indicator lights on each physical disk correspond to the N-bit binary codes in the corresponding coded information one by one respectively, and N is a positive integer smaller than the total number of the physical disks; the method comprises the following steps:
executing N rounds of physical disk read-write operations, and flashing corresponding indicator lights when executing each round of physical disk operations; when the ith round of physical disk read-write operation is executed, the physical disk with the ith binary symbol of 1 of the coded information is simultaneously read-write operated, and the value of i is 1 to N;
recording actual flicker characteristics of N indicator lamps of each physical disk in the N-round physical disk read-write operations and disk installation positions corresponding to the actual flicker characteristics to obtain corresponding flicker statistical results;
determining preset flicker characteristics corresponding to the N indicator lights of each physical disk from a preset mapping table according to the coding information corresponding to the logical drive letter of each physical disk;
and searching actual flicker characteristics consistent with the preset flicker characteristics corresponding to each physical disk and the corresponding disk installation position from the flicker statistical result, and determining the searched disk installation position as the installation position of the corresponding physical disk.
2. The method for locating a physical disk of a server according to claim 1, wherein the performing N rounds of physical disk read-write operations includes:
acquiring coding information of a logical drive letter of each physical disk;
according to each piece of coding information, determining a physical disk needing write operation corresponding to each round of physical disk read-write operation from all physical disks, and obtaining statistical information of the disks to be read and written of the N rounds of physical disk read-write operations;
and automatically executing the N rounds of physical disk read-write operations according to the statistical information of the disk to be read-written.
3. The method for locating the physical disk of the server according to claim 1, wherein the performing N rounds of the read-write operations of the physical disk comprises:
acquiring a read-write instruction set input by a user through a preset read-write instruction interface;
and executing the N rounds of physical disk read-write operations according to the read-write instruction set.
4. The method for positioning the physical disk of the server according to claim 1, wherein the recording actual flicker characteristics of N indicator lights of each physical disk in the N rounds of physical disk read-write operations and the disk installation positions corresponding to the actual flicker characteristics to obtain corresponding flicker statistical results comprises:
recording the actual flicker characteristics of N indicator lamps of each physical disk in the N rounds of physical disk reading and writing operations by using a preset flicker characteristic acquisition device;
and binding the recorded actual flicker characteristics with the corresponding disk installation positions to obtain corresponding flicker statistical results.
5. The method for positioning the physical disk of the server according to claim 1, wherein the recording actual flicker characteristics of N indicator lights of each physical disk in the N rounds of physical disk read-write operations and the disk installation positions corresponding to the actual flicker characteristics to obtain corresponding flicker statistical results comprises:
and recording the actual flicker characteristics of the N indicator lights of each physical disk in the N rounds of physical disk read-write operations and the disk installation positions corresponding to the actual flicker characteristics in a manual recording mode to obtain corresponding flicker statistical results.
6. The method for locating the physical disks of the server according to any one of claims 1 to 5, wherein before determining the preset flicker characteristics corresponding to the N indicator lights of each physical disk from the preset mapping table, the method further comprises:
and recording the corresponding relation between each piece of coding information and the corresponding preset flicker characteristic in a table mode to obtain the preset mapping table.
7. The method for locating the physical disk of the server according to any one of claims 1 to 5, further comprising:
and determining the bit number of the coded information of each physical disk according to the number of the physical disks in the server.
8. A server physical disk positioning device is characterized by being used for positioning physical disks in a server, wherein a logical disk sign of each physical disk carries uniquely corresponding coded information, each coded information is an N-bit binary code, N indicator lights are arranged on each physical disk, the N indicator lights on each physical disk correspond to the N-bit binary codes in the corresponding coded information one by one respectively, and N is a positive integer smaller than the total number of the physical disks; the device comprises:
the read-write execution module is used for executing N rounds of physical disk read-write operations, and corresponding indicator lamps flicker when each round of physical disk operation is executed; when the ith round of physical disk read-write operation is executed, the physical disk with the ith binary symbol of 1 of the coded information is simultaneously read-write operated, and the value of i is 1 to N;
the flicker counting module is used for recording the actual flicker characteristics of the N indicator lamps of each physical disk in the N-round physical disk read-write operations and the disk installation positions corresponding to the actual flicker characteristics to obtain corresponding flicker counting results;
the characteristic determining module is used for determining preset flicker characteristics corresponding to the N indicator lamps of each physical disk from a preset mapping table according to the coding information corresponding to the logical drive letter of each physical disk;
and the position determining module is used for searching the actual flicker characteristics consistent with the preset flicker characteristics corresponding to each physical disk and the corresponding disk installation position from the flicker statistical result, and determining the searched disk installation position as the installation position of the corresponding physical disk.
9. The server physical disk positioning device is used for positioning physical disks in a server, wherein a logical disk sign of each physical disk carries unique corresponding coded information, each coded information is an N-bit binary code, N indicator lights are arranged on each physical disk, the N indicator lights on each physical disk correspond to the N-bit binary codes in the corresponding coded information one by one respectively, and N is a positive integer smaller than the total number of the physical disks; the apparatus comprises:
a memory for storing a computer program;
a processor for executing the computer program to implement the server physical disk location method of any of claims 1 to 7.
10. A computer-readable storage medium for storing a computer program; wherein the computer program when executed by a processor implements the server physical disk location method of any of claims 1 to 7.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910217477.8A CN109947622B (en) | 2019-03-21 | 2019-03-21 | Server physical disk positioning method, device, equipment and medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910217477.8A CN109947622B (en) | 2019-03-21 | 2019-03-21 | Server physical disk positioning method, device, equipment and medium |
Publications (2)
Publication Number | Publication Date |
---|---|
CN109947622A CN109947622A (en) | 2019-06-28 |
CN109947622B true CN109947622B (en) | 2022-08-02 |
Family
ID=67010503
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201910217477.8A Active CN109947622B (en) | 2019-03-21 | 2019-03-21 | Server physical disk positioning method, device, equipment and medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN109947622B (en) |
Families Citing this family (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN112000532B (en) * | 2020-07-30 | 2022-03-22 | 浪潮电子信息产业股份有限公司 | Method, device, equipment and system for detecting disk disorder |
Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101266814A (en) * | 2008-05-08 | 2008-09-17 | 杭州华三通信技术有限公司 | Disk location method in storage system and storage system for locating disk |
CN103729146A (en) * | 2013-12-19 | 2014-04-16 | 浪潮(北京)电子信息产业有限公司 | Method and system for quickly positioning magnetic disks of mass storage systems |
CN105528269A (en) * | 2016-01-29 | 2016-04-27 | 浪潮电子信息产业股份有限公司 | Design method for detecting disorder of hard disks based on Itanium platform |
CN106294084A (en) * | 2016-09-12 | 2017-01-04 | 恒为科技(上海)股份有限公司 | A kind of monitoring hard-disk status system |
CN106469103A (en) * | 2015-08-14 | 2017-03-01 | 华为软件技术有限公司 | The maintaining method of hard disk and device |
CN107015894A (en) * | 2016-01-28 | 2017-08-04 | 胡敏 | A kind of common store hard disk localization method |
WO2018071214A1 (en) * | 2016-10-11 | 2018-04-19 | Carrier Corporation | Determination of the physical location of field device |
-
2019
- 2019-03-21 CN CN201910217477.8A patent/CN109947622B/en active Active
Patent Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101266814A (en) * | 2008-05-08 | 2008-09-17 | 杭州华三通信技术有限公司 | Disk location method in storage system and storage system for locating disk |
CN103729146A (en) * | 2013-12-19 | 2014-04-16 | 浪潮(北京)电子信息产业有限公司 | Method and system for quickly positioning magnetic disks of mass storage systems |
CN106469103A (en) * | 2015-08-14 | 2017-03-01 | 华为软件技术有限公司 | The maintaining method of hard disk and device |
CN107015894A (en) * | 2016-01-28 | 2017-08-04 | 胡敏 | A kind of common store hard disk localization method |
CN105528269A (en) * | 2016-01-29 | 2016-04-27 | 浪潮电子信息产业股份有限公司 | Design method for detecting disorder of hard disks based on Itanium platform |
CN106294084A (en) * | 2016-09-12 | 2017-01-04 | 恒为科技(上海)股份有限公司 | A kind of monitoring hard-disk status system |
WO2018071214A1 (en) * | 2016-10-11 | 2018-04-19 | Carrier Corporation | Determination of the physical location of field device |
Also Published As
Publication number | Publication date |
---|---|
CN109947622A (en) | 2019-06-28 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN101436152B (en) | Method and device for data backup | |
US8990792B2 (en) | Method for constructing dynamic call graph of application | |
CN114764765A (en) | Image defect detection method and device, electronic equipment and storage medium | |
CN114499743B (en) | Communication data processing method, device, equipment and storage medium | |
CN109947622B (en) | Server physical disk positioning method, device, equipment and medium | |
CN111400099B (en) | Flash memory data rereading method, device, equipment and computer readable storage medium | |
US9286155B1 (en) | Systems and methods for generating soft information in a flash device | |
CN110704257A (en) | Solid state disk, quality monitoring method and device thereof and computer readable storage medium | |
CN104317574A (en) | Method and device for identifying application program type | |
CN109558263B (en) | Method and related device for processing data reading errors of solid state disk | |
US11947819B2 (en) | Method and system for testing conversion relationship between block reading and page reading in flash memory chip | |
CN101662293B (en) | Method and device for decoding | |
CN113191119A (en) | Method, apparatus and storage medium for training text error correction model | |
CN116001807B (en) | Multi-scene track prediction method, equipment, medium and vehicle | |
CN107436728B (en) | Rule analysis result storage method, rule backtracking method and device | |
CN112306382B (en) | Flash memory controller, storage device and reading method thereof | |
CN114153670A (en) | Random test method, device, equipment and storage medium | |
CN115373609A (en) | Task processing method and related equipment | |
KR20060050207A (en) | Drive tracking system for moving media | |
CN115438002A (en) | Log file compression method and device, electronic equipment and storage medium | |
CN111382007B (en) | Data recovery method and device and electronic equipment | |
CN113326046A (en) | Method and device for acquiring compiling time length | |
CN112445800A (en) | Method and system for generating data serial number and electronic equipment | |
CN112580297B (en) | Method for encoding and decoding data, electronic equipment and storage medium | |
CN100353445C (en) | Method and device for data decoding applied to optical drive system 8-14 modulation |
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 |