A bad block detection method and system for solid state hard disk

By dynamically adjusting the bad block number threshold of the solid-state drive and based on the characteristic parameters and status changes of the hard drive, the problem of false alarms of the solid-state drive under high load conditions in the existing technology is solved, achieving more accurate hard drive status monitoring and early warning, and extending the extends the service life of the hard drive.

CN118394609BActive Publication Date: 2024-09-03SHENZHEN LINGDECHUANG TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410867646.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-07-01
Publication Date
2024-09-03
Estimated Expiration
2044-07-01

AI Technical Summary

Technical Problem

Existing bad block detection methods for solid-state drives cannot dynamically adjust the bad block number threshold based on the performance and environment of the hard drive, which may result in false alarms or failure to detect hard drive problems in a timely manner under high load conditions.

Method used

By continuously collecting the characteristic parameters of the solid-state drive, such as the number of storage blocks, the number of erases and writes, and the operating temperature, the abnormal state index and change rate are generated, and the proportion threshold of the number of bad blocks is dynamically adjusted to achieve real-time monitoring and early warning of the hard drive status.

Benefits of technology

It optimizes the utilization rate and applicability of solid-state drives, avoids false alarms, extends the service life of hard drives, and enhances system flexibility and performance.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118394609B
    Figure CN118394609B
Patent Text Reader

Abstract

The present invention provides a method and system for detecting bad blocks of a solid-state hard disk, and relates to the technical field of storage block detection of solid-state hard disks. The specific steps include: S1. Continuously collecting characteristic parameters of the solid-state hard disk at time T-1 and time T, wherein the characteristic parameters include the total number of storage blocks, the number of erases and writes, the operating temperature, and the cumulative running time; S2. Dimensionless processing is performed on the characteristic parameters of the solid-state hard disk collected at time T-1 and time T, and correlation analysis is performed to generate a first abnormal state index and a second abnormal state index for characterizing the abnormal degree of the solid-state hard disk. The present invention can change the upper limit of the number of bad blocks of the solid-state hard disk, so that the threshold value of the proportion of the number of bad blocks can be dynamically changed according to different environments and workloads, the utilization rate and applicability of the solid-state hard disk are optimized, and false alarms are avoided at the same time, and the flexible adjustment of the threshold value makes the system more flexible, which can extend the service life of the solid-state hard disk and enhance the performance.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of storage block detection of solid state hard disks, and in particular to a bad block detection method and system of solid state hard disks. Background Art

[0002] With the development and widespread application of technologies such as the Internet, cloud computing, and the Internet of Things, massive amounts of data are generated at all times in human life and need to be processed and stored. The rapid development of information technology has put forward higher requirements on the performance of storage systems. Solid-state drives are widely used because of their fast read and write speeds and low energy consumption.

[0003] In the prior art, a hard disk monitoring method, system, device and medium provided by publication number CN114116374A includes obtaining the current number of bad blocks on each physical LUN; in response to detecting a new bad block, obtaining the cumulative number of bad blocks according to the current number of bad blocks on the corresponding physical LUN, and judging whether to trigger an alarm according to the alarm strategy corresponding to each monitoring parameter, multiple values ​​collected periodically and the corresponding threshold, further including: in response to the current number of bad blocks on the corresponding physical LUN, obtaining the cumulative number of bad blocks is greater than the bad block number threshold, triggering a first-level alarm, and in response to detecting a new bad block, obtaining the cumulative number of bad blocks according to the current number of bad blocks on the corresponding physical LUN. Therefore, the current status of the SSD is analyzed from multiple dimensions, and the alarm information is reported in time when the SSD disk failure is predicted.

[0004] However, there are still the following shortcomings. From the above statements, it can be seen that the bad block number threshold of the hard disk cannot be changed according to its own performance, different environments and workloads. Therefore, the storage block utilization and applicability of the hard disk need to be optimized. In addition, different environments and conditions may produce different loads and pressures on the solid-state drive. If the bad block number threshold is fixed, then under high load conditions, it may cause false alarms or fail to detect real hard disk problems in time. If the bad block number threshold is set too low, it may cause frequent alarms, and these alarms do not necessarily mean that the hard disk has failed.

[0005] The above information disclosed in this Background section is only for enhancement of understanding of the background of the present disclosure and therefore it may contain information that does not constitute the prior art that is already known to one of ordinary skill in the art. Summary of the invention

[0006] The object of the present invention is to provide a bad block detection method and system for a solid state drive to solve the problems raised in the above background technology.

[0007] To achieve the above object, the present invention provides the following technical solutions:

[0008] A method for detecting bad blocks of a solid state drive, the specific steps comprising:

[0009] S1. Continuously collect characteristic parameters of the solid-state hard disk at time T-1 and time T, the characteristic parameters including the total number of storage blocks, number of erases and writes, operating temperature and cumulative operating time;

