ZNS SSD new writable area generation method and system based on dynamic recombination of free physical blocks

By dynamically reorganizing free physical blocks, ZNS SSDs solve the problems of low storage space utilization and low garbage collection efficiency in data centers, achieving more efficient storage space management and extended device lifespan, and are suitable for data center and edge computing environments.

CN121996157APending Publication Date: 2026-05-08QINGHAI NORMAL UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202511963202.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-12-24
Publication Date
2026-05-08

AI Technical Summary

Technical Problem

Traditional ZNS SSDs suffer from unpredictable performance fluctuations caused by background garbage collection, write amplification effect, and low storage space utilization when facing massive data flows in data centers. Furthermore, the fixed area management mode is difficult to adapt to the changing data size and load.

Method used

By monitoring idle physical blocks at the physical and logical layers, scattered idle physical blocks are dynamically reorganized to form new continuous writable regions. This includes steps such as region status monitoring, reorganization strategy decision-making, idle block selection, effective data processing, physical reorganization, mapping table update, and resource cleanup, thereby achieving dynamic reorganization of idle blocks and resource reallocation.

Benefits of technology

It significantly improves storage space utilization and flexibility, optimizes garbage collection efficiency, improves load balancing, and extends device lifespan, making it suitable for application scenarios with significant data load fluctuations and limited resources.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121996157A_ABST
    Figure CN121996157A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of storage systems, in particular to a ZNS SSD new writable area generation method and system based on dynamic recombination of free physical blocks, and the method comprises the following steps: (1) area state monitoring; (2) triggering a decision; (3) selecting a free block and a target physical address; (4) effective data processing; (5) physical recombination; (6) updating the recombined region mapping table; (7) carrying out metadata persistence; (8) a report host; and (9) resource cleaning. The space utilization rate and flexibility are remarkably improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of storage system technology, and more specifically, to a method and system for generating new writable areas in ZNS SSDs based on dynamic reorganization of free physical blocks. Background Technology

[0002] Traditional SSDs, relying on the FTL (Flash Translation Layer) flash memory translation layer, achieve flexible and easy-to-use general-purpose storage through a "black box" management mechanism. However, when data centers face massive data deluges, their inherent bottlenecks become increasingly apparent: background garbage collection causes unpredictable performance fluctuations, severe write amplification rapidly depletes flash memory lifespan, and the large amount of space reserved to maintain performance also drives up the total cost of ownership. To address these challenges, ZNS SSDs emerged, but ZNS divides storage space into multiple fixed-size regions. The host must write sequentially to each region, and space can only be released by resetting the entire region. This results in free physical blocks being scattered across different regions when some blocks in different regions become invalid. Furthermore, releasing a region requires migrating its valid data to other regions, causing additional write operations. Even with a large number of scattered free physical blocks, the GC cannot freely consolidate any free physical blocks, and the host cannot obtain a new, complete, sequentially writable region unless an entire region happens to be reset. Summary of the Invention

[0003] The present invention provides a method and system for generating new writable areas in ZNS SSDs based on dynamic reorganization of free physical blocks, which can overcome some or all of the defects of the prior art.

