Multi-channel parallel log storage method based on ZNS disk zone
By building a journal space on the ZNS disk and using multi-channel concurrency and log partition technology, the performance bottleneck and durability issues of traditional SSD disks when writing large-scale data are solved, and efficient data management and rapid recovery are achieved, improving improve the overall performance and consistency of the system.
Patent Information
- Application Number
- CN202410820440.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-24
- Publication Date
- 2024-10-01
AI Technical Summary
Traditional SSD disks frequently perform garbage collection operations during the data writing process, resulting in performance degradation and reduced available space. They also have serious performance bottlenecks and insufficient durability when writing large-scale data.
The small zone multi-channel parallel log storage method based on ZNS disk is adopted. By obtaining zone information and die information, a log space Journal Space is constructed to realize multi-channel concurrent data writing and reading, and log partitions are created to improve performance and management efficiency.
It significantly improves the overall performance and response speed of the system, solves performance bottlenecks and durability issues, achieves efficient data management and rapid recovery, and improves data consistency and management efficiency.
Smart Images

Figure CN118733541A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the field of computer storage, and in particular relates to a multi-channel parallel log storage method and system based on ZNS disk small zones. Background Art
[0002] As SSDs are increasingly used in the storage field, reducing the cost of using SSDs and improving their performance has become an important issue. Standard SSDs generate a large number of garbage collection (GC) operations during data writing, which not only reduces the available space on the SSD, but also significantly reduces the performance of the SSD after GC is started. In addition, standard SSDs usually use logical block addresses (LBA) to manage data storage, which has obvious deficiencies in performance and durability when facing large-scale data writing.
[0003] In the above technical solutions, the GC problem and performance degradation of standard SSD disks cannot be effectively solved. Traditional SSD disks often face performance bottlenecks and durability issues when processing large-scale data writes, resulting in limited overall performance of the storage system. Summary of the invention
[0004] In view of the above deficiencies in the prior art, the purpose of the invention is to provide a multi-channel parallel log storage method and system based on small zones of ZNS disks. By obtaining the regional zone information and die information of the ZNS disk, the parallel performance and space management advantages of the ZNS disk can be fully utilized, and the problems of performance degradation and reduction of available space caused by frequent GC in traditional SSD disks are solved. By constructing a log space Journal Space, multi-channel concurrent data writing and reading are realized, which significantly improves the overall performance and response speed of the system, and solves the performance bottlenecks and durability problems often faced by traditional SSD disks in large-scale data writing scenarios. By creating log partitions, efficient data management and rapid recovery are achieved, which solves the deficiencies of traditional SSD disks in data consistency and management efficiency.
[0005] The first aspect of the present invention provides a multi-channel parallel log storage method based on a ZNS disk small zone, comprising:
[0006] S1, obtaining the zone information and die information of the ZNS disk, wherein the ZNS disk is composed of a plurality of dies, each of which includes a plurality of zones, wherein IOs of different dies do not affect each other;
[0007] S2, constructing a journal space Journal Space, the journal space includes N zone groups, each zone group includes M zones selected from one die, the zone groups correspond to the die one by one, wherein N is a positive integer greater than 1, and M is a positive integer greater than 1;
[0008] S3: persist the zone group information in the Journal Space to the storage system and create a log partition.
[0009] Furthermore, the zone includes an empty state, a full state, and a writing state.
[0010] Furthermore, in the initial state of the log partition, the zones are all in the empty state.
[0011] Further, when data is written to a target zone, the target zone is converted from the empty state to the writing state, and the target zone is a zone in the zone group;
[0012] When the data of the target zone is fully written, the target zone is converted from the writing state to the full state;
[0013] When the data of the target zone is refreshed, the target zone is converted from the full state to the empty state.
[0014] Furthermore, at the target time, the number of the zones in the writing state in the zone group is one, and the zone in the writing state records the current writing position through write pos, and the target time is the time when the zone group writes data.
[0015] Furthermore, after S3, the method further includes:
[0016] When a write request for a chunk is received, the chunk is hashed to the target zone group based on the chunk ID, and the write request for the chunk corresponds one-to-one with the target zone group;
[0017] The data of the Chunk is written into the first target zone in the target zone group, where the first target zone is in the writing state.
[0018] Furthermore, when the data capacity of the Chunk is greater than the remaining storage space of the first target zone, when the first target zone is full, the first target zone is converted from the writing state to the full state, and the second target zone adjacent to the first target zone is converted from the empty state to the writing state, for writing the remaining data of the Chunk.
[0019] Furthermore, after S3, the method further includes:
[0020] When the log is played back, the status of all the zones in the Journal Space is obtained from the storage system, and the starting zone of the log is determined based on the status of the zones.
[0021] Further, determining the starting position of the log based on the state of the zone specifically includes:
[0022] Scan all third target zones in the Journal Space that are not in the empty state, read the first log header corresponding to each of the third target zones, obtain the seq_id corresponding to the first log header, and determine the minimum seq_id based on the comparison result of the seq_ids, and the zone corresponding to the minimum seq_id is the starting zone of the log.
[0023] The second aspect of the present invention provides a multi-channel parallel log storage system based on ZNS disk small zones, comprising:
[0024] An acquisition module, used to acquire the zone information and die information of a ZNS disk, wherein the ZNS disk is composed of a plurality of dies, each of which includes a plurality of zones, wherein IOs of different dies do not affect each other;
[0025] A construction module, used to construct a journal space Journal Space, wherein the journal space includes N zone groups zonegroup, each zone group includes M zones selected from one die, and the zone groups correspond to the die one by one, wherein N is a positive integer greater than 1, and M is a positive integer greater than 1;
[0026] A creation module is used to persist the zone group information in the Journal Space to a storage system and create a log partition.
[0027] Furthermore, the zone includes an empty state, a full state, and a writing state.
[0028] Furthermore, in the initial state of the log partition, the zones are all in the empty state.
[0029] Further, when data is written to a target zone, the target zone is converted from the empty state to the writing state, and the target zone is a zone in the zone group;
[0030] When the data of the target zone is fully written, the target zone is converted from the writing state to the full state;
[0031] When the data of the target zone is refreshed, the target zone is converted from the full state to the empty state.
[0032] Furthermore, at the target time, the number of the zones in the writing state in the zone group is one, and the zone in the writing state records the current writing position through write pos, and the target time is the time when the zone group writes data.
[0033] Furthermore, the multi-channel parallel log storage system based on the ZNS disk small zone also includes:
[0034] The corresponding module is used to hash the target zone group based on the Chunk ID when receiving a write request for the chunk, and the write request for the chunk corresponds to the target zone group one by one.
[0035] A writing module is used to write the data of the Chunk into a first target zone in the target zone group, where the first target zone is in a writing state.
[0036] Furthermore, when the data capacity of the Chunk is greater than the remaining storage space of the first target zone, when the first target zone is full, the first target zone is converted from the writing state to the full state, and the second target zone adjacent to the first target zone is converted from the empty state to the writing state, for writing the remaining data of the Chunk.
[0037] Furthermore, the multi-channel parallel log storage system based on the ZNS disk small zone also includes:
[0038] The determination module is used to obtain the status of all the zones in the Journal Space from the storage system when replaying the log, and determine the starting zone of the log based on the status of the zone.
[0039] Further, determining the starting position of the log based on the state of the zone specifically includes:
[0040] Scan all third target zones in the Journal Space that are not in the empty state, read the first log header corresponding to each of the third target zones, obtain the seq_id corresponding to the first log header, and determine the minimum seq_id based on the comparison result of the seq_ids, and the zone corresponding to the minimum seq_id is the starting zone of the log.
[0041] The beneficial effects of the present invention are as follows:
[0042] The method and system of the present invention can fully utilize the parallel performance and space management advantages of the ZNS disk by obtaining the regional zone information and die information of the ZNS disk, solve the problems of performance degradation and reduction of available space caused by frequent GC in the traditional SSD disk, and realize multi-channel concurrent data writing and reading by constructing the journal space Journal Space, which significantly improves the overall performance and response speed of the system, solves the performance bottleneck and durability problems often faced by the traditional SSD disk in large-scale data writing scenarios, and realizes efficient data management and rapid recovery by creating journal partitions, which solves the deficiencies of the traditional SSD disk in data consistency and management efficiency. BRIEF DESCRIPTION OF THE DRAWINGS
[0043] The accompanying drawings are only used to illustrate specific embodiments and are not considered to limit the present invention. In the entire drawings, the same reference symbols represent the same components. Obviously, the drawings described below are only some embodiments recorded in the embodiments of the present invention. For those of ordinary skill in the art, other drawings can also be obtained based on these drawings.
[0044] Figure 1 A flowchart of a multi-channel parallel log storage method based on a ZNS disk small zone provided by an embodiment of the present invention;
[0045] Figure 2 A schematic diagram of the structure of a multi-channel parallel log storage system based on ZNS disk zones provided in an embodiment of the present invention. DETAILED DESCRIPTION
[0046] In order to enable those skilled in the art to better understand the technical solutions in the embodiments of the present invention, the technical solutions of the present invention will be clearly and completely described below in conjunction with the accompanying drawings. Obviously, the described embodiments are part of the embodiments of the present invention, rather than all of the embodiments. It should be understood that these descriptions are only exemplary and are not intended to limit the scope of the present invention. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in the field without making creative work should fall within the scope of protection of the present invention.
[0047] Furthermore, in the following description, descriptions of well-known structures and technologies are omitted to avoid unnecessarily obscuring the concepts disclosed in the present invention.
[0048] In the description of the present invention, it should be noted that, unless otherwise clearly specified and limited, the orientation or position relationship indicated by the terms "center", "upper", "lower", "left", "right", "vertical", "horizontal", "inside", "outside", etc. is based on the orientation or position relationship shown in the drawings, which is only for the convenience of describing the present invention and simplifying the description, and does not indicate or imply that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore cannot be understood as a limitation of the present invention. In addition, the terms "first", "second", and "third" are only used for descriptive purposes and cannot be understood as indicating or implying relative importance. The terms "installed", "connected", and "connected" should be understood in a broad sense, for example, it can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection or an electrical connection; it can be a direct connection, or it can be indirectly connected through an intermediate medium, or it can be a connection between the two elements. For those of ordinary skill in the art, the specific meanings of the above terms in the present invention can be understood according to specific circumstances.
[0049] Exemplary embodiments will be described in detail herein, examples of which are shown in the accompanying drawings. When the following description refers to the drawings, unless otherwise indicated, the same numbers in different drawings represent the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present invention. Instead, they are merely examples of methods and systems consistent with some aspects of the present invention as detailed in the appended claims.
[0050] The present invention proposes a multi-channel parallel log storage method and system based on ZNS disk small zones, which solves the problems of frequent GC in SSD disks with traditional technology causing performance degradation and reduction of available space, and often faces performance bottlenecks and durability degradation in large-scale data writing scenarios, as well as deficiencies in data consistency and management efficiency.
[0051] Method Embodiment
[0052] Reference Manual Attached Figure 1 , shows a flow chart of a multi-channel parallel log storage method based on ZNS disk small zones provided by an embodiment of the present invention.
[0053] An embodiment of the present invention provides a multi-channel parallel log storage method based on a ZNS disk small zone, including:
[0054] Specifically, the method includes steps S1 to S3.
[0055] S1, obtain the zone information and die information of the ZNS disk. The ZNS disk is composed of multiple dies, each die includes multiple zones, and the IO between different dies does not affect each other.
[0056] Among them, ZNS disk refers to a storage device based on "Zone Namespace", and its design has significant differences and advantages over traditional disk storage. Traditional disks usually use logical block addresses (LBA) to access and manage data, while ZNS disks divide the storage space into multiple zones, each of which contains multiple sectors (or small zones), and each sector is the same size. ZNS disks are designed to optimize performance and durability in large-scale data writing scenarios.
[0057] A zone is a logical storage unit in a ZNS disk, which represents an addressable continuous storage area. In ZNS, the storage space is divided into multiple zones, each of which contains a certain number of sectors (or small zones), and these small zones are continuous.
[0058] A die is a basic chip unit in a solid-state storage device (such as an SSD), which usually contains multiple flash memory chips and related control circuits. Each die usually communicates directly with a controller in the storage device to manage the flash memory storage units therein.
[0059] IO refers to input / output operations, including data read and write operations. In a storage system, IO operations refer to the process of reading and writing data on a storage device. For example, writing data to a storage medium, reading data from a storage medium, etc.
[0060] In the present invention, by obtaining the zone and die information of the ZNS (Zone Namespace) disk, the parallel performance and space management advantages of the ZNS disk can be effectively utilized. The IO between different dies does not affect each other, which means that data read and write operations can be processed in parallel, improving the overall performance and response speed of the system. At the same time, the precise management of zone information enables more sophisticated data layout and management strategies, further optimizing the performance and reliability of the storage system.
[0061] S2, build a journal space. The journal space includes N zone groups. Each zone group includes M zones selected from a die. The zone groups correspond to the dies one by one. N is a positive integer greater than 1, and M is a positive integer greater than 1.
[0062] Among them, zone includes empty state, full state and writing state.
[0063] It should be noted that in the initial state of the log partition, the zone is empty.
[0064] Furthermore, when data is written to the target zone, the target zone is converted from an empty state to a writing state, and the target zone is a zone in the zone group.
[0065] Among them, the zone of a zone group is fixed, similar to a ring buffer, and each zone can be used cyclically to continuously perform IO.
[0066] Specifically, the empty zone is converted to the writing state through the Open operation.
[0067] When the target zone is full of data, the target zone changes from the writing state to the full state.
[0068] Specifically, when a writing zone is full, it is converted to the full state through the Finish operation.
[0069] When the data of the target zone is flushed, the target zone changes from the full state to the empty state.
[0070] Specifically, when all the data of the zone in the full state is flushed, it is converted to the empty state through the Reset operation.
[0071] It should be noted that at the target time, the number of zones in the zone group that are in the writing state is one, and the zone in the writing state records the current writing position through write pos. The target time is the time when the zone group writes data.
[0072] It should be noted that traditional log space generally intercepts a continuous disk space as the use space of the log module. For ZNS disks, we no longer use the disk LBA to manage space, but directly use zones to manage space. In order to give full play to the performance of ZNS disks, we select a certain number of zones from a die and combine them into a zonegroup.
[0073] Specifically, we do not need to consider the uniform wear problem for small zones within a die, we only need to consider the uniform wear problem between dies. By selecting multiple zone groups from multiple dies, we can form a log space that can support multiple concurrent paths.
[0074] Furthermore, after creating the Journal Space, we need to persist the zone group information in the Journal Space to rocksdb.
[0075] In the present invention, the construction of the Journal Space is achieved by managing the space using the zones of the ZNS disk, rather than the traditional continuous disk space management method, which brings significant advantages. First, by combining the zones selected from multiple dies into a zone group, the parallel performance of the ZNS disk can be fully utilized to achieve multi-channel concurrent data writing and reading, thereby improving the overall performance and response speed of the system. Secondly, by recycling the zones and realizing state transitions (such as empty, writing, full), the utilization of the storage space and the sequentiality of data writing are effectively managed and optimized, further improving the reliability and persistence of the system. Finally, persisting the information of the zone group in rocksdb ensures that the Journal Space can be quickly restored and managed after the system is started, providing a stable and efficient data processing environment for applications.
[0076] S3 persists the zone group information in the Journal Space to the storage system and creates log partitions.
[0077] In a possible implementation, the multi-channel parallel log storage method based on the ZNS disk small zone also includes:
[0078] When a write request for a chunk is received, the chunk's write request is hashed to the target zone group based on the chunk ID, and the chunk's write request corresponds one-to-one with the target zone group.
[0079] Specifically, when a Chunk write IO is received, the ChunkId is hashed and the IO is hashed to a certain Zone Group to ensure that a Chunk IO only falls into one Zone Group.
[0080] Write the Chunk data to the first target zone in the target zone group. The first target zone is in the writing state.
[0081] Among them, when the data capacity of the Chunk is greater than the remaining storage space of the first target zone, when the first target zone is full, the first target zone is converted from the writing state to the full state, and the second target zone adjacent to the first target zone is converted from the empty state to the writing state to write the remaining data of the Chunk.
[0082] Specifically, if the remaining space in the writing zone is insufficient to store a piece of log data, the zone is finished, and the next empty zone is opened to continue writing the log data.
[0083] In a possible implementation, the multi-channel parallel log storage method based on the ZNS disk small zone also includes:
[0084] When replaying a log, the status of all zones in the Journal Space is obtained from the storage system, and the starting zone of the log is determined based on the status of the zone.
[0085] Specifically, after the process is started, the information of all zone groups and the status of all zones are obtained from rocksdb.
[0086] Furthermore, for all zones in the Full and Writing states, read the header of the first data and obtain the sequence number of the header. Compare the sequence numbers, and the zone with the smallest sequence number is the starting zone of the log.
[0087] The starting position of the log is determined based on the status of the zone, including:
[0088] Scan all third target zones that are not in the empty state in the Journal Space, read the first log header corresponding to each third target zone, obtain the seq_id corresponding to the first log header, and determine the minimum seq_id based on the comparison result of the seq_id. The zone corresponding to the minimum seq_id is the starting zone of the log.
[0089] It should be noted that the order of logs has an important impact on data consistency. In this solution, the data operation unit is chunk, and there is no data dependency between chunks. In order to ensure data consistency, chunks are hashed into different log zone groups through chunkid (uint64), so that there will be no data consistency issues when revisiting logs.
[0090] In the present invention, the zone group information in the Journal Space is persisted to the storage system, realizing the creation and management optimization of log partitions. By performing hash mapping to the target zone group based on the Chunk ID, it is ensured that the write operation of each Chunk can be accurately assigned to a Zone Group, thereby realizing efficient parallel writing and data management. When the log is played back, the starting zone of the log can be quickly determined according to the persistent zone status information, ensuring the orderliness and consistency of the data. This method not only improves the performance and reliability of the system, but also effectively avoids the consistency problems that may occur during data access, providing important guarantees for the stable operation and efficient data management of the storage system.
[0091] The beneficial effects of the present invention are as follows:
[0092] The method and system of the present invention obtain the regional zone information and die information of the ZNS disk, make full use of the parallel performance and space management advantages of the ZNS disk, solve the problems of performance degradation and reduction of available space caused by frequent GC in the traditional SSD disk, and realize multi-channel concurrent data writing and reading by constructing the journal space Journal Space, which significantly improves the overall performance and response speed of the system, solves the performance bottleneck and durability problems often faced by the traditional SSD disk in the large-scale data writing scenario, and realizes efficient data management and rapid recovery by creating a journal partition, which solves the deficiencies of the traditional SSD disk in data consistency and management efficiency.
[0093] System Example
[0094] Reference Manual Attached Figure 2, shows a structural schematic diagram of a multi-channel parallel log storage system based on ZNS disk small zones provided by an embodiment of the present invention.
[0095] The embodiment of the present invention provides a multi-channel parallel log storage system 20 based on ZNS disk small zones, including:
[0096] The acquisition module 201 is used to obtain the zone information and die information of the ZNS disk. The ZNS disk is composed of multiple dies, each die includes multiple zones, and the IOs of different dies do not affect each other.
[0097] The construction module 202 is used to construct a journal space Journal Space, which includes N zone groups zonegroups, each zone group includes M zones selected from a die, and the zone groups correspond to the dies one by one, wherein N is a positive integer greater than 1, and M is a positive integer greater than 1.
[0098] Among them, zone includes empty state, full state and writing state.
[0099] It should be noted that in the initial state of the log partition, the zone is empty.
[0100] Furthermore, when data is written to the target zone, the target zone is converted from an empty state to a writing state, and the target zone is a zone in the zone group.
[0101] When the target zone is full of data, the target zone changes from the writing state to the full state.
[0102] When the data of the target zone is flushed, the target zone changes from the full state to the empty state.
[0103] It should be noted that at the target time, the number of zones in the zone group that are in the writing state is one, and the zone in the writing state records the current writing position through write pos. The target time is the time when the zone group writes data.
[0104] The creation module 203 is used to persist the zone group information in the Journal Space to the storage system and create a log partition.
[0105] In a possible implementation, the multi-channel parallel log storage system based on the ZNS disk zone also includes:
[0106] The corresponding module 204 is used to hash the target zone group based on the Chunk ID when receiving a write request for the chunk, so that the write request for the chunk corresponds one-to-one with the target zone group.
[0107] The writing module 205 is used to write the data of the Chunk to the first target zone in the target zone group. The first target zone is in the writing state.
[0108] Among them, when the data capacity of the Chunk is greater than the remaining storage space of the first target zone, when the first target zone is full, the first target zone is converted from the writing state to the full state, and the second target zone adjacent to the first target zone is converted from the empty state to the writing state to write the remaining data of the Chunk.
[0109] In a possible implementation, the multi-channel parallel log storage system based on the ZNS disk zone also includes:
[0110] The determination module 206 is used to obtain the status of all zones in the Journal Space from the storage system when replaying the log, and determine the starting zone of the log based on the status of the zone.
[0111] The starting position of the log is determined based on the status of the zone, including:
[0112] Scan all third target zones that are not in the empty state in the Journal Space, read the first log header corresponding to each third target zone, obtain the seq_id corresponding to the first log header, and determine the minimum seq_id based on the comparison result of the seq_id. The zone corresponding to the minimum seq_id is the starting zone of the log.
[0113] The present invention provides a multi-channel parallel log storage system 20 based on ZNS disk small zones, which can implement the various steps and technical effects of the above-mentioned multi-channel parallel log storage method based on ZNS disk small zones. To avoid repetition, the present invention will not go into details.
[0114] The beneficial effects of the present invention are as follows:
[0115] The method and system of the present invention obtain the regional zone information and die information of the ZNS disk, make full use of the parallel performance and space management advantages of the ZNS disk, solve the problems of performance degradation and reduction of available space caused by frequent GC in the traditional SSD disk, and realize multi-channel concurrent data writing and reading by constructing the journal space Journal Space, which significantly improves the overall performance and response speed of the system, solves the performance bottleneck and durability problems often faced by the traditional SSD disk in the large-scale data writing scenario, and realizes efficient data management and rapid recovery by creating a journal partition, which solves the deficiencies of the traditional SSD disk in data consistency and management efficiency.
[0116] The applicant of the present invention has made a detailed explanation and description of the implementation examples of the present invention in conjunction with the drawings in the specification. However, those skilled in the art should understand that the above implementation examples are only preferred implementation schemes of the present invention, and the detailed description is only to help readers better understand the spirit of the present invention, but not to limit the scope of protection of the present invention. On the contrary, any improvements or modifications based on the inventive spirit of the present invention should fall within the scope of protection of the present invention.
[0117] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the embodiments of the present invention, rather than to limit them. Although the present invention has been described in detail with reference to the above embodiments, those skilled in the art should understand that they can still modify the technical solutions recorded in the above embodiments, or replace some of the technical features therein by equivalents; and these modifications or replacements do not make the essence of the corresponding technical solutions deviate from the spirit and scope of the technical solutions of the embodiments of the present invention. Any changes or replacements that can be easily thought of by those skilled in the art within the technical scope disclosed in the present invention should be covered within the protection scope of the present invention.
Claims
1. A multi-channel parallel log storage method based on ZNS disk small zone, characterized in that: include: S1, obtaining the zone information and die information of the ZNS disk, wherein the ZNS disk is composed of a plurality of dies, each of which includes a plurality of zones, wherein IOs of different dies do not affect each other; S2, constructing a journal space Journal Space, the journal space includes N zone groups, each zone group includes M zones selected from one die, the zone groups correspond to the die one by one, wherein N is a positive integer greater than 1, and M is a positive integer greater than 1; S3: persist the zone group information in the Journal Space to the storage system and create a log partition.
2. The method for implementing a multi-channel parallel log module according to claim 1, characterized in that: The zone includes an empty state, a full state, and a writing state.
3. The method for implementing a multi-channel parallel log module according to claim 2, characterized in that: In the initial state of the log partition, the zones are all in the empty state.
4. The method for implementing a multi-channel parallel log module according to claim 3, characterized in that: When data is written to a target zone, the target zone is converted from the empty state to the writing state, and the target zone is a zone in the zone group; When the data of the target zone is fully written, the target zone is converted from the writing state to the full state; When the data of the target zone is refreshed, the target zone is converted from the full state to the empty state.
5. The method for implementing a multi-channel parallel log module according to claim 2, characterized in that: At the target time, the number of the zones in the writing state in the zone group is one, and the zone in the writing state records the current writing position through write pos, and the target time is the time when the zone group writes data.
6. The method for implementing a multi-channel parallel log module according to claim 5, characterized in that: After S3, the following is also included: When a write request for a chunk is received, the chunk is hashed to the target zone group based on the chunk ID, and the write request for the chunk corresponds one-to-one with the target zone group; The data of the Chunk is written into the first target zone in the target zone group, where the first target zone is in the writing state.
7. The method for implementing a multi-channel parallel log module according to claim 6, characterized in that: When the data capacity of the Chunk is greater than the remaining storage space of the first target zone, and the first target zone is full, the first target zone is converted from the writing state to the full state, and the second target zone adjacent to the first target zone is converted from the empty state to the writing state, for writing the remaining data of the Chunk.
8. The method for implementing a multi-channel parallel log module according to claim 2, characterized in that: After S3, the following is also included: When the log is played back, the status of all the zones in the Journal Space is obtained from the storage system, and the starting zone of the log is determined based on the status of the zones.
9. The method for implementing a multi-channel parallel log module according to claim 8, characterized in that: Determining the starting position of the log based on the state of the zone specifically includes: Scan all third target zones in the Journal Space that are not in the empty state, read the first log header corresponding to each of the third target zones, obtain the seq_id corresponding to the first log header, and determine the minimum seq_id based on the comparison result of the seq_ids, and the zone corresponding to the minimum seq_id is the starting zone of the log.
10. A multi-channel parallel log storage system based on ZNS disk small zones, characterized in that: include: processor; A memory having computer-readable instructions stored thereon, wherein when the computer-readable instructions are executed by the processor, the multi-channel parallel log module implementation method according to any one of claims 1 to 9 is implemented.
Citation Information
Patent Citations
Data storage method and system and electronic equipment
CN114625312A
Data management method based on ZNS solid state disk
CN117075810A
Storage device and data access method thereof
CN117130551A
Zoned namespace with zone grouping
US20200167274A1