[0010] S2. Perform dimensionless processing on the characteristic parameters of the solid-state hard disk collected at the time T-1 and the time T, and perform correlation analysis to generate a first abnormal state index and a second abnormal state index for characterizing the abnormal degree of the solid-state hard disk, and generate a change rate of the solid-state hard disk state from the time T-1 to the time T according to the first abnormal state index and the second abnormal state index;

[0011] S3. The second abnormal state index of the solid state hard disk and the change rate of the solid state hard disk state at the time T are dimensionless processed, and correlation analysis is performed to generate a change coefficient of the solid state hard disk state, and the total number of storage blocks of the solid state hard disk and the change coefficient of the solid state hard disk state are dimensionless processed, and correlation analysis is performed to generate a percentage threshold of the number of bad blocks;

[0012] S4. Detect the total storage block status of the solid-state hard disk at time T, mark the storage block status as normal blocks and bad blocks, and count the number of normal blocks and bad blocks of the solid-state hard disk;

[0013] S5. Process the statistical number of normal blocks and bad blocks of the solid-state drive to generate a percentage of the number of bad blocks;

[0014] S6. Compare the bad block ratio with the generated bad block ratio threshold, generate a level signal, and execute corresponding early warning prompts according to the level signal.

[0015] Furthermore, the characteristic parameters of the solid state hard disk collected at time T-1 are dimensionless processed and correlation analysis is performed to generate a first abnormal state index for characterizing the abnormal degree of the solid state hard disk. , based on the following formula:

[0016] ;

[0017] in, is the total number of storage blocks of the SSD, is the number of times the solid state drive is erased and written at time T-1, is the operating temperature of the solid state drive at time T-1, is the cumulative running time of the solid state drive at time T-1, is the ratio of the number of erase and write times of the solid-state drive at time T-1, is the coefficient of the operating temperature of the solid state drive at time T-1, is the percentage of the accumulated running time of the solid-state drive at time T-1, ,and , C1 is the constant correction coefficient.

[0018] Furthermore, the characteristic parameters of the solid state hard disk collected at time T are dimensionless processed and correlation analysis is performed to generate a second abnormal state index for characterizing the abnormal degree of the solid state hard disk. , based on the following formula:

[0019] ;

[0020] in, is the total number of storage blocks of the SSD, is the number of times the solid state drive is erased and written at time T, is the operating temperature of the solid state drive at time T, is the cumulative running time of the solid-state drive at time T, is the ratio of the number of erase and write times of the solid-state drive at time T, is the coefficient of the operating temperature of the solid state drive at time T, is the proportion coefficient of the accumulated operation time of the solid-state drive at time T. The influence of the number of erase and write times, accumulated operation time and operating temperature of the solid-state drive on the performance and reliability of the solid-state drive decreases in turn. Therefore ,and , C2 is the constant correction coefficient.

[0021] Further, according to the first abnormal state index and the second abnormal state index , the rate of change of the SSD state from time T-1 to time T is generated, based on the following formula:

[0022] ;

[0023] Among them, the second abnormal state index Greater than the first abnormal state index , so the rate of change of the SSD state from time T-1 to time T is .

[0024] Further, the second abnormal state index of the solid state hard disk at time T is and the rate of change of SSD status Perform dimensionless processing and correlation analysis to generate the coefficient of change of the SSD status , based on the following formula:

[0025] ;

[0026] in, ,when When the SSD state changes, .

[0027] The total number of storage blocks of the solid state drive and the coefficient of variation of the SSD status Perform dimensionless processing and correlation analysis to generate a threshold for the percentage of bad blocks , based on the following formula:

[0028] ;

[0029] Furthermore, the method and process of detecting the total storage block status of the solid state hard disk at time T, marking the storage block status as normal blocks and bad blocks, and counting the number of normal blocks and the number of bad blocks of the solid state hard disk are as follows:

[0030] S11. Reading storage blocks: First, the system attempts to read the contents of each storage block by sending a read request through the hard disk controller and then receiving the data in the storage block;

[0031] S12. Check the read result: The system checks the read result of each storage block. If the read is successful and the data is consistent with the expected value, the storage block is marked as a normal block; if the read fails, or the read data does not match the expected value, the storage block may be marked as a bad block;

[0032] S13. Statistical quantity: Count the number of normal blocks and bad blocks of the solid state drive.

[0033] Furthermore, the counted number of normal blocks and the number of bad blocks of the solid state drive are processed to generate a ratio of the number of bad blocks, according to the following formula:

[0034] ;

[0035] in, is the percentage of bad blocks in the solid state drive, is the number of bad blocks of the SSD, is the normal number of blocks of a solid state drive.

[0036] Furthermore, the proportion of the number of bad blocks The percentage threshold of the number of bad blocks generated By comparison, the process of generating a level signal is as follows:

[0037] when , then the number of bad blocks on the hard disk is within an acceptable range, and a first-level signal is issued;

[0038] when , the number of bad blocks on the hard disk exceeds the acceptable range, and a second-level signal is issued;

[0039] According to the generated level signal, the process of executing the corresponding early warning prompt is as follows:

[0040] When the generated level signal is the first level signal, no warning prompt is issued;