[0004] The method for generating a new writable region in a ZNS SSD based on dynamic reorganization of free physical blocks according to the present invention includes the following steps: (1) Area status monitoring: At the physical layer, the zone status monitor identifies free physical blocks in the ZNS SSD that are released due to data deletion but are scattered across physical addresses; at the logical layer, the zone status monitor monitors the number of logical zones that are currently empty. (2) Triggering decision: When the data collected by the regional status monitor meets the reorganization trigger conditions, the reorganization strategy engine is activated; if the trigger conditions are not met, it continues to be in continuous regional monitoring state. (3) Select the free block and the target physical address: From the identified free physical blocks, select a set of free physical blocks as the source physical blocks for reconstruction; and select a set of physically contiguous blank erase units as the target area for reconstruction. (4) Effective data processing: Check the selected source physical blocks to determine if they contain valid data that has not yet been deleted by the host; if no valid data is found, perform physical reassembly immediately. (5) Physical recombination: The selected source physical blocks are remapped to the target contiguous address range by reorganization. (6) Update the reorganized region mapping table: In the reorganization zone mapping table, a new logical zone entry is created and written to the reorganization operation log, thereby establishing a mapping relationship from the start address of the host-visible Zone LBA to the continuous physical address; (7) Metadata persistence: The mapping relationship is atomically written to the secure area of ​​flash memory as metadata; (8) Reporting host: After persistence is complete, the Report Zones command is used to report a new logical zone with an empty state to the host. (9) Resource cleanup: Mark the source region that has been moved as resettable or offline in its original mapping table.

[0005] Preferably, in step (1), the logical states include empty, open, closed, full, and reset.

[0006] Preferably, in step (2), the reorganization trigger condition is that there are more than 300 free physical blocks and less than 10 available zones.

[0007] Preferably, in step (4), if valid data exists, the valid data is migrated to an existing Zone that is not yet full.

[0008] Preferably, in step (9), the host releases the logical address resources of the vacated source zone through the Reset Zone command, thus completing the closed loop of the entire resource reclamation and redistribution.

[0009] This invention provides a new writable region generation system for ZNS SSD based on dynamic reorganization of free physical blocks, which adopts the above-mentioned method for generating new writable regions for ZNS SSD based on dynamic reorganization of free physical blocks.

[0010] The beneficial effects of this invention are as follows: (1) Significantly Improved Space Utilization and Flexibility: The traditional fixed-area management model of ZNS is prone to space fragmentation and is difficult to adapt to varying data sizes. This invention breaks the constraints of fixed areas through a dynamic reorganization mechanism of idle physical blocks, enabling the host to dynamically construct logical write areas with flexibly configurable sizes based on the scale of real-time data streams. This on-demand allocation and elastic scaling capability enables fine-grained control and efficient utilization of NAND flash physical capacity, significantly improving the overall utilization of storage space. This feature is particularly suitable for application scenarios with significant data load fluctuations, high object size dispersion, and sensitivity to storage costs, such as cloud-native microservice architectures and resource-constrained edge computing environments.

[0011] (2) Optimize garbage collection efficiency and further reduce write amplification: Standard ZNS garbage collection is performed on a per-region basis. When the effective data distribution within a region is sparse, all effective data still needs to be migrated, resulting in unnecessary write amplification. The dynamic reorganization strategy proposed in this invention allows effective physical blocks scattered across multiple old regions to be actively merged and reorganized into a completely new sequential write region. This can clear multiple old regions with a high proportion of invalid data at once, greatly reducing the frequency and amount of effective data migration for garbage collection. Thus, based on the low write amplification of ZNS, it further approaches the theoretical optimal value and constructs a more efficient write amplification suppression mechanism.

[0012] (3) Improved load balancing and durability: Fixed region mapping may cause write loads to concentrate on some physical blocks, leading to premature wear in certain areas. The dynamic reorganization mechanism of this invention has the initiative to select from a global pool of idle physical blocks when constructing new regions. By integrating a wear-aware algorithm, the system can prioritize physical blocks with fewer programming / erase cycles, or actively direct write loads to idle storage units, thereby achieving global wear balancing management of the physical media at the device firmware level. This not only extends the overall lifespan of the solid-state memory, but also improves its reliability under long-term high-load operation. Attached Figure Description

[0013] Figure 1 This is a flowchart illustrating a method for generating a new writable region in a ZNS SSD based on dynamically reorganizing free physical blocks, as described in this embodiment. Detailed Implementation

[0014] To further understand the content of this invention, a detailed description of the invention will be provided in conjunction with the accompanying drawings and embodiments. It should be understood that the embodiments are merely illustrative and not limiting of the invention.

