CN109582515A - A kind of hard disk detection method, system and electronic equipment and storage medium - Google Patents

A kind of hard disk detection method, system and electronic equipment and storage medium Download PDF

Info

Publication number
CN109582515A
CN109582515A CN201811463380.7A CN201811463380A CN109582515A CN 109582515 A CN109582515 A CN 109582515A CN 201811463380 A CN201811463380 A CN 201811463380A CN 109582515 A CN109582515 A CN 109582515A
Authority
CN
China
Prior art keywords
hard disk
target
detection
open source
source software
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.)
Withdrawn
Application number
CN201811463380.7A
Other languages
Chinese (zh)
Inventor
孙京本
刘亮
王孝鹏
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Zhengzhou Yunhai Information Technology Co Ltd
Original Assignee
Zhengzhou Yunhai Information Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Zhengzhou Yunhai Information Technology Co Ltd filed Critical Zhengzhou Yunhai Information Technology Co Ltd
Priority to CN201811463380.7A priority Critical patent/CN109582515A/en
Publication of CN109582515A publication Critical patent/CN109582515A/en
Withdrawn legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/22Detection or location of defective computer hardware by testing during standby operation or during idle time, e.g. start-up testing
    • G06F11/2205Detection or location of defective computer hardware by testing during standby operation or during idle time, e.g. start-up testing using arrangements specific to the hardware being tested
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/22Detection or location of defective computer hardware by testing during standby operation or during idle time, e.g. start-up testing
    • G06F11/2268Logging of test results
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/22Detection or location of defective computer hardware by testing during standby operation or during idle time, e.g. start-up testing
    • G06F11/2273Test methods
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/22Detection or location of defective computer hardware by testing during standby operation or during idle time, e.g. start-up testing
    • G06F11/2289Detection or location of defective computer hardware by testing during standby operation or during idle time, e.g. start-up testing by configuration test