[0041] When the generated level signal is a second level signal, an early warning prompt is issued.

[0042] A bad block detection system for a solid state hard disk, comprising:

[0043] A data acquisition module, used to continuously collect characteristic parameters of the solid-state hard disk at time T-1 and time T, wherein the characteristic parameters include the total number of storage blocks, the number of erase and write times, the operating temperature and the accumulated running time;

[0044] A first data processing module is used to perform dimensionless processing on the characteristic parameters of the solid-state hard disk collected at the time T-1 and the time T, and perform correlation analysis to generate a first abnormal state index and a second abnormal state index for characterizing the abnormal degree of the solid-state hard disk, and generate a change rate of the solid-state hard disk state from the time T-1 to the time T according to the first abnormal state index and the second abnormal state index;

[0045] A data analysis module, for performing dimensionless processing on the second abnormal state index of the solid state drive and the change rate of the solid state drive state at the time T, and performing correlation analysis to generate a change coefficient of the solid state drive state, and performing dimensionless processing on the total number of storage blocks of the solid state drive and the change coefficient of the solid state drive state, and performing correlation analysis to generate a percentage threshold of the number of bad blocks;

[0046] A detection module is used to detect the total storage block status of the solid state drive at time T, mark the storage block status as normal blocks and bad blocks, and count the number of normal blocks and bad blocks of the solid state drive;

[0047] A second data processing module is used to process the counted number of normal blocks and bad blocks of the solid state drive to generate a percentage of the number of bad blocks;

[0048] The comparison module compares the bad block ratio with the generated bad block ratio threshold, generates a level signal, and executes corresponding early warning prompts according to the level signal.

[0049] Compared with the prior art, the present invention has the following beneficial effects:

[0050] The present invention continuously collects characteristic parameters of the solid state hard disk at time T-1 and time T, processes and analyzes the characteristic parameters of the solid state hard disk collected at time T-1 and time T, respectively generates a first abnormal state index and a second abnormal state index for characterizing the abnormal degree of the solid state hard disk, generates a change rate of the solid state hard disk state from time T-1 to time T according to the first abnormal state index and the second abnormal state index, processes and analyzes the second abnormal state index of the solid state hard disk and the change rate of the solid state hard disk state at time T, generates a change coefficient of the solid state hard disk state, processes and analyzes the total number of storage blocks of the solid state hard disk and the change coefficient of the solid state hard disk state, generates a percentage threshold of the number of bad blocks, compares the percentage of the number of bad blocks with the percentage threshold of the number of bad blocks, judges whether the number of bad blocks of the solid state hard disk reaches an upper limit, and the percentage threshold of the number of bad blocks is in the process of changing, so that the upper limit of the number of bad blocks of the solid state hard disk can be changed, so that the percentage threshold of the number of bad blocks can be dynamically changed according to different environments and workloads, the utilization rate and applicability of the solid state hard disk are optimized, and at the same time, false alarms are avoided, and the flexible adjustment of the threshold makes the system more flexible, which can extend the service life of the hard disk and enhance the use performance. BRIEF DESCRIPTION OF THE DRAWINGS

[0051] Figure 1 It is a schematic diagram of the overall method flow of the present invention;

[0052] Figure 2 It is a block diagram of the module composition of the present invention. DETAILED DESCRIPTION

[0053] In order to make the objectives, technical solutions and advantages of the present invention more clearly understood, the present invention is further described in detail below in conjunction with specific embodiments.

[0054] It should be noted that, unless otherwise defined, the technical terms or scientific terms used in the present invention should be understood by people with ordinary skills in the field to which the present invention belongs. The words "first", "second" and similar words used in the present invention do not indicate any order, quantity or importance, but are only used to distinguish different components. "Include" or "comprise" and similar words mean that the elements or objects appearing before the word include the elements or objects listed after the word and their equivalents, without excluding other elements or objects. "Connect" or "connected" and similar words are not limited to physical or mechanical connections, but may include electrical connections, whether direct or indirect. "Up", "down", "left", "right" and the like are only used to indicate relative positional relationships. When the absolute position of the described object changes, the relative positional relationship may also change accordingly.

[0055] Example:

[0056] See also Figure 1 to Figure 2, the present invention provides a technical solution:

[0057] A bad block detection method for a solid state hard disk, such as Figure 1 As shown, the specific steps include:

[0058] S1. Continuously collect characteristic parameters of the solid-state hard disk at time T-1 and time T, the characteristic parameters including the total number of storage blocks, number of erases and writes, operating temperature and cumulative operating time;

[0059] S2. The characteristic parameters of the solid state hard disk collected at the time T-1 and the time T are dimensionlessly processed, and correlation analysis is performed to generate a first abnormal state index and a second abnormal state index for characterizing the abnormal degree of the solid state hard disk, and a change rate of the solid state hard disk state from the time T-1 to the time T is generated according to the first abnormal state index and the second abnormal state index;