[0015] Example like Figure 1As shown, this embodiment provides a method for generating new writable regions in ZNS SSDs based on dynamic reorganization of free physical blocks, which includes the following steps: (1) Area status monitoring: At the physical layer, a zone status monitor identifies free physical blocks in the ZNS SSD that have been released due to data deletion but are geographically dispersed. At the logical layer, the zone status monitor monitors the number of logical zones that are currently empty. Logical states include empty, open, closed, full, and reset.

[0016] In this embodiment, under the custom physical state, the flash array has a total of 4096 physical blocks. After a period of operation, 320 of these physical blocks become idle due to data deletion, but they are distributed across 100 different physical erase units. Under the logical state, only 5 of the 256 standard 1-giB zones visible to the host are empty.

[0017] (2) Triggering decision: When the data collected by the zone status monitor meets the reorganization trigger conditions (the reorganization trigger conditions are >300 free physical blocks and <10 available zones), the reorganization policy engine is activated; if the trigger conditions are not met, it continues to be in continuous zone monitoring state.

[0018] (3) Select the free block and the target physical address: From the identified free physical blocks, select a set of free physical blocks as the source physical blocks for reconstruction; and select a set of physically contiguous blank erase units as the target area for reconstruction.

[0019] In this embodiment, 256 physical blocks (total capacity = 256 × 16 MiB = 4 GiB) are selected from 320 free blocks as the reorganization source physical blocks. A continuous target physical address range is planned: {chip 0, channel 0, block 500} to {chip 0, channel 0, block 755} (a total of 256 consecutive blocks).

[0020] (4) Effective data processing: The selected source physical block is checked to determine if it contains valid data that has not yet been deleted by the host. If no valid data is found, physical reassembly is performed immediately. If valid data is found, the valid data is migrated to an existing Zone that is not yet full.

[0021] In this embodiment, if valid data exists, an inspection reveals that 8 out of 256 source blocks contain a small amount of valid data (approximately 128 MiB in total). This 128 MiB of data is then migrated to an existing, not-full Zone. If no valid data exists, physical reassembly is performed immediately.

[0022] (5) Physical recombination: The selected source physical blocks are remapped to the target contiguous address range by reorganization.

[0023] In this embodiment, the selected 256 free blocks are reorganized and remapped to the target contiguous address range.

[0024] (6) Update the reorganized region mapping table: In the reorganization zone mapping table, a new logical zone entry is created and written to the reorganization operation log, thereby establishing a mapping relationship from the start address of the Zone LBA visible to the host to the continuous physical address; the mapping information includes (new logical zone ID: Z_R1, start LBA: 0x8C0000000, physical start address: {chip0, channel0, block500}, zone size: 4 GiB, status: under construction).

[0025] (7) Metadata persistence: The mapping relationship is atomically written to the secure area of ​​flash memory as metadata.

[0026] In this embodiment, the mapping relationship of the reassembly operation is atomically written to a specific secure area of ​​the flash memory as a log. Even if a power outage occurs at this time, the reassembly state can be restored according to the log after the next power-on, preventing data loss or corruption. The log information includes (log sequence number: 0x5A3F, operation type: new reassembly area, area ID: Z_R1, physical mapping: {chip0, channel0, block 500}, 256 blocks}, logical block address LBA: 0x8C0000000).

[0027] (8) Reporting host: Once persistence is complete, the Report Zones command is used to report a new, empty logical zone to the host; the host application or file system immediately becomes aware of this "newly available" write space.

[0028] (9) Resource cleanup: The source regions that have been emptied (where the physical blocks have been removed) are marked as resettable or offline in their original mapping table. The host can then officially release the logical address resources of these regions using the Reset Zone command, completing the closed loop of resource reclamation and reallocation (re-entering zone monitoring state).

