CN112256193A - Method, device and storage medium for improving data security of solid state disk - Google Patents

Method, device and storage medium for improving data security of solid state disk Download PDF

Info

Publication number
CN112256193A
CN112256193A CN202010975185.3A CN202010975185A CN112256193A CN 112256193 A CN112256193 A CN 112256193A CN 202010975185 A CN202010975185 A CN 202010975185A CN 112256193 A CN112256193 A CN 112256193A
Authority
CN
China
Prior art keywords
flash memory
memory block
health
preset
error correction
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202010975185.3A
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.)
Zhejiang Dahua Technology Co Ltd
Original Assignee
Zhejiang Dahua 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 Zhejiang Dahua Technology Co Ltd filed Critical Zhejiang Dahua Technology Co Ltd
Priority to CN202010975185.3A priority Critical patent/CN112256193A/en
Publication of CN112256193A publication Critical patent/CN112256193A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0602Interfaces specially adapted for storage systems specifically adapted to achieve a particular effect
    • G06F3/062Securing storage systems
    • G06F3/0622Securing storage systems in relation to access
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0602Interfaces specially adapted for storage systems specifically adapted to achieve a particular effect
    • G06F3/0614Improving the reliability of storage systems
    • G06F3/0619Improving the reliability of storage systems in relation to data integrity, e.g. data losses, bit errors
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0628Interfaces specially adapted for storage systems making use of a particular technique
    • G06F3/0629Configuration or reconfiguration of storage systems
    • G06F3/0631Configuration or reconfiguration of storage systems by allocating resources to storage systems
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0628Interfaces specially adapted for storage systems making use of a particular technique
    • G06F3/0638Organizing or formatting or addressing of data
    • G06F3/064Management of blocks
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0668Interfaces specially adapted for storage systems adopting a particular infrastructure
    • G06F3/0671In-line storage system
    • G06F3/0673Single storage device
    • G06F3/0679Non-volatile semiconductor memory device, e.g. flash memory, one time programmable memory [OTP]

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Human Computer Interaction (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Security & Cryptography (AREA)
  • Techniques For Improving Reliability Of Storages (AREA)

Abstract

The application discloses a method, a device and a storage medium for improving data security of a solid state disk, wherein the method comprises the following steps: acquiring health information of each flash memory block in the solid state disk, wherein the health information comprises erasing times and error correction bits; calculating the health value of each flash memory block by using the erasing times and the error correction bits of each flash memory block; and selecting a target flash memory block matched with the data to be written based on the health values of all the idle flash memory blocks, and writing the data to be written into the target flash memory block. Through the mode, the data security and the service life of the solid state disk can be improved.

Description

Method, device and storage medium for improving data security of solid state disk
Technical Field
The present application relates to the field of computer technologies, and in particular, to a method, an apparatus, and a storage medium for improving data security of a solid state disk.
Background
The data of the solid state disk is stored on Flash memory (Flash) particles, and because the wear frequency of the Flash memory particles is limited, when the wear frequency of a Flash memory block exceeds a rated erasing frequency, programming failure or data reading errors, such as errors of UNC (Uncorrectable Read Error), are likely to occur, so that the data storage has a safety problem; in the traditional method, when the flash memory blocks are selected, the flash memory blocks are uniformly selected according to the erasing times, but the health state of the flash memory blocks with more erasing times is better than that of the flash memory blocks with less erasing times, and the health state of the flash memory blocks cannot be accurately estimated by the method, so that the reasonable use of the flash memory blocks is influenced.
Disclosure of Invention
The application provides a method, a device and a storage medium for improving data security of a solid state disk, which can improve data security and prolong service life of the solid state disk.
In order to solve the technical problem, the present application adopts a technical scheme that a method for improving data security of a solid state disk is provided, and the method includes: acquiring health information of each flash memory block in the solid state disk, wherein the health information comprises erasing times and error correction bits; calculating the health value of each flash memory block by using the erasing times and the error correction bits of each flash memory block; and selecting a target flash memory block matched with the data to be written based on the health values of all the idle flash memory blocks, and writing the data to be written into the target flash memory block.
In order to solve the technical problem, another technical solution adopted by the present application is to provide an apparatus for improving data security of a solid state disk, where the apparatus includes a memory and a processor connected to each other, where the memory is used for storing a computer program, and the computer program is used for implementing the above method for improving data security of a solid state disk when being executed by the processor.
In order to solve the technical problem, another technical solution adopted by the present application is to provide a computer-readable storage medium for storing a computer program, where the computer program is used to implement the method for improving the data security of the solid state disk when being executed by a processor.
Through the scheme, the beneficial effects of the application are that: the method comprises the steps that health information of each flash memory block in the solid state disk can be obtained firstly, wherein the health information comprises error correction bits and erasing times; then processing the error correction bit number and the erasing times to estimate the health value of each flash memory block; selecting a target flash memory block matched with the current data to be written according to the health values of all the idle flash memory blocks so as to write the data to be written into the target flash memory block; this application is when considering the in service behavior of flash memory block, not only erasing and writing number of times has not been considered, error correction's digit when still having considered reading data, thereby can characterize the health condition of flash memory block more comprehensively, it is more accurate to estimate the health value of flash memory block, when the storage data, the suitable idle flash memory block of optional saves, guarantee that the use of each flash memory block is more average, the health condition of flash memory block is roughly the same, prevent to be limited by the worst flash memory block of health condition because of the great life that leads to of health condition difference, can improve solid state hard disk's data security and life.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings needed to be used in the description of the embodiments are briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present application, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without creative efforts. Wherein:
fig. 1 is a schematic flowchart illustrating an embodiment of a method for improving data security of a solid state disk according to the present application;
fig. 2 is a schematic flowchart of another embodiment of a method for improving data security of a solid state disk according to the present application;
FIG. 3 is a schematic flow chart of step 27 in the embodiment shown in FIG. 2;
FIG. 4 is a schematic structural diagram illustrating an embodiment of an apparatus for improving data security of a solid state disk according to the present application;
FIG. 5 is a schematic structural diagram of an embodiment of a computer-readable storage medium provided in the present application.
Detailed Description
The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are only a part of the embodiments of the present application, and not all the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
In the existing scheme, when a flash memory block is selected, only the erasing times of the flash memory block are basically considered, the health condition of the flash memory block is represented by the erasing times, and the health condition of the flash memory block is judged more accurately without other auxiliary information.
Referring to fig. 1, fig. 1 is a schematic flowchart illustrating an embodiment of a method for improving data security of a solid state disk according to the present application, where the method includes:
step 11: and acquiring the health information of each flash memory block in the solid state disk.
Before data is written, health information of a solid state disk to be written in can be acquired, specifically, the solid state disk can be a solid state disk which comprises a plurality of flash memory blocks, and each flash memory block can be used for storing data; since the health condition of each flash memory block may be different, in order to ensure the security of data storage, the health information of each flash memory block may be obtained, where the health information includes the number of times of erasure and the number of error correction bits, and the number of error correction bits may be the number of bits for correcting erroneous data by using Low Density Parity Check (LDPC) to perform error correction.
Further, two pieces of information may be counted in advance for each flash block, first: counting the erasing times when erasing the flash memory block, and secondly: when the data in the flash memory block is read, the error correction bit number can be counted, so that the counted information can be directly obtained when the data is pre-written into the solid state disk.
Step 12: and calculating the health value of each flash memory block by using the erasing times and the error correction bit number of each flash memory block.
After the erasing times and the error correction times of the flash memory blocks in the solid state disk are obtained, the health value of each flash memory block can be calculated by utilizing the erasing times and the error correction times of each flash memory block; for example, the number of erasures and the number of error corrections may be added/multiplied to obtain a health value; or mapping the erasing times and the error correction times into corresponding erasing times health values and error correction digit health values, and then adding/multiplying the erasing times health values and the error correction digit health values to obtain health values; it will be appreciated that the health value of the flash block may also be calculated in other reasonable ways, provided that the health of the flash block can be characterized.
Step 13: and selecting a target flash memory block matched with the data to be written based on the health values of all the idle flash memory blocks, and writing the data to be written into the target flash memory block.
After the health value of the flash memory block is calculated, the data to be written can be stored in the appropriate flash memory block in the solid state disk; specifically, the target flash memory block is a flash memory block in which other data is not stored, and the idle flash memory block with the highest health value in all idle flash memory blocks can be used as the target flash memory block, that is, the data to be written is stored in the idle flash memory block with the highest health value in all idle flash memory blocks, or the idle flash memory block with the health value greater than a certain set value is used as the target flash memory block, and then the data to be written is randomly stored in one of the target flash memory blocks; or the destination flash block may also be selected based on the properties of the data to be written, e.g., size or frequency of access.
The application provides a method for improving data storage safety, which can acquire health information of each flash memory block in a solid state disk, process error correction digits and erasing times in the health information, estimate the health condition of each flash memory block, select a target flash memory block matched with current data to be written from all idle flash memory blocks, store the data to be written into the target flash memory block, realize data storage, more accurately estimate the health condition of each flash memory block, reasonably use all flash memory blocks, enable the health condition of each flash memory block to be more uniform, prevent that some flash memory blocks are bad due to repeated use and the health condition of some flash memory blocks is good due to non-use, improve the service life of the solid state disk, and ensure the safety of data storage.
Referring to fig. 2, fig. 2 is a schematic flowchart illustrating another embodiment of a method for improving data security of a solid state disk according to the present application, where the method includes:
step 21: and acquiring the erasing times and the error correction bits of each flash memory block.
When erasing the data in the flash memory block, recording and counting the number of times of erasing each flash memory block; the number of bits that the data in the flash block is corrected may also be obtained when reading the data in the flash block.
Step 22: and calculating the erase frequency health value of the flash memory block based on the erase frequency of each flash memory block and a preset erase frequency limit.
Judging whether the erasing times of each flash memory block are larger than a preset erasing time limit or not, wherein the erasing times of the flash memory blocks are the times of erasing the flash memory blocks till now; if the erasing times of the flash memory block are larger than the preset erasing times limit, the erasing times health value of the flash memory block is a first preset value; and if the erasing times of the flash memory block are less than or equal to the preset erasing times limit, the erasing times health value of the flash memory block is a second preset value (the preset erasing times limit-the erasing times of the flash memory block)/a preset erasing times limit.
In a specific embodiment, the first preset value may be 0, the second preset value may be 100, and the health value of the erase times of the flash memory block may be calculated by using the following formula:
Figure BDA0002685503580000051
wherein HpeFor erase count health value, PEcurrentFor the number of times of erasing of a flash block, PEmaxThe erase time limit is preset by the user based on experience.
According to the formula, if the erasing times of the flash memory block are higher than the preset erasing times limit, the flash memory block reaches the preset service life, and if data are continuously written, the risk of data loss exists, and the health value is 0; and if the erasing times of the flash memory block are not higher than the preset erasing time limit, the larger the erasing times of the current flash memory block is, the smaller the erasing time health value corresponding to the flash memory block is.
Step 23: and calculating the error correction digit health value of the flash memory block based on the maximum error correction digit, the preset error correction digit threshold value and the preset error correction digit limit of each flash memory block.
Judging whether the maximum error correction frequency of each flash memory block is smaller than a preset error correction bit number threshold value or not, wherein the maximum error correction bit number of the flash memory block is the maximum error correction frequency corresponding to the flash memory block at present; if the maximum error correction times of the flash memory block is smaller than a preset error correction bit number threshold value, the error correction times health value of the flash memory block is a third preset value; if the maximum error correction times of the flash memory block is greater than or equal to the preset error correction digit threshold value, the error correction times health value of the flash memory block is a second preset value (preset error correction digit limit-maximum error correction times of the flash memory block)/(preset error correction digit limit-preset error correction digit threshold value).
In a specific embodiment, the third preset value may be 100, and the health value of the error correction bit of the flash memory block may be calculated by using the following formula:
Figure BDA0002685503580000052
wherein HldpcFor error correcting the health value of the bit, BcurrentMaximum number of error correction bits of flash memory block, BmaxThe error correction bit number limit is preset by a user according to experience.
As can be seen from the above formula, if the maximum error correction bit number of the flash memory block is lower than the preset error correction bit number threshold, the flash memory block is completely healthy, and the health value is 100; if the maximum error correction digit of the flash memory block is not lower than the preset error correction digit threshold value, the larger the maximum error correction digit of the current flash memory block is, the higher the probability of the error of the flash memory block is, and the smaller the health value of the error correction digit corresponding to the flash memory block is.
Step 24: and carrying out weighted summation on the erasing times health value and the error correction digit health value of each flash memory block to obtain the health value of the flash memory block.
The health value of a flash block can be calculated using the following formula:
H=θ*Hldpc+(1-θ)*Hpe
wherein, H is the health value of the flash memory block, and theta is the weight proportion, and can be set by the user according to the experience value.
Step 25: and judging whether the data to be written is hot data or not.
The health value of the flash memory block can be applied to write operation, in order to more reasonably use the flash memory block, a target flash memory block can be selected according to the access frequency of data to be written, namely, whether the data to be written is hot data or cold data is judged, the hot data is relative to the cold data, namely, compared with the cold data, the write frequency of the hot data is higher, a write frequency threshold value can be set, if the write frequency of the data to be written is greater than the write frequency threshold value, the data to be written is the hot data, otherwise, the data to be written is the cold data, for example, the cold data can be data of a garbage recovery source data block.
Step 26: and if the data to be written is hot data, selecting an idle flash memory block with the maximum health value from all the idle flash memory blocks to store the data to be written.
When the data to be written is hot data, the data is frequently accessed, so that the requirement on the health value of the flash memory blocks is high, and at the moment, the idle flash memory block with the highest health value can be selected from all the idle flash memory blocks to store the data to be written.
Step 27: and if the data to be written is cold data, selecting one idle flash memory block from all the idle flash memory blocks based on a preset health threshold value to store the data to be written.
When it is determined that the data to be written is cold data, because the access frequency of the data is not high, the step shown in fig. 3 may be adopted to select the destination flash memory block, which specifically includes:
step 271: and sequencing all the idle flash memory blocks according to the sequence of the health values from small to large to obtain an idle flash memory sequence.
In order to select the most suitable idle flash memory blocks to store cold data, all the idle flash memory blocks can be sorted firstly to generate an idle flash memory sequence with health values arranged from small to large; for example, the free flash memory sequence is { F3, F2, F1, F4, F5}, and the corresponding health values are {50, 60, 70, 87, 90 }; the destination flash block may then be selected based on the free flash sequence and the preset health threshold, as shown in steps 272-277.
Step 272: and traversing the idle flash memory sequence, and taking the first idle flash memory block in the idle flash memory sequence as the current idle flash memory block.
The first idle flash block may be taken out of the idle flash sequence, and the first idle flash block is used as the current idle flash block, and whether the traversal is finished or not is determined by comparing the health value of the current idle flash block with a preset health threshold, which will be described in detail below.
Step 273: and judging whether the health value of the current idle flash memory block is smaller than a preset health threshold value.
The preset health threshold may be an empirically set range of health values that enable secure storage.
Step 274: and if the health value of the current idle flash memory block is greater than or equal to the preset health threshold value, taking the current idle flash memory block as a target flash memory block.
When the health value of the current idle flash memory block is greater than or equal to a preset health threshold value, the health value of the idle flash memory block is indicated to meet the requirement and is suitable for being used for storing data to be written; if the health value of the current idle flash memory block is smaller than the preset health threshold value, it is indicated that the health value of the flash memory block is too low, potential safety hazards exist when data to be written is written into the idle flash memory block, at this time, the data to be written can be stored based on whether other idle flash memory blocks exist in the solid state disk, and steps 275 to 276 can be specifically executed.
Step 275: and judging whether other idle flash memory blocks exist in the solid state disk.
When the health value of the current idle flash memory block is smaller than the preset health threshold value, whether other idle flash memory blocks except the current idle flash memory block exist in the idle flash memory sequence can be judged so as to select a proper idle flash memory block.
Step 276: and if other free flash memory blocks exist, selecting the next free flash memory block from the free flash memory sequence as the current free flash memory block.
If there are other free flash blocks, the next free flash block from the free flash sequence can be selected as the current free flash block, and then the process returns to step 273; if there are no free flash blocks other than the current free flash block, this indicates that there are no optional free flash blocks, and step 274 may be performed with the current free flash block as the destination flash block.
In summary, when the written data is cold data, the idle flash memory blocks with relatively low health values need to be selected, all the idle flash memory blocks may be sorted according to the sequence of health values from small to large, then the idle flash memory block with the minimum health value is selected as the current idle flash memory block, and if the health value of the current idle flash memory block is greater than the preset health threshold, the current idle flash memory block is selected as the target flash memory block; if the health value of the current idle flash memory block is lower than a preset health threshold value, inquiring whether the health value of the next idle flash memory block meets the condition, if not, continuing to traverse, and if all the traverse is finished and the idle flash memory block with the health value larger than the preset health threshold value is not found, selecting the last idle flash memory block as a target flash memory block; the safety of data storage can be ensured, and meanwhile, each flash memory block can reach the service life more evenly.
In the embodiment, the health value of the flash memory block can be estimated according to the error correction bit number and the erasing times of the flash memory block, when data is written into the solid state disk, if the data to be written is cold data, an idle flash memory block with a lower health value is selected, and a threshold value can be set, and the idle flash memory block lower than the threshold value is not used temporarily; if the data to be written is hot data, the idle flash memory blocks with higher health values are selected, the use of each flash memory block is relatively average, the health values are approximately the same, and the data safety and the service life of the solid state disk can be improved.
Referring to fig. 4, fig. 4 is a schematic structural diagram of an embodiment of the apparatus for improving data security of a solid state disk provided in the present application, where the apparatus 40 for improving data security includes a memory 41 and a processor 42 that are connected to each other, the memory 41 is used for storing a computer program, and the computer program is used for implementing the method for improving data security of a solid state disk in the foregoing embodiment when being executed by the processor 42.
Referring to fig. 5, fig. 5 is a schematic structural diagram of an embodiment of a computer-readable storage medium provided in the present application, where the computer-readable storage medium 50 is used to store a computer program 51, and when the computer program 51 is executed by a processor, the computer program is used to implement the method for improving the data security of the solid state disk in the foregoing embodiments.
The computer readable storage medium 50 may be a server, a usb disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and various media capable of storing program codes.
In the several embodiments provided in the present application, it should be understood that the disclosed method and apparatus may be implemented in other manners. For example, the above-described apparatus embodiments are merely illustrative, and for example, a division of modules or units is merely a logical division, and an actual implementation may have another division, for example, a plurality of units or components may be combined or integrated into another system, or some features may be omitted, or not executed.
Units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the embodiment.
In addition, functional units in the embodiments of the present application may be integrated into one processing unit, or each unit may exist alone physically, or two or more units may be integrated into one unit. The integrated unit can be realized in a form of hardware, and can also be realized in a form of a software functional unit.
The above description is only an example of the present application and is not intended to limit the scope of the present application, and all modifications of equivalent structures and equivalent processes, which are made by the contents of the specification and the drawings, or which are directly or indirectly applied to other related technical fields, are intended to be included within the scope of the present application.

Claims (10)

1. A method for improving data security of a solid state disk is characterized by comprising the following steps:
acquiring health information of each flash memory block in the solid state disk, wherein the health information comprises erasing times and error correction bits;
calculating the health value of each flash memory block by using the erasing times and the error correction bits of each flash memory block;
and selecting a target flash memory block matched with the data to be written based on the health values of all the idle flash memory blocks, and writing the data to be written into the target flash memory block.
2. The method for improving data security of the solid state disk according to claim 1, further comprising:
acquiring the erasing times and error correction bits of each flash memory block;
calculating the erase frequency health value of each flash memory block based on the erase frequency of each flash memory block and a preset erase frequency limit;
calculating the error correction digit health value of each flash memory block based on the maximum error correction digit, a preset error correction digit threshold value and a preset error correction digit limit of each flash memory block;
and carrying out weighted summation on the erasing times health value and the error correction digit health value of each flash memory block to obtain the health value of the flash memory block.
3. The method for improving data security of the solid state disk according to claim 2, wherein the step of calculating the healthy value of the number of times of erasure of the flash memory block based on the number of times of erasure of each flash memory block and a preset number of times of erasure limit comprises:
judging whether the erasing times of each flash memory block are larger than the preset erasing time limit or not;
if so, the healthy value of the erasing times of the flash memory block is a first preset value;
if not, the erase time health value of the flash memory block is a second preset value (the preset erase time limit-the erase time of the flash memory block)/the preset erase time limit.
4. The method for improving data security of a solid state disk according to claim 2, wherein the step of calculating the health value of the error correction bits of the flash memory blocks based on the maximum error correction bits of each flash memory block, a preset threshold value of the error correction bits and a preset limit of the error correction bits comprises:
judging whether the maximum error correction times of each flash memory block is smaller than the preset error correction bit number threshold value or not;
if so, the error correction frequency health value of the flash memory block is a third preset value;
if not, the error correction time health value of the flash memory block is a second preset value (the preset error correction bit number limit-the maximum error correction time of the flash memory block)/(the preset error correction bit number limit-the preset error correction bit number threshold).
5. The method for improving the data security of the solid state disk according to claim 1, wherein the step of selecting a destination flash memory block matching the data to be written based on the health values of all free flash memory blocks, and writing the data to be written into the destination flash memory block comprises:
judging whether the data to be written is hot data or not;
if the data to be written is the hot data, selecting an idle flash memory block with the maximum health value from all the idle flash memory blocks to store the data to be written;
and if the data to be written is cold data, selecting one idle flash memory block from all the idle flash memory blocks based on a preset health threshold value to store the data to be written.
6. The method for improving data security of the solid state disk according to claim 5, wherein the step of selecting one free flash memory block from all the free flash memory blocks based on a preset health threshold to store the data to be written comprises:
sequencing all the idle flash memory blocks according to the sequence of the health values from small to large to obtain an idle flash memory sequence;
and selecting the target flash memory block based on the idle flash memory sequence and the preset health threshold value.
7. The method according to claim 6, wherein the step of selecting the target flash block based on the free flash sequence and the preset health threshold includes:
traversing the idle flash memory sequence, and taking a first idle flash memory block in the idle flash memory sequence as a current idle flash memory block;
judging whether the health value of the current idle flash memory block is smaller than the preset health threshold value or not;
if the health value of the current idle flash memory block is larger than or equal to the preset health threshold value, taking the current idle flash memory block as the target flash memory block;
and if the health value of the current idle flash memory block is smaller than the preset health threshold value, storing the data to be written based on whether other idle flash memory blocks exist in the solid state disk.
8. The method for improving data security of the solid state disk according to claim 7, wherein the step of storing the data to be written based on whether there are other free flash memory blocks in the solid state disk comprises:
judging whether the solid state disk has other idle flash memory blocks or not;
if the other idle flash memory blocks exist, selecting the next idle flash memory block from the idle flash memory sequence as the current idle flash memory block, and returning to the step of judging whether the health value of the current idle flash memory block is smaller than the preset health threshold value;
and if the other free flash memory blocks are not available, taking the current free flash memory block as the target flash memory block.
9. An apparatus for improving data security, comprising a memory and a processor connected to each other, wherein the memory is used for storing a computer program, and the computer program is used for implementing the method for improving data security of a solid state disk according to any one of claims 1 to 8 when being executed by the processor.
10. A computer-readable storage medium for storing a computer program, wherein the computer program is configured to implement the method for improving data security of a solid state disk according to any one of claims 1 to 8 when the computer program is executed by a processor.
CN202010975185.3A 2020-09-16 2020-09-16 Method, device and storage medium for improving data security of solid state disk Pending CN112256193A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010975185.3A CN112256193A (en) 2020-09-16 2020-09-16 Method, device and storage medium for improving data security of solid state disk

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010975185.3A CN112256193A (en) 2020-09-16 2020-09-16 Method, device and storage medium for improving data security of solid state disk

Publications (1)

Publication Number Publication Date
CN112256193A true CN112256193A (en) 2021-01-22

Family

ID=74231774

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010975185.3A Pending CN112256193A (en) 2020-09-16 2020-09-16 Method, device and storage medium for improving data security of solid state disk

Country Status (1)

Country Link
CN (1) CN112256193A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113362879A (en) * 2021-04-19 2021-09-07 浙江大华存储科技有限公司 Method and device for predicting service life of solid state disk and readable storage medium
CN114489504A (en) * 2022-01-21 2022-05-13 苏州浪潮智能科技有限公司 SSD data management method and related components
WO2024055612A1 (en) * 2022-09-13 2024-03-21 深圳市硅格半导体有限公司 Data storage method and apparatus for flash memory, and terminal device and storage medium

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20160170682A1 (en) * 2014-12-16 2016-06-16 Sandisk Technologies Inc. Tag-based wear leveling for a data storage device
US20160188231A1 (en) * 2014-12-30 2016-06-30 International Business Machines Corporation Adapting erase cycle parameters to promote endurance of a memory
CN107391035A (en) * 2017-07-11 2017-11-24 华中科技大学 It is a kind of that the method for reducing solid-state mill damage is perceived by misprogrammed
CN109524046A (en) * 2018-09-05 2019-03-26 广东工业大学 A kind of flash memory abrasion equalization algorithm of low memory consumption
CN109542667A (en) * 2018-10-26 2019-03-29 珠海妙存科技有限公司 A kind of method and device improving nand flash memory data reliability
CN111078123A (en) * 2018-10-19 2020-04-28 浙江宇视科技有限公司 Method and device for evaluating wear degree of flash memory block

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20160170682A1 (en) * 2014-12-16 2016-06-16 Sandisk Technologies Inc. Tag-based wear leveling for a data storage device
US20160188231A1 (en) * 2014-12-30 2016-06-30 International Business Machines Corporation Adapting erase cycle parameters to promote endurance of a memory
CN107391035A (en) * 2017-07-11 2017-11-24 华中科技大学 It is a kind of that the method for reducing solid-state mill damage is perceived by misprogrammed
CN109524046A (en) * 2018-09-05 2019-03-26 广东工业大学 A kind of flash memory abrasion equalization algorithm of low memory consumption
CN111078123A (en) * 2018-10-19 2020-04-28 浙江宇视科技有限公司 Method and device for evaluating wear degree of flash memory block
CN109542667A (en) * 2018-10-26 2019-03-29 珠海妙存科技有限公司 A kind of method and device improving nand flash memory data reliability

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113362879A (en) * 2021-04-19 2021-09-07 浙江大华存储科技有限公司 Method and device for predicting service life of solid state disk and readable storage medium
CN113362879B (en) * 2021-04-19 2022-08-09 浙江大华存储科技有限公司 Method and device for predicting service life of solid state disk and readable storage medium
CN114489504A (en) * 2022-01-21 2022-05-13 苏州浪潮智能科技有限公司 SSD data management method and related components
CN114489504B (en) * 2022-01-21 2023-08-08 苏州浪潮智能科技有限公司 SSD data management method and related components
WO2024055612A1 (en) * 2022-09-13 2024-03-21 深圳市硅格半导体有限公司 Data storage method and apparatus for flash memory, and terminal device and storage medium

Similar Documents

Publication Publication Date Title
CN108269604B (en) Method and apparatus for read disturb detection and processing
CN112256193A (en) Method, device and storage medium for improving data security of solid state disk
JP5658128B2 (en) System, method, and computer program for probabilistic multilayer error correction in NAND flash memory
US8010876B2 (en) Method of facilitating reliable access of flash memory
US8756464B2 (en) Flash memory device and flash memory programming method equalizing wear-level
US8429501B2 (en) Memory storage device, memory controller thereof, and method thereof for generating log likelihood ratio
US8694715B2 (en) Methods for adaptively programming flash memory devices and flash memory systems incorporating same
US20110258495A1 (en) Methods of calculating compensation voltage and adjusting threshold voltage and memory apparatus and controller
US20150365106A1 (en) Deterministic read retry method for soft ldpc decoding in flash memories
US11210163B2 (en) Memory system and control method
US20140026003A1 (en) Flash memory read error rate reduction
US20130290612A1 (en) Soft information module
CN107748722B (en) Self-adaptive data refreshing method for ensuring data persistence in solid state disk
US20090024787A1 (en) Data writing method and apparatus
JP2010079486A (en) Semiconductor recording device
US10324648B1 (en) Wear-based access optimization
US9021340B2 (en) Error recovery using erasures for NAND Flash
US20210067178A1 (en) Method for selectively inverting words to be written to a memory and device for implementing same
TWI594253B (en) Non-volatile memory apparatus and empty page detection method thereof
CN106847342B (en) Nonvolatile memory device and empty page detection method thereof
CN107705817B (en) Decoding method and device using flash memory channel characteristics and data storage system
JP2010108029A (en) Nonvolatile memory controller, non-volatile storage device, and non-volatile storage system
CN113035265B (en) Bad block screening method and device, readable storage medium and electronic equipment
US20220165336A1 (en) Systems for adaptively determining read threshold voltage using meta information
KR100697792B1 (en) Storage medium reproducing apparatus, storage medium reproducing method, and computer readable medium for reading information from storage medium

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
CB02 Change of applicant information
CB02 Change of applicant information

Address after: Room 1202, Floor 12, Building 3, No. 126, Yueda Lane, Changhe Street, Binjiang District, Hangzhou City, Zhejiang Province, 310056

Applicant after: Zhejiang Huayi Core Technology Co.,Ltd.

Address before: 310051 room 512, building 2, 2930 South Ring Road, Puyan street, Binjiang District, Hangzhou City, Zhejiang Province

Applicant before: Zhejiang Dahua Technology Co.,Ltd.

RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20210122