[0060] S3. The second abnormal state index of the solid state drive and the change rate of the solid state drive state at time T are dimensionless processed, and correlation analysis is performed to generate a change coefficient of the solid state drive state, and the total number of storage blocks of the solid state drive and the change coefficient of the solid state drive state are dimensionless processed, and correlation analysis is performed to generate a percentage threshold of the number of bad blocks;

[0061] S4. Detect the total storage block status of the solid-state hard disk at time T, mark the storage blocks as normal blocks and bad blocks, and count the number of normal blocks and bad blocks of the solid-state hard disk;

[0062] S5. Process the counted number of normal blocks and bad blocks of the solid state drive to generate a percentage of the number of bad blocks;

[0063] S6. Compare the bad block ratio with the generated bad block ratio threshold, generate a level signal, and execute corresponding early warning prompts according to the level signal.

[0064] In step S1, when the number of times the solid state drive is erased and written increases, the performance and reliability of the solid state drive decrease. The specific reasons are as follows:

[0065] Limited erase and write life: The storage cells in SSDs are usually based on flash memory technology. Flash memory cells have a limited lifespan during the erase and write process. Each storage cell can be erased and written several times. After exceeding this limit, the storage cell may become unreliable, resulting in performance degradation.

[0066] Write amplification: An increase in the number of erase and write times may lead to write amplification, that is, the ratio between the actual amount of data written and the amount of data requested by the application layer increases. This is because a write operation usually requires erasing the original data before writing new data. Write amplification increases the write operations to the memory, resulting in more erase and write operations, which accelerates the wear of the storage unit.

[0067] Erase and write wear: Erase and write operations usually consume more of the life of the solid-state drive than read operations. When the number of erase and write times increases, the storage unit experiences more erase and write operations, resulting in increased wear of the storage medium, which in turn affects the reliability of the hard drive.

[0068] Performance degradation: As the number of erase and write cycles increases, the performance of the SSD may gradually decline, write operations may take longer, and read operations may become slower, which may have a negative impact on the response speed and performance of the entire system.

[0069] Therefore, detecting the number of times a solid-state drive is erased and written is particularly important for monitoring the performance and reliability of the solid-state drive. If this can be done, the following effects will occur:

[0070] Hard disk life prediction: By monitoring the number of erase and write cycles, the life of the solid-state drive can be predicted more accurately. An increase in the number of erase and write cycles is usually associated with the wear of the storage unit, so it can be used as an important indicator to estimate the remaining life of the hard disk, which helps users take appropriate preventive measures before the hard disk may fail, such as backing up data or replacing the hard disk.

[0071] Maintenance and prevention: Timely detection of increased erase and write counts can help with maintenance and preventive measures to prevent the hard drive from experiencing performance degradation and reduced reliability due to prolonged erase and write operations. This can include performing operations such as erase and write leveling, load balancing, and garbage collection to slow down the wear of the hard drive.

[0072] Performance optimization: By monitoring the number of erase and write cycles, potential performance issues can be identified. When the number of erase and write cycles is too high, it may indicate that there are too many write operations, which may cause performance degradation. Taking appropriate measures, such as optimizing the file system and reducing write amplification, can help improve the performance of the hard drive.

[0073] Ensure data reliability: Monitoring the number of erase and write cycles helps ensure data reliability. When the number of erase and write cycles is too high, there may be a risk of data writing errors. Regular monitoring and maintenance operations can reduce this risk and ensure the integrity of stored data.

[0074] In step S1, when the operating temperature of the solid state drive increases, the performance and reliability of the solid state drive decrease. The specific reasons are as follows:

[0075] Accelerated erase and write wear: High temperature environment will accelerate the erase and write wear of storage units in solid-state drives. During the erase and write operation, the erasure and rewriting of storage units may occur more easily, resulting in an increased aging rate of the storage units, thereby reducing the life of the hard drive.

[0076] Increased bad block rate: High temperature may cause the flash memory particles in the storage medium to age, thereby increasing the rate of bad blocks. Bad blocks will affect the reliability of the hard disk and may cause data damage or loss.

[0077] Degraded performance of electronic devices: High temperature has an adverse effect on the performance of electronic devices in SSDs (such as controllers, memory chips, etc.). Electronic components may increase resistance and decrease conductivity under high temperature, thus affecting the overall performance of the SSD.

[0078] Increased write amplification effect: In high temperature environments, the write amplification effect may be exacerbated. The write amplification effect means that the amount of data actually written to the storage medium is much larger than the amount of data to be written, which will lead to more frequent write operations and increase the rapid wear of the storage medium.

[0079] Reduced read and write speeds: High temperatures may cause increased electron movement inside the storage media, thereby affecting read and write speeds. This may lead to increased data access latency and reduce the overall performance of the SSD.

[0080] Poor thermal conductivity: In a high-temperature environment, poor heat dissipation may cause the internal temperature of the solid-state drive to rise. If the heat dissipation design is insufficient, the hard drive may not be able to dissipate heat effectively, exacerbating the temperature rise and affecting the performance and reliability of the hard drive.

