CN-122018795-A - Storage system
Abstract
The application provides a storage system which can be applied to the technical field of storage. The storage controller is configured to establish a mapping relation between a target logical address and an in-disk address space corresponding to a second physical port in response to a write request timeout initiated to the target logical address through a first physical port, and execute write operation for the target logical address through the second physical port according to the mapping relation. The storage system solves the problem of data inconsistency of the multi-port storage device under the single-way write timeout fault scene. By dynamically switching the address mapping of the fault port to the independent address space of the health port, the rapid seamless switching of the service level is realized.
Inventors
- LIN YONGJIE
- YANG ZHILEI
- CHEN LEI
- WU RUIQIANG
- GUO ZHAOBIN
Assignees
- 曙光信息产业股份有限公司
- 曙光信息产业(北京)有限公司
Dates
- Publication Date
- 20260512
- Application Date
- 20260121
Claims (10)
- 1. A storage system, comprising: Memory controller, and The system comprises at least one solid state disk, a plurality of storage units and a plurality of storage units, wherein the solid state disk is provided with at least two physical ports, and the at least two physical ports are respectively provided with independent in-disk address spaces; wherein the memory controller is configured to: Responding to the overtime of a write request initiated to a target logical address through a first physical port, and establishing a mapping relation between the target logical address and an in-disk address space corresponding to a second physical port, wherein the target logical address is mapped to the in-disk address space corresponding to the first physical port before the overtime of the write request; And executing the write operation aiming at the target logical address through the second physical port according to the mapping relation.
- 2. The memory system of claim 1, wherein the on-disk address space is a logical address space, the logical address space comprising a first logical address space and a second logical address space, the first logical address space being different from the second logical address space, the first physical port corresponding to the first logical address space, the second physical port corresponding to the second logical address space, the target logical address having a mapping relationship with a first logical address of the first logical address space; Wherein the storage controller is configured to perform the following operations to establish a mapping relationship between a target logical address and an in-disk address space corresponding to a second physical port: allocating a second logical address to the target logical address in the second logical address space; and establishing a mapping relation between the target logical address and the second logical address.
- 3. The storage system of claim 1, wherein the in-disk address space is a physical address space, the physical address space comprising a first physical address space and a second physical address space, the first physical address space being different from the second logical address space, the first physical port corresponding to the first physical address space, the second physical port corresponding to the second physical address space, the target logical address having a mapping relationship with a first physical address of the first physical address space; Wherein the storage controller is configured to perform the following operations to establish a mapping relationship between a target logical address and an in-disk address space corresponding to a second physical port: Allocating a second physical address to the target logical address in the second physical address space; And establishing a mapping relation between the target logical address and the second physical address.
- 4. A storage system according to claim 2 or 3, wherein the storage controller is configured to perform a write operation to the target logical address through the second physical port according to the mapping relationship: determining an in-disc target address corresponding to the target logical address based on the mapping relation, wherein the in-disc target address is positioned in an in-disc address space corresponding to the second physical port; And sending a write command to the solid state disk through the second physical port, wherein the write command comprises the target address in the disk and data to be written.
- 5. The storage system of claim 1, wherein the storage controller is further configured to: and storing an address mapping record, wherein the address mapping record is used for indicating the mapping relation between the target logical address and the address space in the disc corresponding to the second physical port.
- 6. The storage system of claim 5, wherein the solid state disk has metadata storage areas partitioned thereon, each metadata storage area comprising a first area and a second area; the memory controller is configured to: writing the address mapping record corresponding to the i-1 time-out state of the write request into the first area in the i-1 time-out state of the write request; and writing the address mapping record corresponding to the ith write request overtime state into the second area in the ith write request overtime state, wherein i is an integer larger than 1.
- 7. The storage system of claim 6, wherein the storage controller is configured to: Under the condition that the writing on the metadata storage area exceeding a preset threshold is successful, determining that the address mapping record is successfully saved; and under the condition that the reading on the metadata storage area exceeding the preset threshold is successful, determining that the address mapping record is successful in reading.
- 8. The storage system of claim 5, wherein the storage controller is further configured to: Responding to the read operation of the target logical address, and inquiring the address mapping record; And determining a physical port corresponding to the target logical address and an in-disc target address corresponding to the physical port based on the address mapping record, and executing a reading operation on the in-disc target address through the physical port.
- 9. The storage system of claim 1, wherein the storage controller is further configured to: In response to a write request timeout initiated to a target logical address through a first physical port, marking the first physical port as a write request timeout state; and executing reset and/or repair operation on the first physical port, and marking the first physical port as a health state after the operation is successful.
- 10. An electronic device, comprising: A storage system, comprising: Memory controller, and The system comprises at least one solid state disk, a plurality of storage units and a plurality of storage units, wherein the solid state disk is provided with at least two physical ports, and the at least two physical ports are respectively provided with independent in-disk address spaces; wherein the memory controller is configured to: Responding to the overtime of a write request initiated to a target logical address through a first physical port, and establishing a mapping relation between the target logical address and an in-disk address space corresponding to a second physical port, wherein the target logical address is mapped to the in-disk address space corresponding to the first physical port before the overtime of the write request; And executing the write operation aiming at the target logical address through the second physical port according to the mapping relation.
Description
Storage system Technical Field The application relates to the technical field of storage, in particular to a storage system. Background In the design of a high-availability storage system, the adoption of a dual-port solid state disk to construct a redundant data access path is a common scheme for ensuring service continuity. Such storage systems typically rely on multi-path input-output management techniques to effect automatic switching upon path failure. In the related art, when the storage controller detects that an access request initiated through a certain physical port is overtime, the path fault is determined, and the same access request is immediately re-issued to the solid state disk through another healthy physical port. Because of the independent processor and the complex flash management mechanism inside the solid state disk, the input/output request may be suspended in the internal queue of the device. If the system directly switches the path and retries writing after the writing timeout occurs, the old writing request which is suspended from the fault port before may be executed by the solid state disk after the new writing request is completed, so that the newly written data is accidentally covered, and the data consistency is destroyed. Disclosure of Invention In view of the above problems, the present application provides a storage system for fast failover of access paths to a dual-port solid state disk under the premise of ensuring data consistency. According to a first aspect of the application, a storage system is provided, which comprises a storage controller and at least one solid state disk, wherein the solid state disk is provided with at least two physical ports, the at least two physical ports are respectively provided with independent in-disk address spaces, the storage controller is configured to respond to write request timeout initiated by a first physical port to a target logical address, establish a mapping relation between the target logical address and an in-disk address space corresponding to a second physical port, the target logical address is mapped to the in-disk address space corresponding to the first physical port before the write request timeout, and execute write operation for the target logical address by the second physical port according to the mapping relation. The memory system provided by the embodiment of the application fundamentally solves the core problem of data inconsistency of the multi-port memory device under the single-way write timeout fault scene. By dynamically switching the address mapping of the fault port to the independent address space of the health port, the rapid seamless switching of the service level is realized, the correctness of data and the continuity of service are ensured, and meanwhile, the service interruption caused by forced reset of the fault port is avoided for a long time. According to the embodiment of the application, the in-disk address space is a logic address space, the logic address space comprises a first logic address space and a second logic address space, the first logic address space is different from the second logic address space, the first physical port corresponds to the first logic address space, the second physical port corresponds to the second logic address space, the target logic address has a mapping relation with the first logic address of the first logic address space, and the storage controller is configured to perform the following operation to establish the mapping relation of the in-disk address space corresponding to the target logic address and the second physical port, allocate the second logic address for the target logic address in the second logic address space, and establish the mapping relation of the target logic address and the second logic address. Through space division and management in the logic address layer of SSD, port isolation can be realized by utilizing the existing storage protocol and interface, the implementation threshold and cost of the scheme are reduced, meanwhile, the advantages of core data consistency and fast switching are maintained, and a specific implementation scheme which is easy to realize and has lower dependence on hardware is provided. According to an embodiment of the application, the in-disk address space is a physical address space, the physical address space comprises a first physical address space and a second physical address space, the first physical address space is different from the second physical address space, the first physical port corresponds to the first physical address space, the second physical port corresponds to the second physical address space, the target logical address has a mapping relation with the first physical address of the first physical address space, wherein the storage controller is configured to perform operations to establish a mapping relation of the in-disk address space corresponding to the target logical address an