CN114138193A - Data writing method, device and equipment for solid state disk with partitioned name space - Google Patents

Data writing method, device and equipment for solid state disk with partitioned name space Download PDF

Info

Publication number
CN114138193A
CN114138193A CN202111415464.5A CN202111415464A CN114138193A CN 114138193 A CN114138193 A CN 114138193A CN 202111415464 A CN202111415464 A CN 202111415464A CN 114138193 A CN114138193 A CN 114138193A
Authority
CN
China
Prior art keywords
writing
target
partition
namespace
data
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.)
Granted
Application number
CN202111415464.5A
Other languages
Chinese (zh)
Other versions
CN114138193B (en
Inventor
秦文政
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Zhengzhou Yunhai Information Technology Co Ltd
Original Assignee
Zhengzhou Yunhai Information Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Zhengzhou Yunhai Information Technology Co Ltd filed Critical Zhengzhou Yunhai Information Technology Co Ltd
Priority to CN202111415464.5A priority Critical patent/CN114138193B/en
Publication of CN114138193A publication Critical patent/CN114138193A/en
Application granted granted Critical
Publication of CN114138193B publication Critical patent/CN114138193B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0628Interfaces specially adapted for storage systems making use of a particular technique
    • G06F3/0638Organizing or formatting or addressing of data
    • G06F3/0644Management of space entities, e.g. partitions, extents, pools
    • 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/0626Reducing size or complexity of storage systems
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0668Interfaces specially adapted for storage systems adopting a particular infrastructure
    • G06F3/0671In-line storage system
    • G06F3/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)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The invention discloses a data writing method of a partition name space solid state disk, which comprises the following steps: receiving target data to be written; acquiring target attribute information corresponding to target data; selecting a target writing name space corresponding to the target attribute information from the sequential writing name space and the random writing name space; the sequential writing of the name space and the random writing of the name space are obtained by dividing the solid state disk of the partition name space; target data is written to the target write namespace. By applying the data writing method of the partition name space solid state disk provided by the invention, the adaptation difficulty of part of service scenes is reduced, and the usability of the partition name space solid state disk is greatly improved. The invention also discloses a data writing device, equipment and a storage medium of the partitioned name space solid state disk, and the device, the equipment and the storage medium have corresponding technical effects.

Description