[0081] Increased risk of failure: Under high temperature conditions, the risk of failure of various components inside the hard drive will increase, including electronic components, connectors, etc., which may lead to sudden failure of the hard drive and affect data integrity and availability.

[0082] Therefore, detecting the operating temperature of the SSD is particularly important for monitoring the performance and reliability of the SSD. If this can be done, the following effects will occur:

[0083] Predicting hard drive life: Temperature is one of the important factors that affect the life of solid-state drives. By monitoring the operating temperature, administrators can better predict the life of the hard drive. In a high temperature environment, the hard drive may be more susceptible to factors such as erase and write wear, thereby providing early warning of the end of the hard drive life and helping to plan replacement and maintenance plans.

[0084] Optimize heat dissipation design: By detecting the operating temperature, you can evaluate the heat dissipation effect of the hard disk. If the operating temperature is high, you may need to optimize the heat dissipation design to ensure that the hard disk operates within the appropriate temperature range to improve performance and reliability.

[0085] Prevent hard disk overheating: Timely monitoring of operating temperature can help administrators prevent the risk of hard disk overheating. Excessive temperature may lead to performance degradation and increased risk of failure. Through real-time monitoring, administrators can take measures such as improving heat dissipation and adjusting device layout to prevent hard disk overheating.

[0086] Improve data reliability: Appropriate operating temperature helps maintain the stability of the hard disk's internal components, thereby improving data reliability. Excessively high temperatures may cause storage media aging and increase the bad block rate. By detecting the temperature, measures can be taken to reduce these adverse effects.

[0087] Planning maintenance cycles: Monitoring operating temperature helps plan hard drive maintenance cycles. If the temperature is consistently too high, more frequent hard drive inspections and maintenance may be required to ensure the hard drive is operating in good condition.

[0088] Improve system stability: By detecting operating temperature, administrators can better plan system cooling and hard disk maintenance to improve overall system stability. A stable system helps prevent data loss and system crashes.

[0089] In step S1, as the accumulated running time of the solid state drive increases, the performance and reliability of the solid state drive decrease. The specific reasons are as follows:

[0090] Erase and write wear: The storage cells in the solid-state drive will undergo a physical erase and rewrite process during the erase and write operation. As the running time increases, these operations will cause the storage cells to wear out, thereby affecting performance.

[0091] Increased bad blocks: Storage cells in the SSD may become unusable, forming bad blocks. As the operating time increases, the number of bad blocks may increase, thereby reducing the reliability and performance of the hard drive.

[0092] Write amplification effect: The write amplification effect in SSDs refers to the fact that the amount of data actually written to the storage medium when writing data may be much larger than the data to be written. As the running time increases, the write amplification effect may intensify, resulting in rapid wear and tear of the storage medium, which in turn affects performance.

[0093] Flash memory failure: The flash memory chip in the solid-state drive may fail as the running time increases. This may be caused by too many erase and write times, aging of the storage unit, or other reasons, which will cause data corruption or hard drive failure, affecting performance and reliability.

[0094] Temperature and environmental factors: Long-term operation may cause the solid-state drive to be affected by temperature and environmental factors, such as high temperature and humidity, which may further aggravate the aging and failure of the hard drive.

[0095] SSD controller wear: The controller in the SSD may also wear out over time, affecting its performance and reliability.

[0096] Therefore, detecting the cumulative running time of the SSD is particularly important for monitoring the performance and reliability of the SSD. If this can be done, the following effects will occur:

[0097] Predicting hard drive life: By monitoring the operating time of the solid-state drive, the life of the hard drive can be better predicted. Knowing the operating time of the hard drive can help administrators develop more reasonable maintenance plans and data backup strategies to reduce the risk of data loss due to hard drive failure.

[0098] Planning maintenance cycles: Monitoring the running time helps plan maintenance cycles. The life of a hard drive is not only affected by the number of writes, but the running time is also a key factor. Regular maintenance can include erasing unnecessary data, performing health checks, or replacing aging hard drives in a timely manner, thereby improving the stability and reliability of the entire system.

[0099] Prevent hard drive failure: SSDs that have been running for a long time are more likely to have potential problems. Through timely monitoring, potential signs of failure can be identified before the hard drive fails, and preventive measures can be taken to reduce the risk of hard drive failure.

[0100] Improve system stability: By timely monitoring the operating time of the SSD, administrators can better plan maintenance and upgrade plans, thereby improving the stability of the entire system. Preventive hard drive maintenance can reduce the risk of system crashes or data loss.

[0101] Optimize performance management: As the running time increases, the hard disk may experience performance degradation. By monitoring the running time, the administrator can better optimize the performance management strategy, such as reasonably arranging data migration, load balancing, etc., to maintain the high performance state of the system.

[0102] Improve data security: Timely detection of the operating time of the SSD can help plan and implement more effective data backup strategies to improve data security. Before the hard drive reaches the end of its life, administrators can take necessary measures to ensure data integrity and recoverability.