[0029] This embodiment provides a ZNS SSD new writable area generation system based on dynamic reorganization of free physical blocks, which adopts the above-mentioned ZNS SSD new writable area generation method based on dynamic reorganization of free physical blocks.

[0030] This embodiment optimizes the flexibility of storage space reorganization, thereby improving the write utilization of the ZNS region. A free block reorganization engine is added to the original ZNS SSD design; it runs internally within the SSD controller, is completely transparent to the host, and requires no modification to the host software, operating system, or existing ZNS standards.

[0031] The engine: First, continuously monitors the physical status of all regions, identifying scattered free physical blocks. Second, in the background, it reorganizes these free physical blocks into a set of contiguous physical erase units. Third, through an internal reorganization region mapping table, it virtualizes the newly formed, physically contiguous set of free blocks into a new, complete logical region and reports it to the host. Finally, it ensures the consistency and security of all data migrations and mapping changes in the event of unexpected power outages or other adverse conditions.

[0032] The present invention and its embodiments have been described above illustratively. This description is not restrictive, and the figures shown are only one embodiment of the present invention; the actual structure is not limited thereto. Therefore, if those skilled in the art are inspired by this description and design similar structures and embodiments without departing from the spirit of the present invention, such designs should fall within the protection scope of the present invention.

Claims

1. A method for generating new writable regions in ZNS SSDs based on dynamic reorganization of free physical blocks, characterized in that: Includes the following steps: (1) Area status monitoring: At the physical layer, the zone status monitor identifies free physical blocks in the ZNS SSD that are released due to data deletion but are scattered across physical addresses; at the logical layer, the zone status monitor monitors the number of logical zones that are currently empty. (2) Triggering decision: When the data collected by the regional status monitor meets the reorganization trigger conditions, the reorganization strategy engine is activated; if the trigger conditions are not met, it continues to be in continuous regional monitoring state. (3) Select the free block and the target physical address: From the identified free physical blocks, select a set of free physical blocks as the source physical blocks for reconstruction; and select a set of physically contiguous blank erase units as the target area for reconstruction. (4) Effective data processing: Check the selected source physical blocks to determine if they contain valid data that has not yet been deleted by the host; if no valid data is found, perform physical reassembly immediately. (5) Physical recombination: The selected source physical blocks are remapped to the target contiguous address range by reorganization. (6) Update the reorganized region mapping table: In the reorganization zone mapping table, a new logical zone entry is created and written to the reorganization operation log, thereby establishing a mapping relationship from the start address of the host-visible Zone LBA to the continuous physical address; (7) Metadata persistence: The mapping relationship is atomically written to the secure area of ​​flash memory as metadata; (8) Reporting host: After persistence is complete, the Report Zones command is used to report a new logical zone with an empty state to the host. (9) Resource cleanup: Mark the source region that has been moved as resettable or offline in its original mapping table.

2. The method for generating a new writable region in a ZNS SSD based on dynamic reorganization of free physical blocks according to claim 1, characterized in that: In step (1), the logical states include empty, open, closed, full, and reset.

3. The method for generating a new writable region in a ZNS SSD based on dynamic reorganization of free physical blocks according to claim 2, characterized in that: In step (2), the reorganization trigger condition is that there are more than 300 free physical blocks and less than 10 available zones.

4. The method for generating a new writable region in a ZNS SSD based on dynamic reorganization of free physical blocks according to claim 3, characterized in that: In step (4), if valid data exists, the valid data is migrated to an existing Zone that is not yet full.

5. The method for generating a new writable region in a ZNS SSD based on dynamic reorganization of free physical blocks according to claim 4, characterized in that: In step (9), the host releases the logical address resources of the vacated source zone through the Reset Zone command, completing the closed loop of the entire resource reclamation and redistribution.

6. A ZNS SSD new writable area generation system based on dynamic reorganization of free physical blocks, characterized in that: It employs the ZNS SSD new writable region generation method based on dynamic reorganization of free physical blocks as described in any of claims 1-5.