Landscapes

  • Engineering & Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Hardware Design (AREA)
  • Quality & Reliability (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Debugging And Monitoring (AREA)

Abstract

This application discloses a kind of hard disk detection method, system and a kind of electronic equipment and computer readable storage mediums, this method comprises: when searching target hard disk, the health status that the target hard disk is detected using open source software and/or system command, obtains feedback result;Judge whether the feedback result reaches preset value, if it is not, then carrying out deduction of points operation to the basis of the target hard disk point;The Health Category of the target hard disk is obtained according to the final score of the target hard disk.Hard disk detection method provided by the present application incorporates a variety of free open source softwares, provides the hard disk detection mode of various dimensions, can accomplish batch detection hard disk, greatly improves the quality and efficiency of hard disk screening and hard disk evaluation work.In addition, in this application, open source software and system command can be encapsulated as to detection script, by Script controlling detection process, scalability is strong.

Description

A kind of hard disk detection method, system and electronic equipment and storage medium
Technical field
This application involves field of computer technology, more specifically to a kind of hard disk detection method, system and a kind of electricity Sub- equipment and a kind of computer readable storage medium.
Background technique
In cloud computing era, mass data needs the storage hard disk of magnanimity, the quality of hard disk quality, strong influence cloud Calculate the stability in data center.In order to improve the stability of mass memory, various detection methods have been produced at present, most Common is exactly that hard disk is given to special detection department or a large amount of performance test of test department progress and stability test.But It is that such test method is at high cost, low efficiency can not adapt to the geometry grade growth of large-scale data center storage hard disk scale Trend becomes bottleneck.
Therefore, how to improve the detection efficiency of hard disk is those skilled in the art's problem to be solved.
Summary of the invention
The application be designed to provide a kind of hard disk detection method, system and a kind of electronic equipment and a kind of computer can Storage medium is read, the detection efficiency of hard disk is improved.
To achieve the above object, this application provides a kind of hard disk detection methods, comprising:
When searching target hard disk, the healthy shape of the target hard disk is detected using open source software and/or system command Condition obtains feedback result;
Judge whether the feedback result reaches preset value, if it is not, then deducting points to the basis of the target hard disk point Operation;
The Health Category of the target hard disk is obtained according to the final score of the target hard disk.
Wherein, the health status that the target hard disk is detected using open source software and/or system command, is fed back As a result, including
The target detection item that the target hard disk is detected using target open source software or goal systems order, obtains the mesh Mark the corresponding feedback result of detection;
Correspondingly, judge whether the feedback result reaches preset value, if it is not, then to the basis of the target hard disk point into Row deduction of points operation, comprising:
Judge whether the feedback result reaches the corresponding target preset value of the target detection item, if it is not, then according to institute It states target detection item corresponding standard of deducting point and deduction of points operation is carried out to the basis point of the target hard disk.
Wherein, the target detection item of the target hard disk is detected using target open source software, comprising:
The health status of the target hard disk is detected using open source software smartctl;
Page detection is carried out to the target hard disk using open source software sg_inq;
Bad block detection is carried out to the target hard disk using open source software sg_verify;
Slow disk detection is carried out to the target hard disk using open source software fioi.
Wherein, the target detection item that the target hard disk is detected using goal systems order obtains the target detection item Corresponding feedback result, comprising:
It is controlled using the goal systems order with default read-write size order or is read and write at random to the target hard disk pre- If duration, the corresponding feedback result of read-write operation is obtained.
Wherein, the open source software includes smartctl, sg_inq, sg_scan, sg_ses, sg_verify, sg_ Any one of readcap, sg_map, sg_sat_identify, od, fioi appoint several combinations.
Wherein, further includes:
Obtain configuration file;Wherein, the configuration file includes at least the corresponding target preset value of the target detection item And standard of deducting point.
To achieve the above object, this application provides a kind of hard disk detection systems, comprising:
Detection module, for detecting the target using open source software and/or system command when searching target hard disk The health status of hard disk, obtains feedback result;
Judgment module, for judging whether the feedback result reaches preset value, if it is not, then to the base of the target hard disk Plinth point carries out deduction of points operation;
Grading module, for obtaining the Health Category of the target hard disk according to the final score of the target hard disk.
Wherein, the detection module is specially to utilize target open source software or goal systems when searching target hard disk Order detects the target detection item of the target hard disk, obtains the module of the corresponding feedback result of the target detection item;
Correspondingly, the judgment module is specially that judge whether the feedback result reaches the target detection item corresponding Target preset value, if it is not, then being carried out according to basis point of the corresponding standard of deducting point of the target detection item to the target hard disk The module of deduction of points operation.
To achieve the above object, this application provides a kind of electronic equipment, comprising:
Memory, for storing computer program;
Processor is realized when for executing the computer program such as the step of above-mentioned hard disk detection method.
To achieve the above object, this application provides a kind of computer readable storage medium, the computer-readable storages It is stored with computer program on medium, the step such as above-mentioned hard disk detection method is realized when the computer program is executed by processor Suddenly.
By above scheme it is found that a kind of hard disk detection method provided by the present application, comprising: when searching target hard disk When, the health status of the target hard disk is detected using open source software and/or system command, obtains feedback result;Described in judgement Whether feedback result reaches preset value, if it is not, then carrying out deduction of points operation to the basis of the target hard disk point;According to the target The final score of hard disk obtains the Health Category of the target hard disk.
Hard disk detection method provided by the present application, using open source software and system command according to this to the health status of hard disk into Row detection, carries out scoring operation to the hard disk according to the comparing result of feedback result and preset value, obtains final Health Category. In this application, a variety of free open source softwares are incorporated, the hard disk detection mode of various dimensions is provided, can accomplish batch detection Hard disk greatly improves the quality and efficiency of hard disk screening and hard disk evaluation work.In addition, in this application, can will open Source software and system command are encapsulated as detection script, and by Script controlling detection process, scalability is strong.Disclosed herein as well is A kind of hard disk detection system and a kind of electronic equipment and a kind of computer readable storage medium are equally able to achieve above-mentioned technology effect Fruit.
Detailed description of the invention
In order to illustrate the technical solutions in the embodiments of the present application or in the prior art more clearly, to embodiment or will show below There is attached drawing needed in technical description to be briefly described, it should be apparent that, the accompanying drawings in the following description is only this Some embodiments of application for those of ordinary skill in the art without creative efforts, can be with It obtains other drawings based on these drawings.
Fig. 1 is a kind of flow chart of hard disk detection method disclosed in the embodiment of the present application;
Fig. 2 is the flow chart of another kind hard disk detection method disclosed in the embodiment of the present application;
Fig. 3 is a kind of structure chart of hard disk detection system disclosed in the embodiment of the present application;
Fig. 4 is the structure chart of a kind of electronic equipment disclosed in the embodiment of the present application;
Fig. 5 is the structure chart of another kind electronic equipment disclosed in the embodiment of the present application.
Specific embodiment
Below in conjunction with the attached drawing in the embodiment of the present application, technical solutions in the embodiments of the present application carries out clear, complete Site preparation description, it is clear that described embodiments are only a part of embodiments of the present application, instead of all the embodiments.It is based on Embodiment in the application, it is obtained by those of ordinary skill in the art without making creative efforts every other Embodiment shall fall in the protection scope of this application.
The embodiment of the present application discloses a kind of hard disk detection method, improves the detection efficiency of hard disk.
Referring to Fig. 1, a kind of flow chart of hard disk detection method disclosed in the embodiment of the present application, as shown in Figure 1, comprising:
S101: when searching target hard disk, the strong of the target hard disk is detected using open source software and/or system command Health situation, obtains feedback result;
In specific implementation, when searching target hard disk, the target hard disk is detected using open source software and system command Health status.Open source software herein may include smartctl, sg_inq, sg_scan, sg_ses, sg_verify, sg_ Readcap, sg_map, sg_sat_identify, od, fioi etc..What those skilled in the art can detect according to actual needs Target detection item carries out flexible setting.
It is understood that the health status of hard disk can be detected from many aspects, that is, there are multiple target detection items.Cause This, this step may include that the target detection item of the target hard disk is detected using target open source software or goal systems order, Obtain the corresponding feedback result of the target detection item.
It should be noted that target hard disk needs the target detection item detected that can be configured in configuration file, Default before this step and there is the step of obtaining the configuration file.The corresponding target of target detection item is defined in the configuration file Preset value and standard of deducting point, so that subsequent step compares the feedback result that this step obtains and preset value.
S102: judging whether the feedback result reaches preset value, if it is not, then carrying out to the basis of the target hard disk point Deduction of points operation;
In specific implementation, the feedback result that previous step obtains is compared with pre-set preset value, if reaching To preset value, then illustrate that the health status of the target hard disk is up to standard, is operated without deduction of points, if not up to preset value, to this The basis of target hard disk point carries out deduction of points operation.Be set to 100 for example, basis can be set up separately, not up to preset value when carry out phase The deduction of points answered.
It is understood that needing to judge respectively the feedback knot of each target detection item when there are multiple target detection items Whether fruit reaches its corresponding target preset value, if it is not, then according to the corresponding standard of deducting point of target detection item to target hard disk Basis point carries out deduction of points operation.
S103: the Health Category of the target hard disk is obtained according to the final score of the target hard disk.
In specific implementation, the fraction range of each grade can be set in configuration file.In this step, according to the mesh The fraction range in the final score and configuration file of hard disk is marked, the Health Category of the target hard disk is exported.For example, 85-100 is A, 75-85 B, 60-75 C, 0-60 F.
It as a preferred implementation manner, can be by the final score that previous step obtains and the health etc. that this step obtains Grade display issues warning information in final score or too low Health Category to terminal device.
Hard disk detection method provided by the embodiments of the present application, using open source software and system command according to this to the health of hard disk Situation is detected, and carries out scoring operation to the hard disk according to the comparing result of feedback result and preset value, obtains final be good for Health grade.In the embodiment of the present application, a variety of free open source softwares are incorporated, the hard disk detection mode of various dimensions is provided, it can To accomplish batch detection hard disk, the quality and efficiency of hard disk screening and hard disk evaluation work are greatly improved.In addition, in this Shen Open source software and system command can please be encapsulated as to detection script in embodiment, it is expansible by Script controlling detection process Property is strong.
The embodiment of the present application discloses a kind of hard disk detection method, and relative to a upper embodiment, the present embodiment is to technical side Case has made further instruction and optimization.It is specific:
Referring to fig. 2, the flow chart of another hard disk detection method provided by the embodiments of the present application, as shown in Figure 2, comprising:
S201: configuration file is obtained;
S202: the target detection item of the target hard disk is detected using target open source software or goal systems order, is obtained The corresponding feedback result of the target detection item;
In specific implementation, target detection item may include the health status of target hard disk, page detection, the detection of bad block Item, slow disk detection and read-write operation etc..For the target detection item using open source software detection, specific detecting step can be with It include: the health status that the target hard disk is detected using open source software smartctl;Using open source software sg_inq to described Target hard disk carries out page detection;Bad block detection is carried out to the target hard disk using open source software sg_verify;Utilize open source Software fioi carries out slow disk detection to the target hard disk.
For the target detection item using system command detection, specific detecting step are as follows: ordered using the goal systems It enables control read and write preset duration to the target hard disk with default read-write size order or at random, it is corresponding anti-to obtain read-write operation Present result.
Default read-write size and preset duration are not limited specifically herein, those skilled in the art can be according to specific Hard disk carry out flexible setting.For example, can be read and write 10 minutes with 4k size order, at random to the target hard disk, then big with 1M Small sequence, at random to the target hard disk read and write 10 minutes, obtained each read-write situation again with pre-set each preset value into Row comparison carries out corresponding deduction of points operation according to comparing result.
S203: judging whether the feedback result reaches the corresponding target preset value of the target detection item, if it is not, then root Deduction of points operation is carried out according to basis point of the corresponding standard of deducting point of the target detection item to the target hard disk.
S204: the Health Category of the target hard disk is obtained according to the final score of the target hard disk.
The Application Example of the hard disk detection method of the present embodiment introduction is described below, specifically, VB language can be used Foreground interface is developed, foreground interface can provide basic configuration maintenance, starting and detection process are shown and testing result is shown etc.. Wherein, basic configuration may include road where the hard disk type supported and model, log storing path, master catalogue, detection program Diameter, detection threshold value and detection do not reach threshold value deduction of points score value etc..Starting and detection process displaying may include detection process day Will displaying etc..Testing result displaying may include each hard disk score show and problematic hard disk problem details displaying etc..
Backstage carries out the scheduling of process using shell script, and the log of script output is foreground interface process and result exhibition The source shown.Backstage scheduling smartctl, sg_inq, sg_scan, sg_ses, sg_verify, sg_readcap, sg_map, The free open source software such as sg_sat_identify, od, fioi carries out the detection of different dimensions to hard disk.
Backstage is main when realizing including the following steps:
Step 1: read foreground interface configurations, obtain support hard disk type and model, log storing path, master catalogue, Path, detection threshold value and detection where detection program do not reach the information such as threshold value deduction of points score value, and are arranged into variable.
Step 2: searching for all hard disks, calculate the number for needing the hard disk detected, be output in log.
Step 3: open source software smartctl is used, checks hard disk health status, if not reaching threshold value, is deducted points, and Outputting alarm is into log.
Step 4: open source software sg_modes is used, hard disk page detection is carried out, if not reaching threshold value, is deducted points, and Outputting alarm is into log.
Step 5: read hard disk first character section and the last byte, check whether value is 0, if it is 0, illustrate be Otherwise new building is old disk, according to the threshold value of configuration setting, deduct points, output journal alarm.
Step 6: disk is written and read 10 minutes with 4K size order, whether threshold value is reached according to read-write situation, into Row assessment and deduction of points, and outputting alarm is into log.
Step 7: disk is written and read 10 minutes with 1M size order, whether threshold value is reached according to read-write situation, into Row assessment and deduction of points, and outputting alarm is into log.
Step 8: disk is written and read 10 minutes at random with 4K size, whether threshold value is reached according to read-write situation, into Row assessment and deduction of points, and outputting alarm is into log.
Step 9: disk is written and read 10 minutes at random with 1M size, whether threshold value is reached according to read-write situation, into Row assessment and deduction of points, and outputting alarm is into log.
Step 10: overall low-quality disk being carried out to disk using free open source software sg_verify and is detected, if there is bad block, then It is deducted points accordingly, and outputting alarm is into log.
Step 11: slow disk detection is carried out using free open source software fio, different threshold conditions is reached according to slow disk, into The corresponding deduction of points of row, and outputting alarm is into log.
Step 12: all items detection terminates, and exports all hard disk grades and score.
A kind of hard disk detection system provided by the embodiments of the present application is introduced below, a kind of hard disk inspection described below Examining system can be cross-referenced with a kind of above-described hard disk detection method.
Referring to Fig. 3, a kind of structure chart of hard disk detection system provided by the embodiments of the present application, as shown in Figure 3, comprising:
Detection module 301, for when searching target hard disk, using described in open source software and/or system command detection The health status of target hard disk, obtains feedback result;
Judgment module 302, for judging whether the feedback result reaches preset value, if it is not, then to the target hard disk Basis point carry out deduction of points operation;
Grading module 303, for obtaining the Health Category of the target hard disk according to the final score of the target hard disk.
Hard disk detection system provided by the embodiments of the present application, using open source software and system command according to this to the health of hard disk Situation is detected, and carries out scoring operation to the hard disk according to the comparing result of feedback result and preset value, obtains final be good for Health grade.In the embodiment of the present application, a variety of free open source softwares are incorporated, the hard disk detection mode of various dimensions is provided, it can To accomplish batch detection hard disk, the quality and efficiency of hard disk screening and hard disk evaluation work are greatly improved.In addition, in this Shen Open source software and system command can please be encapsulated as to detection script in embodiment, it is expansible by Script controlling detection process Property is strong.
On the basis of the above embodiments, the detection module 301 is specially when search as a preferred implementation manner, When to target hard disk, the target detection item of the target hard disk is detected using target open source software or goal systems order, is obtained The module of the corresponding feedback result of the target detection item;
Correspondingly, the judgment module 302 is specially that judge whether the feedback result reaches the target detection item right The target preset value answered, if it is not, then according to the corresponding standard of deducting point of the target detection item to the basis point of the target hard disk Carry out the module of deduction of points operation.
On the basis of the above embodiments, the detection module 301 includes: as a preferred implementation manner,
First detection unit, for detecting the health status of the target hard disk using open source software smartctl;
Second detection unit, for carrying out page detection to the target hard disk using open source software sg_inq;
Third detection unit, for carrying out bad block detection to the target hard disk using open source software sg_verify;
4th detection unit, for carrying out slow disk detection to the target hard disk using open source software fioi.
On the basis of the above embodiments, the detection module 301 is specially when search as a preferred implementation manner, When to target hard disk, is controlled using the goal systems order with default read-write size order or the target hard disk is read at random Preset duration is write, the module of the corresponding feedback result of read-write operation is obtained.
On the basis of the above embodiments, as a preferred implementation manner, the open source software include smartctl, In sg_inq, sg_scan, sg_ses, sg_verify, sg_readcap, sg_map, sg_sat_identify, od, fioi Any one appoints several combinations.
On the basis of the above embodiments, as a preferred implementation manner, further include:
Module is obtained, for obtaining configuration file;Wherein, the configuration file is corresponding including at least the target detection item Target preset value and standard of deducting point.
Present invention also provides a kind of electronic equipment, referring to fig. 4, the knot of a kind of electronic equipment provided by the embodiments of the present application Composition, as shown in Figure 4, comprising:
Memory 100, for storing computer program;
Step provided by above-described embodiment may be implemented in processor 200 when for executing the computer program.
Specifically, memory 100 includes non-volatile memory medium, built-in storage.Non-volatile memory medium storage There are operating system and computer-readable instruction, which is that the operating system and computer in non-volatile memory medium can The operation of reading instruction provides environment.Processor 200 provides calculating and control ability for electronic equipment, executes the memory 100 When the computer program of middle preservation, may be implemented as above-mentioned any embodiment provide hard disk detection method the step of.
The embodiment of the present application according to this detects the health status of hard disk using open source software and system command, according to anti- The comparing result of feedback result and preset value carries out scoring operation to the hard disk, obtains final Health Category.Implement in the application In examples, a variety of free open source softwares are incorporated, the hard disk detection mode of various dimensions is provided, can accomplish batch detection hard disk, Greatly improve the quality and efficiency of hard disk screening and hard disk evaluation work.In addition, in the embodiment of the present application, can will open Source software and system command are encapsulated as detection script, and by Script controlling detection process, scalability is strong.
On the basis of the above embodiments, preferably, referring to Fig. 5, the electronic equipment further include:
Input interface 300 is connected with processor 200, for obtaining computer program, parameter and the instruction of external importing, It saves through the control of processor 200 into memory 100.The input interface 300 can be connected with input unit, and it is manual to receive user The parameter or instruction of input.The input unit can be the touch layer covered on display screen, be also possible to be arranged in terminal enclosure Key, trace ball or Trackpad, be also possible to keyboard, Trackpad or mouse etc..
Display unit 400 is connected with processor 200, the data sent for video-stream processor 200.The display unit 400 It can be display screen, liquid crystal display or the electric ink display screen etc. in PC machine.It, can be with specifically, in the present embodiment Testing result etc. is shown by display unit 400.
The network port 500 is connected with processor 200, for being communicatively coupled with external each terminal device.The communication link The communication technology used by connecing can be cable communicating technology or wireless communication technique, and such as mobile high definition chained technology (MHL) leads to It is blue with universal serial bus (USB), high-definition media interface (HDMI), adopting wireless fidelity technology (WiFi), Bluetooth Communication Technology, low-power consumption The tooth communication technology, communication technology based on IEEE802.11s etc..
Present invention also provides a kind of computer readable storage medium, the storage medium may include: USB flash disk, mobile hard disk, Read-only memory (Read-Only Memory, ROM), random access memory (Random Access Memory, RAM), magnetic The various media that can store program code such as dish or CD.Computer program, the calculating are stored on the storage medium The step of hard disk detection method such as the offer of above-mentioned any embodiment is realized when machine program is executed by processor.
Each embodiment is described in a progressive manner in specification, the highlights of each of the examples are with other realities The difference of example is applied, the same or similar parts in each embodiment may refer to each other.For system disclosed in embodiment Speech, since it is corresponded to the methods disclosed in the examples, so being described relatively simple, related place is referring to method part illustration ?.It should be pointed out that for those skilled in the art, under the premise of not departing from the application principle, also Can to the application, some improvement and modification can also be carried out, these improvement and modification also fall into the protection scope of the claim of this application It is interior.
It should also be noted that, in the present specification, relational terms such as first and second and the like be used merely to by One entity or operation are distinguished with another entity or operation, without necessarily requiring or implying these entities or operation Between there are any actual relationship or orders.Moreover, the terms "include", "comprise" or its any other variant meaning Covering non-exclusive inclusion, so that the process, method, article or equipment for including a series of elements not only includes that A little elements, but also including other elements that are not explicitly listed, or further include for this process, method, article or The intrinsic element of equipment.In the absence of more restrictions, the element limited by sentence "including a ...", is not arranged Except there is also other identical elements in the process, method, article or apparatus that includes the element.

Claims (10)

1. a kind of hard disk detection method, which is characterized in that including
When searching target hard disk, the health status of the target hard disk is detected using open source software and/or system command, is obtained To feedback result;
Judge whether the feedback result reaches preset value, if it is not, then carrying out deduction of points operation to the basis of the target hard disk point;
The Health Category of the target hard disk is obtained according to the final score of the target hard disk.
2. hard disk detection method according to claim 1, which is characterized in that described to utilize open source software and/or system command The health status for detecting the target hard disk obtains feedback result, including
The target detection item that the target hard disk is detected using target open source software or goal systems order obtains the target inspection Survey the corresponding feedback result of item;
Correspondingly, judging whether the feedback result reaches preset value, if it is not, then detaining the basis of the target hard disk point Divide operation, comprising:
Judge whether the feedback result reaches the corresponding target preset value of the target detection item, if it is not, then according to the mesh The corresponding standard of deducting point of mark detection carries out deduction of points operation to the basis point of the target hard disk.
3. hard disk detection method according to claim 2, which is characterized in that it is hard to detect the target using target open source software The target detection item of disk, comprising:
The health status of the target hard disk is detected using open source software smartctl;
Page detection is carried out to the target hard disk using open source software sg_inq;
Bad block detection is carried out to the target hard disk using open source software sg_verify;
Slow disk detection is carried out to the target hard disk using open source software fioi.
4. hard disk detection method according to claim 2, which is characterized in that it is hard to detect the target using goal systems order The target detection item of disk obtains the corresponding feedback result of the target detection item, comprising:
When controlling with default read-write size order using the goal systems order or read and write default to the target hard disk at random It is long, obtain the corresponding feedback result of read-write operation.
5. hard disk detection method according to claim 1, which is characterized in that the open source software includes smartctl, sg_ Appointing in inq, sg_scan, sg_ses, sg_verify, sg_readcap, sg_map, sg_sat_identify, od, fioi One or appoint several combinations.
6. according to any one of the claim 2-5 hard disk detection method, which is characterized in that further include:
Obtain configuration file;Wherein, the configuration file includes at least the corresponding target preset value of the target detection item and button Minute mark is quasi-.
7. a kind of hard disk detection system characterized by comprising
Detection module, for detecting the target hard disk using open source software and/or system command when searching target hard disk Health status, obtain feedback result;
Judgment module, for judging whether the feedback result reaches preset value, if it is not, then to the basis of the target hard disk point Carry out deduction of points operation;
Grading module, for obtaining the Health Category of the target hard disk according to the final score of the target hard disk.
8. hard disk detection system according to claim 7, which is characterized in that the detection module is specially to work as to search target When hard disk, the target detection item of the target hard disk is detected using target open source software or goal systems order, obtains the mesh Mark the module of the corresponding feedback result of detection;
Correspondingly, the judgment module is specially to judge whether the feedback result reaches the corresponding target of the target detection item Preset value, if it is not, then being deducted points according to basis point of the corresponding standard of deducting point of the target detection item to the target hard disk The module of operation.
9. a kind of electronic equipment characterized by comprising
Memory, for storing computer program;
Processor, realizing the hard disk detection method as described in any one of claim 1 to 6 when for executing the computer program Step.
10. a kind of computer readable storage medium, which is characterized in that be stored with computer on the computer readable storage medium Program realizes the step of the hard disk detection method as described in any one of claim 1 to 6 when the computer program is executed by processor Suddenly.
CN201811463380.7A 2018-12-03 2018-12-03 A kind of hard disk detection method, system and electronic equipment and storage medium Withdrawn CN109582515A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811463380.7A CN109582515A (en) 2018-12-03 2018-12-03 A kind of hard disk detection method, system and electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811463380.7A CN109582515A (en) 2018-12-03 2018-12-03 A kind of hard disk detection method, system and electronic equipment and storage medium

Publications (1)

Publication Number Publication Date
CN109582515A true CN109582515A (en) 2019-04-05

Family

ID=65926014

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811463380.7A Withdrawn CN109582515A (en) 2018-12-03 2018-12-03 A kind of hard disk detection method, system and electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN109582515A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109992217A (en) * 2019-04-11 2019-07-09 苏州浪潮智能科技有限公司 A kind of method for controlling quality of service, device, electronic equipment and storage medium
WO2021043246A1 (en) * 2019-09-06 2021-03-11 华为技术有限公司 Data reading method and apparatus

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109992217A (en) * 2019-04-11 2019-07-09 苏州浪潮智能科技有限公司 A kind of method for controlling quality of service, device, electronic equipment and storage medium
CN109992217B (en) * 2019-04-11 2020-05-29 苏州浪潮智能科技有限公司 Service quality control method and device, electronic equipment and storage medium
WO2021043246A1 (en) * 2019-09-06 2021-03-11 华为技术有限公司 Data reading method and apparatus

Similar Documents

Publication Publication Date Title
US10310957B2 (en) Indicating an application status based on a device state
US8352800B2 (en) Universal serial bus system and method
US20060259902A1 (en) Embedded system self-updating method and device
CN104199767B (en) Test method and device
CN110597675B (en) Chip testing method, device, storage medium and burner
CN104331373A (en) Monkey test system and method
CN103049363B (en) Verification method of NAND (neither agree not disagree) Flash controller
TWI498874B (en) Display electronic device and backlight adjustment method thereof
CN109857356A (en) A kind of screen display method, electronic equipment and storage medium
CN103929676B (en) Method for remotely testing functions of intelligent television board card and intelligent television board card
CN107992399A (en) A kind of memory bar condition detection method, apparatus and system
CN104881355A (en) Method and system for testing test coverage
CN107391195A (en) A kind of method that SSD FW upgradings are carried out under linux
CN109582515A (en) A kind of hard disk detection method, system and electronic equipment and storage medium
CN105975289A (en) Method and device for obtaining hardware version information
CN107038120A (en) A kind of method for testing software and equipment
CN102866897A (en) Computer and method for determining display contents
CN115408212A (en) System and method for parallel automatic testing of partitioned namespace solid state drives
US9596654B2 (en) Association of applications to clusters mapped to logical battery partitions
CN109375871A (en) A kind of log processing method, system and electronic equipment and storage medium
CN104809053A (en) Control style testing method and device
CN113608684A (en) Memory information acquisition method, device and system, electronic equipment and storage medium
CN112445670B (en) eMMC test method and device
CN113204456A (en) Test method, tool, device and equipment for VPP interface of server
CN112463602A (en) User interface testing method and system

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
WW01 Invention patent application withdrawn after publication
WW01 Invention patent application withdrawn after publication

Application publication date: 20190405