[0103] Based on the above embodiment, the characteristic parameters of the solid state hard disk collected at time T-1 are dimensionless processed and correlation analysis is performed to generate a first abnormal state index for characterizing the abnormal degree of the solid state hard disk. , based on the following formula:

[0104] ;

[0105] in, is the total number of storage blocks of the SSD, is the number of times the solid state drive is erased and written at time T-1, is the operating temperature of the solid state drive at time T-1, is the cumulative running time of the solid state drive at time T-1, is the ratio of the number of erase and write times of the solid-state drive at time T-1, is the coefficient of the operating temperature of the solid state drive at time T-1, is the proportion of the accumulated operation time of the SSD at time T-1. The number of erase and write times, accumulated operation time and operating temperature of the SSD have a decreasing influence on the performance and reliability of the SSD. Therefore ,and , C1 is the constant correction coefficient.

[0106] From the above formula, we can see that when , and The higher the value, the higher the first abnormal state index of the SSD state at time T-1. The lower the , , and They are all negatively correlated, and the factor coefficient is used to balance the proportion of each data in the formula, thereby promoting the accuracy of the calculation results.

[0107] The characteristic parameters of the solid state hard disk collected at time T are dimensionless processed and correlation analysis is performed to generate a second abnormal state index for characterizing the abnormal degree of the solid state hard disk , based on the following formula:

[0108] ;

[0109] in, is the total number of storage blocks of the SSD, is the number of times the solid state drive is erased and written at time T, is the operating temperature of the solid state drive at time T, is the cumulative running time of the solid-state drive at time T, is the ratio of the number of erase and write times of the solid-state drive at time T, is the coefficient of the operating temperature of the solid state drive at time T, is the proportion coefficient of the accumulated operation time of the solid-state drive at time T. The influence of the number of erase and write times, accumulated operation time and operating temperature of the solid-state drive on the performance and reliability of the solid-state drive decreases in turn. Therefore ,and , C2 is the constant correction coefficient.

[0110] From the above formula, we can see that when , and The higher the value, the higher the second abnormal state index of the SSD state at time T. The lower the , , and They are all negatively correlated, and the factor coefficient is used to balance the proportion of each data in the formula, thereby promoting the accuracy of the calculation results.

[0111] Based on the above embodiment, according to the first abnormal state index and the second abnormal state index , the rate of change of the SSD state from time T-1 to time T is generated, based on the following formula:

[0112] ;

[0113] According to the above formula, under normal circumstances, the performance of the SSD will gradually decrease as the running time increases, so the second abnormal state index Greater than the first abnormal state index , so the rate of change of the SSD state from time T-1 to time T is .

[0114] Based on the above embodiment, the second abnormal state index of the solid state hard disk at time T is and the rate of change of SSD status Perform dimensionless processing and correlation analysis to generate the coefficient of change of the SSD status , based on the following formula:

[0115] ;

[0116] in, According to the above formula, when When the SSD state changes, .

[0117] The total number of storage blocks on the SSD and the coefficient of variation of the SSD status Perform dimensionless processing and correlation analysis to generate a threshold for the percentage of bad blocks , based on the following formula:

[0118] ;

[0119] According to the above formula, when , the percentage threshold of bad blocks Smaller than the total number of storage blocks on the SSD .

[0120] Based on the above embodiment, the method and process of detecting the total storage block status of the solid state hard disk at time T, marking the storage blocks as normal blocks and bad blocks, and counting the number of normal blocks and the number of bad blocks of the solid state hard disk are as follows:

[0121] S11. Reading storage blocks: First, the system attempts to read the contents of each storage block by sending a read request through the hard disk controller and then receiving the data in the storage block;

[0122] S12. Check the read result: The system checks the read result of each storage block. If the read is successful and the data is consistent with the expected value, the storage block is marked as a normal block; if the read fails, or the read data does not match the expected value, the storage block may be marked as a bad block;

[0123] S13. Statistical quantity: Count the number of normal blocks and bad blocks of the solid state drive.

[0124] On the basis of the above embodiment, the statistical number of normal blocks and bad blocks of the solid state drive are processed to generate the proportion of the number of bad blocks, according to the following formula:

[0125] ;

[0126] in, is the percentage of bad blocks in the solid state drive, is the number of bad blocks of the SSD, is the normal number of blocks of a solid state drive.

[0127] Based on the above embodiment, the proportion of bad blocks is The percentage threshold of the number of bad blocks generated By comparison, the process of generating a level signal is as follows:

[0128] when , then the number of bad blocks on the hard disk is within an acceptable range, and a first-level signal is issued;

[0129] when , the number of bad blocks on the hard disk exceeds the acceptable range, and a second-level signal is issued;

[0130] According to the generated level signal, the process of executing the corresponding early warning prompt is as follows:

[0131] When the generated level signal is the first level signal, no warning prompt is issued;

[0132] When the generated level signal is a second level signal, an early warning prompt is issued.