Data writing method, device and equipment for solid state disk with partitioned name space
Technical Field
The present invention relates to the field of storage technologies, and in particular, to a data writing method, apparatus, device, and computer-readable storage medium for a partitioned namespace solid state disk.
Background
A partitioned Namespace Solid State Disk (ZNS SSD), as a novel nvme (nvm express) SSD, has been adapted and applied by various internet vendors with efficient protocol interaction and good performance. The most important advantage of the partition namespace solid state disk is that an interaction protocol with upper-layer application is standardized, the solid state disk is divided into partitions, partition information is opened to the upper-layer application, the application combines own service to store the partitions, service data with the same life cycle are written into the same partition, and meanwhile, an end-to-end fusion garbage recycling strategy is matched, so that high performance and low cost of a storage system are achieved.
The advantage of matching the solid state disk with the storage system in the partition naming space is obvious, but the biggest difference between the solid state disk and the traditional solid state disk is that data writing requires sequential writing inside the partition, and under a specific user scene, all data writing actions are converted into sequential writing, so that great difficulty is caused, and great resistance is brought to popularization of the solid state disk in the partition naming space.
In summary, how to effectively solve the problems that all data writing actions are converted into sequential writing, which causes great difficulty, and great resistance is brought to the popularization of a partition namespace solid state disk, is a problem that needs to be solved urgently by those skilled in the art at present.
Disclosure of Invention
The invention aims to provide a data writing method of a partition namespace solid state disk, which reduces the adaptation difficulty of part of service scenes and greatly improves the usability of the partition namespace solid state disk; another object of the present invention is to provide a data writing apparatus, device and computer readable storage medium for partitioned namespace solid state disk.
In order to solve the technical problems, the invention provides the following technical scheme:
a data writing method of a partition name space solid state disk comprises the following steps:
receiving target data to be written;
acquiring target attribute information corresponding to the target data;
selecting a target writing name space corresponding to the target attribute information from a sequential writing name space and a random writing name space; the sequential writing naming space and the random writing naming space are obtained by dividing the solid state disk of the partition naming space;
and writing the target data into the target writing namespace.
In a specific embodiment of the present invention, when the target writing namespace is the random writing namespace, after writing the target data into the target writing namespace, the method further includes:
acquiring a target physical address and a target logical address of the target data written in the target writing name space;
and correspondingly storing the target physical address and the target logical address into a preset mapping table.
In a specific embodiment of the present invention, storing the target physical address and the target logical address into a preset mapping table correspondingly includes:
determining a random metadata area corresponding to the random writing name space;
and correspondingly storing the target physical address and the target logical address into a preset mapping table of the random metadata area.
In one embodiment of the present invention, the method further comprises:
and when detecting that a target partition with the space usage exceeding a preset value exists in the sequential writing namespace and/or the random writing namespace, performing garbage collection operation on the target partition.
In a specific embodiment of the present invention, performing a garbage collection operation on the target partition includes:
judging whether the target partition has random partition mark information or not;
and if so, searching the target partition from the random writing name space, and performing garbage collection operation on the target partition.
In one embodiment of the present invention, the method further comprises:
and respectively carrying out wear times counting operation on each sequential partition in the sequential writing name space and each random partition in the random writing name space.
In a specific embodiment of the present invention, after performing the wear count counting operation on each sequential partition in the sequential writing namespace and each random partition in the random writing namespace, the method further includes:
judging whether a sequence partition and/or a random partition with the abrasion times exceeding a preset time threshold exists or not;
and if so, acquiring an idle partition from the preset partition pool, and moving the data in the partition with the determined wear frequency exceeding a preset frequency threshold to the idle partition.
A data writing device of a partition name space solid state disk comprises:
the data receiving module is used for receiving target data to be written;
the attribute information acquisition module is used for acquiring target attribute information corresponding to the target data;
the name space selecting module is used for selecting a target writing name space corresponding to the target attribute information from a sequential writing name space and a random writing name space; the sequential writing naming space and the random writing naming space are obtained by dividing the solid state disk of the partition naming space;
and the data writing module is used for writing the target data into the target writing namespace.
A data write device of a partition namespace solid state disk, comprising:
a memory for storing a computer program;
and the processor is used for realizing the steps of the data writing method of the partition name space solid state disk when executing the computer program.
A computer-readable storage medium, having stored thereon a computer program which, when being executed by a processor, carries out the steps of the method for writing data to a partitioned namespace solid state disk as set forth above.
The data writing method of the partition name space solid state disk provided by the invention comprises the steps of receiving target data to be written; acquiring target attribute information corresponding to target data; selecting a target writing name space corresponding to the target attribute information from the sequential writing name space and the random writing name space; the sequential writing of the name space and the random writing of the name space are obtained by dividing the solid state disk of the partition name space; target data is written to the target write namespace.
According to the technical scheme, the partition namespace solid state disk is divided into the sequential writing namespace and the random writing namespace in advance, when target data to be written are received, target attribute information corresponding to the target data is obtained, and the target writing namespace corresponding to the target attribute information is obtained from the sequential writing namespace and the random writing namespace. The invention can support random writing under the traditional scheme of the partition name space solid state disk, reduces the adaptation difficulty of partial service scenes, greatly improves the usability of the partition name space solid state disk, and improves the competitiveness of the partition name space solid state disk.
Correspondingly, the invention also provides a data writing device, equipment and a computer readable storage medium of the partition namespace solid state disk, which correspond to the data writing method of the partition namespace solid state disk, and the technical effects are achieved, and the description is omitted.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to the drawings without creative efforts.
FIG. 1 is a flowchart illustrating an implementation of a data writing method for a partition namespace solid state disk according to an embodiment of the present invention;
FIG. 2 is a flowchart illustrating another embodiment of a method for writing data into a partition namespace solid state disk according to the present invention;
FIG. 3 is a block diagram illustrating a data writing apparatus of a partitioned namespace solid state disk according to an embodiment of the present invention;
fig. 4 is a block diagram of a data writing device of a partitioned namespace solid state disk in an embodiment of the present invention;
fig. 5 is a schematic structural diagram of a data writing device of a partitioned namespace solid state disk according to this embodiment.
Detailed Description
In order that those skilled in the art will better understand the disclosure, the invention will be described in further detail with reference to the accompanying drawings and specific embodiments. It is to be understood that the described embodiments are merely exemplary of the invention, and not restrictive of the full scope of the invention. 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 invention.
Referring to fig. 1, fig. 1 is a flowchart illustrating an implementation of a data writing method for a partition namespace solid state disk according to an embodiment of the present invention, where the method may include the following steps:
s101: target data to be written is received.
When data need to be written into the partition namespace solid state disk, target data to be written are sent to the data writing management center, and the data writing management center receives the target data to be written.
S102: and acquiring target attribute information corresponding to the target data.
And after the data writing management center receives the target data to be written, acquiring target attribute information corresponding to the target data. The target attribute information is attribute information for distinguishing whether the target data needs to be written into the naming space in sequence or written into the naming space at random, for example, a bank saving service in a personal account belongs to the naming space which needs to be written into at random, and a batch operation service in which a large amount of data needs to be backed up belongs to the naming space which needs to be written into in sequence.
S103: and selecting a target writing name space corresponding to the target attribute information from the sequential writing name space and the random writing name space.
The sequential writing of the name space and the random writing of the name space are obtained by dividing the solid state disk of the partition name space.
The method comprises the steps of dividing a partition namespace solid state disk into a sequential write namespace and a random write namespace in advance, and presenting the two write namespaces as two independent block devices. The namespace size that supports random writing supports hundreds of MB or even hundreds of GB, and the region size can be specified when creating the namespace. The sequential write namespace includes a plurality of sequential partitions (zones) and the random write namespace includes a plurality of random partitions. And after the target attribute information corresponding to the target data is acquired, selecting a target writing name space corresponding to the target attribute information from the sequential writing name space and the random writing name space.
S104: target data is written to the target write namespace.
And after the target writing name space corresponding to the target attribute information is selected from the sequential writing name space and the random writing name space, writing the target data into the target writing name space. The invention keeps the advantages of good end-to-end performance and low cost of the traditional scheme of the partition namespace solid state disk, simultaneously reduces the adaptation difficulty of storage software or client application software, and the application can keep the random writing of the main stream service converted into the sequential writing, but keeps the behavior similar to the random writing of the metadata stream, thereby greatly reducing the writing amplification of metadata writing and greatly improving the usability of the partition namespace solid state disk.
The invention provides a scheme capable of supporting random writing behaviors on the basis of the original scheme of a solid state disk of a partition name space, the random writing name space and the sequential writing name space mentioned in the scheme are not interfered with each other, all advantages of the scheme of the solid state disk of the partition name space are kept, the problem that all data in the scheme popularization need to be randomly changed into the sequence is solved, and the competitiveness of the solid state disk of the partition name space is greatly improved.
According to the technical scheme, the partition namespace solid state disk is divided into the sequential writing namespace and the random writing namespace in advance, when target data to be written are received, target attribute information corresponding to the target data is obtained, and the target writing namespace corresponding to the target attribute information is obtained from the sequential writing namespace and the random writing namespace. The invention can support random writing under the traditional scheme of the partition name space solid state disk, reduces the adaptation difficulty of partial service scenes, greatly improves the usability of the partition name space solid state disk, and improves the competitiveness of the partition name space solid state disk.
It should be noted that, based on the above embodiments, the embodiments of the present invention also provide corresponding improvements. In the following embodiments, steps that are the same as or correspond to those in the above embodiments may be referred to one another, and corresponding advantageous effects may also be referred to one another, which is not described in detail in the following modified embodiments.
Referring to fig. 2, fig. 2 is a flowchart of another implementation of a data writing method for a partition namespace solid state disk in an embodiment of the present invention, where the method may include the following steps:
s201: target data to be written is received.
S202: and acquiring target attribute information corresponding to the target data.
S203: and selecting a target writing name space corresponding to the target attribute information from the sequential writing name space and the random writing name space.
The sequential writing of the name space and the random writing of the name space are obtained by dividing the solid state disk of the partition name space.
S204: target data is written to the target write namespace.
S205: and when the target writing name space is the random writing name space, acquiring a target physical address and a target logical address of target data writing target writing name space.
The random write namespace supports random write, and a mapping table for maintaining logical addresses and physical addresses by taking 4KB user data as a unit is preset. And when the target writing name space is the random writing name space, acquiring a target physical address and a target logical address of target data writing target writing name space.
S206: and correspondingly storing the target physical address and the target logical address into a preset mapping table.
And after the target physical address and the target logical address of the target data written in the target writing name space are obtained, the target physical address and the target logical address are correspondingly stored in a preset mapping table. Therefore, when data query is needed at a later stage, corresponding data query operation can be performed according to the target physical address and the target logical address stored in the preset mapping table.
In one embodiment of the present invention, step S206 may include the following steps:
the method comprises the following steps: determining a random metadata area corresponding to a random writing name space;
step two: and correspondingly storing the target physical address and the target logical address into a preset mapping table of the random metadata area.
The above two steps may be combined for ease of description.
And aiming at SSD firmware (firmware), according to the sizes of two namespaces, namely a created sequential write namespace and a random write namespace, allocating corresponding metadata storage areas, wherein the random write namespace needs to be allocated according to one thousandth of the user capacity, and one partition of the sequential write namespace corresponds to one metadata area with the size of 4 bytes. After a target physical address and a target logical address of a target data writing target writing name space are obtained, a random metadata area corresponding to the random writing name space is determined, and the target physical address and the target logical address are correspondingly stored in a preset mapping table of the random metadata area.
S207: and when detecting that a target partition with the space usage amount exceeding a preset value exists in the sequential writing namespace and/or the random writing namespace, performing garbage collection operation on the target partition.
Whether a target partition with the space usage exceeding a preset value exists in a sequential writing namespace and/or a random writing namespace can be detected in real time or according to preset time intervals, when the target partition with the space usage exceeding the preset value exists in the sequential writing namespace and/or the random writing namespace is detected, namely when the partition with the space usage exceeding the preset value exists in the sequential writing namespace is determined, or when the partition with the space usage exceeding the preset value exists in the random writing namespace is determined, or when the partition with the space usage exceeding the preset value exists in the sequential writing namespace and the random writing namespace, the partition with the space usage exceeding the preset value is determined as the target partition, and garbage recycling operation is carried out on the target partition.
It should be noted that the preset value may be set and adjusted according to actual situations, for example, the preset value may be set and adjusted according to specific space capacities of the partitions, which is not limited in the embodiment of the present invention.
In an embodiment of the present invention, performing a garbage collection operation on a target partition may include the following steps:
the method comprises the following steps: judging whether random partition mark information exists in the target partition, if so, executing a second step, and if not, executing a third step;
step two: searching a target partition from the random writing name space, and performing garbage collection operation on the target partition;
step three: and searching the target partition from the sequential writing name space, and performing garbage collection operation on the target partition.
The above three steps may be combined for ease of description.
Setting a special mark as random partition mark information for a random partition corresponding to a random write-in naming space in advance, judging whether the random partition mark information exists in a target partition when performing garbage recovery operation on the target partition, if so, searching the target partition from the random write-in naming space, performing garbage recovery operation on the target partition, and if not, searching the target partition from a sequential write-in naming space, and performing garbage recovery operation on the target partition. The random partition in the random writing naming space is specially marked by setting the random partition mark information, so that the quick search of the partition to be written is facilitated.
S208: and respectively carrying out wear frequency counting operation on each sequential partition in the sequential writing name space and each random partition in the random writing name space.
And each partition in the sequentially written name space and the randomly written name space has abrasion life, all the partitions are managed in a unified way, and statistical information such as the abrasion times and the reading times of the partitions are maintained equally. And respectively carrying out wear frequency counting operation on each sequential partition in the sequential writing name space and each random partition in the random writing name space.
S209: and judging whether a sequence partition and/or a random partition with the abrasion times exceeding a preset time threshold exists, if so, executing the step S210, and if not, not processing.
After the wear frequency counting operation is performed on each sequential partition in the sequential writing namespace and each random partition in the random writing namespace, whether a sequential partition and/or a random partition with the wear frequency exceeding a preset frequency threshold exists or not is judged, that is, whether only a sequential partition with the wear frequency exceeding the preset frequency threshold exists or only a random partition with the wear frequency exceeding the preset frequency threshold exists or both a sequential partition with the wear frequency exceeding the preset frequency threshold and a random partition with the wear frequency exceeding the preset frequency threshold exist or not is judged, if yes, step S210 is executed, and if not, no processing is performed.
S210: and acquiring an idle partition from the preset partition pool, and moving the data in the partition with the determined wear times exceeding the preset time threshold to the idle partition.
The method comprises the steps that a partition pool comprising a plurality of partitions is preset, when it is determined that sequential partitions and/or random partitions with the wear times exceeding a preset time threshold exist, idle partitions are obtained from the preset partition pool, and data in the partitions with the wear times exceeding the preset time threshold are moved to the idle partitions. When the system detects that wear leveling needs to be triggered, a source partition can be selected globally, and related data moving actions are carried out according to the type of the partition (randomly writing the partition corresponding to the namespace or sequentially writing the partition corresponding to the namespace).
Corresponding to the above method embodiment, the present invention further provides a data writing device for a partition namespace solid state disk, where the data writing device for the partition namespace solid state disk described below and the data writing method for the partition namespace solid state disk described above may be referred to each other correspondingly.
Referring to fig. 3, fig. 3 is a block diagram of a data writing device of a partitioned namespace solid state disk according to an embodiment of the present invention, where the device may include:
a data receiving module 31, configured to receive target data to be written;
an attribute information obtaining module 32, configured to obtain target attribute information corresponding to the target data;
a namespace selecting module 33, configured to select a target write namespace corresponding to the target attribute information from the sequential write namespace and the random write namespace; the sequential writing of the name space and the random writing of the name space are obtained by dividing the solid state disk of the partition name space;
and a data writing module 34 for writing the target data into the target write namespace.
According to the technical scheme, the partition namespace solid state disk is divided into the sequential writing namespace and the random writing namespace in advance, when target data to be written are received, target attribute information corresponding to the target data is obtained, and the target writing namespace corresponding to the target attribute information is obtained from the sequential writing namespace and the random writing namespace. The invention can support random writing under the traditional scheme of the partition name space solid state disk, reduces the adaptation difficulty of partial service scenes, greatly improves the usability of the partition name space solid state disk, and improves the competitiveness of the partition name space solid state disk.
In one embodiment of the present invention, the apparatus may further include:
the address acquisition module is used for acquiring a target physical address and a target logical address of target data write-in target write-in naming space after target data are written in the target write-in naming space when the target write-in naming space is a random write-in naming space;
and the address storage module is used for correspondingly storing the target physical address and the target logical address into a preset mapping table.
In one embodiment of the present invention, the address storage module includes:
the metadata area determining submodule is used for determining a random metadata area corresponding to the random writing name space;
and the address storage submodule is used for correspondingly storing the target physical address and the target logical address into a preset mapping table of the random metadata area.
In one embodiment of the present invention, the apparatus may further include:
and the garbage recycling module is used for performing garbage recycling operation on the target partition when detecting that the target partition with the space usage amount exceeding a preset value exists in the sequential writing namespace and/or the random writing namespace.
In one embodiment of the present invention, the garbage collection module includes:
the judgment submodule is used for judging whether the target partition has random partition mark information or not;
and the garbage recycling submodule is used for searching the target partition from the random writing name space and performing garbage recycling operation on the target partition when the target partition is determined to have the random partition mark information.
In one embodiment of the present invention, the apparatus may further include:
and the wear frequency counting module is used for respectively carrying out wear frequency counting operation on each sequential partition in the sequential write-in naming space and each random partition in the random write-in naming space.
In one embodiment of the present invention, the apparatus may further include:
the judging module is used for judging whether the sequence partition and/or the random partition with the abrasion times exceeding a preset time threshold exists or not after the abrasion times counting operation is respectively carried out on each sequence partition in the sequence writing naming space and each random partition in the random writing naming space;
and the data moving module is used for acquiring the idle partition from the preset partition pool and moving the data in the partition with the wear frequency exceeding the preset frequency threshold to the idle partition when the sequential partition and/or the random partition with the wear frequency exceeding the preset frequency threshold are determined to exist.
Corresponding to the above method embodiment, referring to fig. 4, fig. 4 is a schematic diagram of a data writing device for a partition namespace solid state disk provided by the present invention, where the device may include:
a memory 332 for storing a computer program;
and a processor 322, configured to implement the steps of the data writing method for the partition namespace solid state disk of the foregoing method embodiments when executing the computer program.
Specifically, referring to fig. 5, fig. 5 is a schematic diagram illustrating a specific structure of a data writing device of a partition namespace solid state disk provided in this embodiment, the data writing device of the partition namespace solid state disk may generate a relatively large difference due to different configurations or performances, and may include a processor (CPU) 322 (for example, one or more processors) and a memory 332, where the memory 332 stores one or more computer applications 342 or data 344. Memory 332 may be, among other things, transient or persistent storage. The program stored in memory 332 may include one or more modules (not shown), each of which may include a sequence of instructions operating on a data processing device. Still further, processor 322 may be configured to communicate with memory 332 to execute a series of instruction operations in memory 332 on data writing device 301 of a partitioned namespace solid state disk.
The data writing apparatus 301 of the partitioned namespace solid state disk may also include one or more power supplies 326, one or more wired or wireless network interfaces 350, one or more input output interfaces 358, and/or one or more operating systems 341.
The steps in the data writing method for the partition namespace solid state disk described above may be implemented by the structure of the data writing device for the partition namespace solid state disk.
Corresponding to the above method embodiment, the present invention further provides a computer-readable storage medium having a computer program stored thereon, the computer program, when executed by a processor, implementing the steps of:
receiving target data to be written; acquiring target attribute information corresponding to target data; selecting a target writing name space corresponding to the target attribute information from the sequential writing name space and the random writing name space; the sequential writing of the name space and the random writing of the name space are obtained by dividing the solid state disk of the partition name space; target data is written to the target write namespace.
The computer-readable storage medium may include: various media capable of storing program codes, such as a usb disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk, or an optical disk.
For the introduction of the computer-readable storage medium provided by the present invention, please refer to the above method embodiments, which are not described herein again.
The embodiments are described in a progressive manner, each embodiment focuses on differences from other embodiments, and the same or similar parts among the embodiments are referred to each other. The device, the apparatus and the computer-readable storage medium disclosed in the embodiments correspond to the method disclosed in the embodiments, so that the description is simple, and the relevant points can be referred to the description of the method.
The principle and the implementation of the present invention are explained in the present application by using specific examples, and the above description of the embodiments is only used to help understanding the technical solution and the core idea of the present invention. It should be noted that, for those skilled in the art, it is possible to make various improvements and modifications to the present invention without departing from the principle of the present invention, and those improvements and modifications also fall within the scope of the claims of the present invention.