[0133] In the formula , and The specific value of is generally determined by those skilled in the art according to actual conditions. The essence of this formula is a comprehensive analysis by weighted summation. The technicians in this field collect multiple groups of sample data, and set corresponding preset proportional coefficients for each group of sample data. The preset proportional coefficients and the collected sample data are substituted into the formula. Through repeated experiments and parameter adjustments, the accuracy of the model output and the rationality of the results are observed, and these proportional factor coefficients are gradually adjusted. The performance and effect of the model under different parameter settings are compared to find the optimal coefficient combination. The calculated proportional factor coefficients are screened and averaged to obtain , and The value of .

[0134] In addition, the size of the preset proportional factor coefficient is to quantize each parameter to obtain a specific value. In order to facilitate subsequent comparison, the size of the proportional factor coefficient depends on the amount of sample data and the preliminary setting of the corresponding preset proportional factor coefficient for each set of sample data by technical personnel in this field. It is not unique as long as it does not affect the proportional relationship between the parameter and the quantized value.

[0135] The above formulas are all dimensionless and numerical calculations. The formula is a formula for the most recent real situation obtained by collecting a large amount of data and performing software simulation. The preset parameters in the formula are set by technicians in this field according to actual conditions.

[0136] See also Figure 2 The present invention further provides a bad block detection system for a solid state hard disk, the detection system is applied to the above-mentioned bad block detection method for a solid state hard disk, and comprises:

[0137] A data acquisition module, used to continuously collect characteristic parameters of the solid-state hard disk at time T-1 and time T, wherein the characteristic parameters include the total number of storage blocks, the number of erase and write times, the operating temperature and the accumulated running time;

[0138] A first data processing module is used to perform dimensionless processing on the characteristic parameters of the solid-state hard disk collected at the time T-1 and the time T, and perform correlation analysis to generate a first abnormal state index and a second abnormal state index for characterizing the abnormal degree of the solid-state hard disk, and generate a change rate of the solid-state hard disk state from the time T-1 to the time T according to the first abnormal state index and the second abnormal state index;

[0139] A data analysis module, for performing dimensionless processing on the second abnormal state index of the solid state drive and the change rate of the solid state drive state at the time T, and performing correlation analysis to generate a change coefficient of the solid state drive state, and performing dimensionless processing on the total number of storage blocks of the solid state drive and the change coefficient of the solid state drive state, and performing correlation analysis to generate a percentage threshold of the number of bad blocks;

[0140] A detection module is used to detect the total storage block status of the solid state drive at time T, mark the storage blocks as normal blocks and bad blocks, and count the number of normal blocks and bad blocks of the solid state drive;

[0141] A second data processing module is used to process the counted number of normal blocks and bad blocks of the solid state drive to generate a percentage of the number of bad blocks;

[0142] The comparison module compares the bad block ratio with the generated bad block ratio threshold, generates a level signal, and executes corresponding early warning prompts according to the level signal.

[0143] The above embodiments may be implemented in whole or in part by software, hardware, firmware or any other combination thereof. When implemented using software, the above embodiments may be implemented in whole or in part in the form of a computer program product. Those skilled in the art may appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein may be implemented by computer software, electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed by hardware or software depends on the specific application and design constraints of the technical solution.

[0144] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, and may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0145] The above description is only a specific implementation manner of the present application, but the protection scope of the present application is not limited thereto. Any technician familiar with the technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application.

Claims

1. A method for detecting bad blocks of a solid state drive, characterized in that: The specific steps include: S1. Continuously collect characteristic parameters of the solid-state hard disk at time T-1 and time T, the characteristic parameters including the total number of storage blocks, number of erases and writes, operating temperature and cumulative operating time; S2. Perform dimensionless processing on the characteristic parameters of the solid-state hard disk collected at the time T-1 and the time T, and perform correlation analysis to generate a first abnormal state index and a second abnormal state index for characterizing the abnormal degree of the solid-state hard disk, and generate a change rate of the solid-state hard disk state from the time T-1 to the time T according to the first abnormal state index and the second abnormal state index; S3. The second abnormal state index of the solid state hard disk and the change rate of the solid state hard disk state at the time T are dimensionless processed, and correlation analysis is performed to generate a change coefficient of the solid state hard disk state, and the total number of storage blocks of the solid state hard disk and the change coefficient of the solid state hard disk state are dimensionless processed, and correlation analysis is performed to generate a percentage threshold of the number of bad blocks; S4. Detect the total storage block status of the solid-state hard disk at time T, mark the storage block status as normal blocks and bad blocks, and count the number of normal blocks and bad blocks of the solid-state hard disk; S5. Process the statistical number of normal blocks and bad blocks of the solid-state drive to generate a percentage of the number of bad blocks; S6. Compare the percentage of the number of bad blocks with the generated threshold value of the number of bad blocks to generate a level signal, and execute the corresponding warning prompt according to the level signal; The characteristic parameters of the solid state hard disk collected at the time T-1 are dimensionless processed and correlation analyzed to generate a first abnormal state index for characterizing the abnormality degree of the solid state hard disk. , based on the following formula: ; in, is the total number of storage blocks of the SSD, is the number of times the solid state drive is erased and written at time T-1, is the operating temperature of the solid state drive at time T-1, is the cumulative running time of the solid state drive at time T-1, is the ratio of the number of erase and write times of the solid-state drive at time T-1, is the coefficient of the operating temperature of the solid state drive at time T-1, is the percentage of the accumulated running time of the solid-state drive at time T-1, ,and , C1 is the constant correction coefficient; The characteristic parameters of the solid state hard disk collected at time T are dimensionless processed and correlation analysis is performed to generate a second abnormal state index for characterizing the abnormal degree of the solid state hard disk , based on the following formula: ; in, is the total number of storage blocks of the SSD, is the number of times the solid state drive is erased and written at time T, is the operating temperature of the solid state drive at time T, is the cumulative running time of the solid-state drive at time T, is the ratio of the number of erase and write times of the solid-state drive at time T, is the coefficient of the operating temperature of the solid state drive at time T, is the proportion coefficient of the accumulated operation time of the solid-state drive at time T. The influence of the number of erase and write times, accumulated operation time and operating temperature of the solid-state drive on the performance and reliability of the solid-state drive decreases in turn. Therefore ,and , C2 is the constant correction coefficient; According to the first abnormal state index and the second abnormal state index , the rate of change of the SSD state from time T-1 to time T is generated, based on the following formula: ; Among them, the second abnormal state index Greater than the first abnormal state index , so the rate of change of the SSD state from time T-1 to time T is ; The second abnormal state index of the solid state hard disk at time T and the rate of change of SSD status Perform dimensionless processing and correlation analysis to generate the coefficient of change of the SSD status , based on the following formula: ; in, ,when When the SSD state changes, ; The total number of storage blocks of the solid state drive and the coefficient of variation of the SSD status Perform dimensionless processing and correlation analysis to generate a threshold for the percentage of bad blocks , based on the following formula:

2. The method for detecting bad blocks of a solid state drive according to claim 1, characterized in that: The method and process of detecting the total storage block status of the solid state hard disk at time T, marking the storage block status as normal blocks and bad blocks, and counting the number of normal blocks and the number of bad blocks of the solid state hard disk are as follows: Reading storage blocks: The system attempts to read the contents of each storage block, sending a read request through the hard disk controller and then receiving the data in the storage block; Check the read result: The system checks the read result of each storage block. If the read is successful and the data matches the expected value, the storage block is marked as a normal block; if the read fails, or the read data does not match the expected value, the storage block is marked as a bad block. Statistics: count the number of normal blocks and bad blocks of the SSD.

3. The bad block detection method of a solid state drive according to claim 2, characterized in that: The counted normal block number and bad block number of the solid state drive are processed to generate a ratio of the number of bad blocks, according to the following formula: ; in, is the percentage of bad blocks in the solid state drive, is the number of bad blocks of the solid state drive, is the normal number of blocks of a solid state drive.

4. The bad block detection method of a solid state drive according to claim 3, characterized in that: The proportion of the number of bad blocks The percentage threshold of the number of bad blocks generated By comparison, the process of generating a level signal is as follows: when , then the number of bad blocks on the hard disk is within an acceptable range, and a first-level signal is issued; when , the number of bad blocks on the hard disk exceeds the acceptable range, and a second-level signal is issued; According to the generated level signal, the process of executing the corresponding early warning prompt is as follows: When the generated level signal is a first level signal, no warning prompt is issued; When the generated level signal is a second level signal, an early warning prompt is issued.

5. A bad block detection system for a solid state hard disk, the system being used to execute the bad block detection method for a solid state hard disk as claimed in any one of claims 1 to 4, characterized in that: include: A data acquisition module, used to continuously collect characteristic parameters of the solid-state hard disk at time T-1 and time T, wherein the characteristic parameters include the total number of storage blocks, the number of erase and write times, the operating temperature and the accumulated running time; A first data processing module is used to perform dimensionless processing on the characteristic parameters of the solid-state hard disk collected at the time T-1 and the time T, and perform correlation analysis to generate a first abnormal state index and a second abnormal state index for characterizing the abnormal degree of the solid-state hard disk, and generate a change rate of the solid-state hard disk state from the time T-1 to the time T according to the first abnormal state index and the second abnormal state index; A data analysis module, for performing dimensionless processing on the second abnormal state index of the solid state drive and the change rate of the solid state drive state at the time T, and performing correlation analysis to generate a change coefficient of the solid state drive state, and performing dimensionless processing on the total number of storage blocks of the solid state drive and the change coefficient of the solid state drive state, and performing correlation analysis to generate a percentage threshold of the number of bad blocks; A detection module is used to detect the total storage block status of the solid state drive at time T, mark the storage block status as normal blocks and bad blocks, and count the number of normal blocks and bad blocks of the solid state drive; A second data processing module is used to process the counted number of normal blocks and bad blocks of the solid state drive to generate a percentage of the number of bad blocks; The comparison module compares the bad block ratio with the generated bad block ratio threshold, generates a level signal, and executes corresponding early warning prompts according to the level signal.