Claims (10)

1. A data writing method of a partition name space solid state disk is characterized by comprising the following steps:
receiving target data to be written;
acquiring target attribute information corresponding to the target data;
selecting a target writing name space corresponding to the target attribute information from a sequential writing name space and a random writing name space; the sequential writing naming space and the random writing naming space are obtained by dividing the solid state disk of the partition naming space;
and writing the target data into the target writing namespace.
2. The method according to claim 1, wherein when the target write namespace is the random write namespace, after writing the target data into the target write namespace, the method further comprises:
acquiring a target physical address and a target logical address of the target data written in the target writing name space;
and correspondingly storing the target physical address and the target logical address into a preset mapping table.
3. The method for writing data in the partition namespace solid state disk according to claim 2, wherein the storing the target physical address and the target logical address into a preset mapping table correspondingly comprises:
determining a random metadata area corresponding to the random writing name space;
and correspondingly storing the target physical address and the target logical address into a preset mapping table of the random metadata area.
4. The data writing method of the partition namespace solid state disk according to claim 1, further comprising:
and when detecting that a target partition with the space usage exceeding a preset value exists in the sequential writing namespace and/or the random writing namespace, performing garbage collection operation on the target partition.
5. The method for writing data into the partition namespace solid state disk according to claim 4, wherein performing garbage collection operation on the target partition comprises:
judging whether the target partition has random partition mark information or not;
and if so, searching the target partition from the random writing name space, and performing garbage collection operation on the target partition.
6. The data writing method of the partition namespace solid state disk according to claim 1, further comprising:
and respectively carrying out wear times counting operation on each sequential partition in the sequential writing name space and each random partition in the random writing name space.
7. The method for writing data in the partition namespace solid state disk according to claim 6, further comprising, after performing the wear count statistics operation on each sequential partition in the sequential write namespace and each random partition in the random write namespace, respectively:
judging whether a sequence partition and/or a random partition with the abrasion times exceeding a preset time threshold exists or not;
and if so, acquiring an idle partition from the preset partition pool, and moving the data in the partition with the determined wear frequency exceeding a preset frequency threshold to the idle partition.
8. The utility model provides a data write device of partition name space solid state hard drives which characterized in that includes:
the data receiving module is used for receiving target data to be written;
the attribute information acquisition module is used for acquiring target attribute information corresponding to the target data;
the name space selecting module is used for selecting a target writing name space corresponding to the target attribute information from a sequential writing name space and a random writing name space; the sequential writing naming space and the random writing naming space are obtained by dividing the solid state disk of the partition naming space;
and the data writing module is used for writing the target data into the target writing namespace.
9. A data write device of a partitioned name space solid state disk is characterized by comprising:
a memory for storing a computer program;
a processor for implementing the steps of the data writing method of the partitioned namespace solid state disk of any of claims 1 to 7 when executing said computer program.
10. A computer-readable storage medium, having stored thereon a computer program which, when being executed by a processor, carries out the steps of the method for writing data to a partitioned namespace solid state disk according to any of claims 1 to 7.
CN202111415464.5A 2021-11-25 2021-11-25 Data writing method, device and equipment for partition naming space solid state disk Active CN114138193B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111415464.5A CN114138193B (en) 2021-11-25 2021-11-25 Data writing method, device and equipment for partition naming space solid state disk

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111415464.5A CN114138193B (en) 2021-11-25 2021-11-25 Data writing method, device and equipment for partition naming space solid state disk

Publications (2)

Publication Number Publication Date
CN114138193A true CN114138193A (en) 2022-03-04
CN114138193B CN114138193B (en) 2024-03-26

Family

ID=80392124

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111415464.5A Active CN114138193B (en) 2021-11-25 2021-11-25 Data writing method, device and equipment for partition naming space solid state disk

Country Status (1)

Country Link
CN (1) CN114138193B (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114546295A (en) * 2022-04-25 2022-05-27 武汉麓谷科技有限公司 Intelligent write allocation method and device based on ZNS solid state disk
CN115543224A (en) * 2022-11-30 2022-12-30 苏州浪潮智能科技有限公司 ZNS SSD-based file system control method, device and equipment
CN117056245A (en) * 2023-08-18 2023-11-14 武汉麓谷科技有限公司 Data organization method for log record application based on ZNS solid state disk
CN117193650A (en) * 2023-09-13 2023-12-08 东莞市奇海实业有限公司 Solid state disk management method, device, equipment and medium based on large file

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112148226A (en) * 2020-09-25 2020-12-29 腾讯科技(深圳)有限公司 Data storage method and related device
CN112684979A (en) * 2020-12-24 2021-04-20 北京浪潮数据技术有限公司 Use method, system, equipment and storage medium of solid state disk
US20210132827A1 (en) * 2019-11-05 2021-05-06 Western Digital Technologies, Inc. Applying Endurance Groups To Zoned Namespaces
CN113179658A (en) * 2019-09-12 2021-07-27 西部数据技术公司 Non-sequential partition namespaces

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113179658A (en) * 2019-09-12 2021-07-27 西部数据技术公司 Non-sequential partition namespaces
US20210132827A1 (en) * 2019-11-05 2021-05-06 Western Digital Technologies, Inc. Applying Endurance Groups To Zoned Namespaces
CN112783425A (en) * 2019-11-05 2021-05-11 西部数据技术公司 Applying durability groups to partitioned namespaces
CN112148226A (en) * 2020-09-25 2020-12-29 腾讯科技(深圳)有限公司 Data storage method and related device
CN112684979A (en) * 2020-12-24 2021-04-20 北京浪潮数据技术有限公司 Use method, system, equipment and storage medium of solid state disk

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
环球网: "浪潮新一代ZNS SSD固态盘解码", Retrieved from the Internet <URL:https://www.360kuai.com/pc/9d8ae3d026fafb919?cota=3&kuai_so=1&tj_url=so_vip&sign=360_57c3bbd1&refer_scene=so_1> *

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114546295A (en) * 2022-04-25 2022-05-27 武汉麓谷科技有限公司 Intelligent write allocation method and device based on ZNS solid state disk
CN114546295B (en) * 2022-04-25 2022-07-01 武汉麓谷科技有限公司 Intelligent writing distribution method and device based on ZNS solid state disk
CN115543224A (en) * 2022-11-30 2022-12-30 苏州浪潮智能科技有限公司 ZNS SSD-based file system control method, device and equipment
CN117056245A (en) * 2023-08-18 2023-11-14 武汉麓谷科技有限公司 Data organization method for log record application based on ZNS solid state disk
CN117056245B (en) * 2023-08-18 2024-02-23 武汉麓谷科技有限公司 Data organization method for log record application based on ZNS solid state disk
CN117193650A (en) * 2023-09-13 2023-12-08 东莞市奇海实业有限公司 Solid state disk management method, device, equipment and medium based on large file
CN117193650B (en) * 2023-09-13 2024-04-05 东莞市奇海实业有限公司 Solid state disk management method, device, equipment and medium based on large file

Also Published As

Publication number Publication date
CN114138193B (en) 2024-03-26

Similar Documents

Publication Publication Date Title
CN114138193B (en) Data writing method, device and equipment for partition naming space solid state disk
CN102436420B (en) The lasting key assignments of the low ram space of supplementary storage, high-throughput is used to store
CN106874348B (en) File storage and index method and device and file reading method
CN103336849B (en) A kind of database retrieval system improves the method and device of retrieval rate
WO2017107414A1 (en) File operation method and device
CN101777061B (en) JAVA card object management method and JAVA card
CN103995855A (en) Method and device for storing data
CN105468642A (en) Data storage method and apparatus
KR20200122994A (en) Key Value Append
CN114546295B (en) Intelligent writing distribution method and device based on ZNS solid state disk
US8296270B2 (en) Adaptive logging apparatus and method
CN109407985B (en) Data management method and related device
KR20150071500A (en) Method and Apparatus for Managing Data
EP3255547A1 (en) Data backup device and method
CN101963977A (en) A search method and mobile terminal without urban search
CN107329909B (en) Data management method and device
CN105183399A (en) Data writing and reading method and device based on elastic block storage
CN113835639B (en) I/O request processing method, device, equipment and readable storage medium
JP2007220107A (en) Apparatus and method for managing mapping information of nonvolatile memory
CN111831691A (en) Data reading and writing method and device, electronic equipment and storage medium
JP2006072441A (en) Memory device and control method of nonvolatile memory
US10311026B2 (en) Compressed data layout for optimizing data transactions
CN115543859A (en) Wear leveling optimization method, device, equipment and medium for multi-partition SSD
CN109871355B (en) Snapshot metadata storage method, device, equipment and medium
US20160335198A1 (en) Methods and system for maintaining an indirection system for a mass storage device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant