CN110851383B - Method and equipment for managing storage system - Google Patents

Method and equipment for managing storage system Download PDF

Info

Publication number
CN110851383B
CN110851383B CN201910920051.9A CN201910920051A CN110851383B CN 110851383 B CN110851383 B CN 110851383B CN 201910920051 A CN201910920051 A CN 201910920051A CN 110851383 B CN110851383 B CN 110851383B
Authority
CN
China
Prior art keywords
ssd
virtual
namespaces
ssds
access request
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.)
Active
Application number
CN201910920051.9A
Other languages
Chinese (zh)
Other versions
CN110851383A (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.)
Huawei Technologies Co Ltd
Original Assignee
Huawei Technologies 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 Huawei Technologies Co Ltd filed Critical Huawei Technologies Co Ltd
Priority to CN201910920051.9A priority Critical patent/CN110851383B/en
Publication of CN110851383A publication Critical patent/CN110851383A/en
Application granted granted Critical
Publication of CN110851383B publication Critical patent/CN110851383B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F13/00Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
    • G06F13/14Handling requests for interconnection or transfer
    • G06F13/16Handling requests for interconnection or transfer for access to memory bus
    • G06F13/1668Details of memory controller
    • 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/0625Power saving in storage systems
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0628Interfaces specially adapted for storage systems making use of a particular technique
    • G06F3/0662Virtualisation aspects
    • 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/0683Plurality of storage devices

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Human Computer Interaction (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

A method and device for managing a storage system are used for reducing the number of SSD attribute sets required to be maintained by an upper layer application and reducing the resource consumption of the application. The method of managing a storage system is performed by a storage controller and includes the steps of: scanning at least one SSD to obtain M item attribute sets of the at least one SSD, wherein each SSD corresponds to at least one attribute set; constructing N virtual SSDs according to M attribute sets obtained by scanning, wherein each virtual SSD is constructed according to at least two attribute sets, the attribute set of each virtual SSD is formed by combining the at least two attribute sets, M is an integer greater than or equal to 2, and N is a positive integer less than M; and reporting the attribute sets of the N virtual SSDs to an application, so that the application accesses the N virtual SSDs according to the attribute sets of the N virtual SSDs.

Description

Method and equipment for managing storage system
Technical Field
The present application relates to the field of computer technologies, and in particular, to a method and apparatus for managing a storage system.
Background
In a storage system having a plurality of solid state disks (English: solid state drives, SSDs), an apparatus for managing SSDs needs to scan each SSD disk to obtain an attribute set of each SSD, and then report the attribute set of each SSD to an application, where the application accesses the SSD according to the attribute set of each SSD.
However, the storage system is larger and larger, and a storage system comprises a plurality of SSDs, so that each application needs to manage a plurality of attribute sets of the SSDs, consumes a plurality of resources, and increases the complexity of the system.
Disclosure of Invention
The application provides a method and equipment for managing a storage system, which are used for reducing the number of SSD attribute sets required to be maintained by an upper layer application and reducing resource consumption.
In a first aspect, the present application provides a method of managing a storage system, the method being performed by a storage controller, which may be located in the same physical entity as at least one SSD, or the storage controller may be a separate control device, in communication with the at least one SSD over a network. First, the storage controller scans at least one SSD to obtain M item attribute sets of the at least one SSD, wherein each SSD corresponds to at least one attribute set. Then, the storage controller constructs N virtual SSDs according to M attribute sets obtained by scanning, each virtual SSD is constructed according to at least two attribute sets, the attribute set of each virtual SSD is formed by combining the at least two attribute sets, M is an integer greater than or equal to 2, and N is a positive integer less than M; and reporting the attribute sets of the N virtual SSDs to an application, so that the application accesses the N virtual SSDs according to the attribute sets of the N virtual SSDs.
After the storage controller scans at least one SSD in the storage system, according to a plurality of attribute sets obtained by scanning, combining storage spaces in the attribute sets, constructing a virtual SSD, and reporting the attribute sets of the virtual SSD to the application. The application can access the virtual SSD according to the attribute set of the virtual SSD to finish operations such as reading and writing data, the number of SSD attribute sets required to be maintained by the application is greatly reduced, and the resource consumption of the application is reduced.
In one possible implementation, each attribute set includes a storage space size, e.g., a namespace (English: namespace) identifier of an SSD and a size of the corresponding storage space for the Namespace. And the storage controller merges the storage space sizes in the attribute sets obtained by scanning, and constructs a virtual SSD according to at least two attribute sets when the storage space sizes in the at least two attribute sets reach a preset capacity after being merged.
In one possible implementation, the storage controller constructs a virtual SSD according to a preset number of the attribute sets, where the virtual set includes a sum of storage space sizes of the preset number of attribute sets.
In one possible implementation, the storage controller stores a mapping between a logical address of each virtual SSD and a physical address in the at least one SSD after constructing N virtual SSDs according to the M attribute sets obtained by scanning, and determines, according to the stored mapping, a physical address of the first SSD in the at least one corresponding to the logical address of the first virtual SSD included in the first access request after obtaining the first access request of the application; and sending a second access request to the first SSD, the second access request including the determined physical address, the second access request being identical to the data operation requested by the first access request. By the method, the application can realize data access through the attribute set of the virtual SSD.
In one possible implementation, the second SSD of the at least one includes at least one SSD controller; and when the storage controller scans the second SSD, one attribute set is obtained according to the scanning of each SSD controller of the second SSD.
In a second aspect, the application provides an apparatus for managing a storage system, the apparatus comprising means for performing the method of the first aspect or any possible implementation of the first aspect.
In a third aspect, the present application provides a memory controller comprising a processor, a transceiver, and a bus, the processor and transceiver communicating over the bus. The transceiver is used for communicating with other network elements, such as a plurality of SSDs, application servers. The processor is configured to perform the method of the first aspect or any possible implementation of the first aspect described above by a transceiver.
In one possible implementation, the processor includes a first processor, such as a central processing unit (English: central processing unit, CPU), for scanning a plurality of SSDs through a transceiver to obtain a set of attributes for each SSD. The processor further includes a second processor, e.g., an application specific integrated circuit (English: application specific integrated circuit, ASIC), for constructing a virtual SSD from the obtained set of attributes of the at least one SSD from the storage space in the SSD, generating a set of attributes of the virtual SSD.
In a fourth aspect, the present application provides a storage device including a storage controller and a plurality of SSDs, the storage controller being connected to the plurality of SSDs by a bus. The memory controller is adapted to perform the method of the first aspect or any possible implementation of the first aspect.
In a fifth aspect, the present application provides a computer readable medium storing a computer program comprising instructions for performing the method of the first aspect or any possible implementation of the first aspect.
Further combinations of the present application may be made to provide further implementations based on the implementations provided in the above aspects.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings that are needed in the description of the embodiments will be briefly described below, it will be apparent that the drawings in the following description are only some embodiments of the present application, and that other drawings can be obtained according to these drawings without inventive effort for a person skilled in the art.
FIGS. 1 a-1 b are schematic diagrams illustrating possible configurations of a memory controller according to embodiments of the present application;
FIG. 2 is a flow chart of a method for managing a storage system according to an embodiment of the application;
FIG. 3 is a detailed flow chart of a method for managing a storage system according to an embodiment of the present application;
FIG. 4 is a schematic diagram of an apparatus for managing a storage system according to an embodiment of the present application;
FIG. 5 is a schematic diagram of another apparatus for managing a storage system according to an embodiment of the present application.
Detailed Description
The following detailed description of the technical solutions of the present application will be given by way of the accompanying drawings and specific embodiments, and it should be understood that the specific features of the embodiments and embodiments of the present application are detailed descriptions of the technical solutions of the present application, and not limiting the technical solutions of the present application, and that the embodiments and technical features of the embodiments of the present application may be combined with each other without conflict.
In the embodiment of the present application, the storage system includes a plurality of solid state disks SSD20 and a storage controller 10. The memory controller can have at least two modes.
Form 1, referring to fig. 1a, the storage controller 10 may be a stand-alone computer, also referred to as a host, connected to at least one SSD20 via the internet or a private network. In practice, a plurality of storage controllers 10 may be included in the storage system, each storage controller 10 being capable of taking care of receiving a user's access to the SSD20. In the following description of the embodiments of the present application, the description is based on one storage controller 10 in a storage system, and the same implementation manner may be adopted for other storage controllers 10 in the storage system.
Form 2 referring to fig. 1b, the storage controller 10 and at least one SSD20 are located within one physical entity, commonly referred to as a hard disk frame. In practice, the storage system may comprise a plurality of such hard disk frame structures.
In the embodiment of the present application, the SSD20 may be specifically connected to the memory controller 10 through a peripheral component interconnect express (PCI-E) interface (english: peripheral component interconnect express) using the above-described configuration 1 or configuration 2.
In the embodiment of the present application, the SSD20 includes an SSD controller (a control chip of the SSD 20) and a storage unit. The memory unit is used for storing data, and can be divided into a flash memory (English: flash disk) and a dynamic random access memory (English: dynamic random access memory, DRAM) according to different memory media. The SSD controller is used for allocating the load of data on each storage unit and transferring the data. In addition, the SSD controller can also be used to: error correction, wear leveling, bad block mapping, read-write caching, garbage collection, encryption, and other functional algorithms. Optionally, a buffer unit for data buffering may be further included in the SSD20.
In an embodiment of the present application, the memory controller 10 includes, but is not limited to, the following functions:
in the first function, the storage controller 10 runs the SSD driver, scans the SSD20, and obtains the attribute set of the SSD20. For example, a flash nonvolatile memory (NVMe) driver is loaded on the storage controller 10, and the storage controller 10 runs the NVMe driver to scan each SSD20 connected to the storage controller 10, so as to obtain an attribute set of each SSD20.
Table 1 is a schematic representation of the obtained SSD attribute set when the SSD20 is scanned by the storage controller 10, and the controller in the table refers to the SSD controller.
Kernel PCI device data structure corresponding to controller
MMIO space mapped by controller BAR space
Array of all management queues and IO queue data structures contained by controller
Total number of controller queues
Linked list of all the nacesespace corresponding to the controller
……
TABLE 1
The definitions of some of the english abbreviations or words in table 1 are as follows:
PCI, english is named peripheral component interconnect, chinese paraphrasing is: peripheral component interconnect standards.
BAR, english, fully base address register, chinese paraphrasing: a base address register.
IO, english is called input/output, chinese paraphrasing is: input/output.
The Chinese paraphrasing is as follows: namespaces (or namespaces). In the embodiment of the application, one controller can correspond to one or more namesespace, and each namesespace corresponds to one logic storage space. Table 2 is a schematic representation of a linked list of nasspace.
Operation pointer of corresponding linked list of Namespace
Namespace corresponding controller
Namespace corresponding waiting queue
Namespace corresponds to information (disk name, version number, etc.) of the logical disk
Namespace identification
number of logical blocks of a nacespace
Size of each logical block of a naspace
……
TABLE 2
The capacity of the logical storage space corresponding to the nacespace can be determined according to the "number of logical blocks of the nacespace" and the "size of each logical block of the nacespace" in table 2. And the sum of the capacities of the logical storage spaces corresponding to all the nano spaces corresponding to one SSD20 is the capacity of the SSD20.
In the second function, the storage controller 10 merges the storage spaces of the SSDs 20 according to the attribute sets of the plurality of SSDs 20 obtained by scanning to form a virtual SSD, and generates the attribute set of the virtual SSD.
In the solution described in the background of the present application, the storage controller 10 reports the SSD attribute set obtained by scanning to an application (also referred to as an upper layer application), so that the application accesses the SSD20 according to the SSD attribute set. However, this results in applications that need to maintain a large set of attributes, and a large resource consumption.
In order to solve the problem, in the embodiment of the present application, the storage controller 10 merges the storage spaces of the SSDs 20 according to the attribute sets of the multiple SSDs 20 obtained by scanning to form a virtual SSD, generates the attribute set of the virtual SSD, and then reports the attribute set of the virtual SSD to the application.
In the embodiment of the present application, the virtual SSD refers to a virtualized storage device formed by logically merging the storage spaces of different SSDs 20. The data structure of the attribute set of the virtual SSD may be the same as the data structure of the attribute set before merging, or only partial data of interest of the application may be reserved, such as the identifier of the virtual SSD and the capacity of the virtual SSD.
Each attribute set of the multiple attribute sets before merging comprises at least one nacespace, and the attribute set of the virtual SSD after merging can only have one nacespace, and the identity of the nacespace is used as the identity of the virtual SSD. This identifier may be an identifier of any one of the plurality of attribute sets included in any one of the plurality of attribute sets before merging (for example, an identifier of a least numbered one of all the plurality of attribute sets included in the plurality of attribute sets), or may be an unused identifier generated by the storage controller 10.
In addition, in the nalspace linked list in the attribute set after merging, the number of logical blocks of the nalspace is the sum of the numbers of logical blocks of each nalspace in all attribute sets before merging. While the size of each logical block remains unchanged.
For example, the storage controller 10 scans 10 SSDs 20, and may obtain 1 attribute set for each SSD20, which may include 1 nano space in each attribute set, each nano space includes 10 ten thousand logic blocks, and each logic block has a size of 10MB, and each nano space corresponds to a storage space of 1TB. All 10 attribute sets of the 10 SSDs 20 are combined to form an attribute set of a virtual SSD, wherein the attribute set of the virtual SSD comprises 1 nano space, the number of logical blocks included by the nano space is 100 ten thousand, and the capacity of the virtual SSD is 10TB if the size of each logical block is 10 MB.
In addition, in the embodiment of the present application, the storage controller 10 may construct a plurality of virtual SSDs according to the attribute set obtained by scanning at least one SSD; in addition, the storage controller 10 may construct 1 or more virtual SSDs from only the attribute set obtained by scanning a part of the SSDs 20.
And thirdly, the storage controller 10 is further configured to report the attribute set of the merged virtual SSD to the application, so that the application accesses the virtual SSD according to the attribute set of the virtual SSD.
The application accessing the virtual SSD means that the application accesses the SSD20 corresponding to the virtual SSD.
In practice, the storage controller 10 may only merge a part of the SSD attribute sets, and obviously, the storage controller 10 still reports the non-merged SSD attribute sets to the application.
In the embodiment of the present application, the application refers to an application program that needs to access the SSD20, for example, a database program stores data in the SSD20, where the database program is the application in the embodiment of the present application, and needs to access the SSD20 to write or read the data.
In combination with the form of the storage controller 10 shown in fig. 1a, an application in the embodiment of the present application may run on the storage controller 10, in which case, the storage controller 10 reports the attribute set of the virtual SSD to the application, which refers to a logic module of the storage controller 10 responsible for merging the attribute set of the SSD reporting the attribute set of the virtual SSD to the logic module corresponding to the application. The application may also run on a device external to the storage controller 10 (e.g., another server), the storage controller 10 sending the set of attributes of the virtual SSD to the device where the application resides, either over the Internet or with a private network.
In the system architecture of fig. 1b, the application in the embodiment of the present application runs in a device (such as a server in fig. 1 b) outside the hard disk frame composed of the storage controller 10 and the at least one SSD20.
In the above technical solution of the present application, after the storage controller 10 in the storage system scans at least one SSD20 in the storage system, a part of the SSD attribute sets therein are combined to generate a virtual SSD attribute set, so as to form a virtual SSD, and the attribute set of the virtual SSD is reported to the application. The application can read and write data according to the attribute set of the virtual SSD, the number of SSD attribute sets which the application needs to maintain is greatly reduced, and the resource consumption of the application is reduced.
In one possible implementation, the above-mentioned functions of the above-mentioned storage controller 10 may be implemented by an SSD20 driving module, such as an NVMe driving program, running on the above-mentioned storage controller 10.
The second function of the memory controller 10 may be implemented by a capacity conversion module (english: capacity transform module, CTM), which is specifically configured to: the driving module of the record storage controller 10 scans all the obtained attribute sets of the SSDs 20, merges at least one SSD20 according to preset rules, generates a virtual SSD, and reports the generated attribute sets of the virtual SSD to an application.
In the embodiment of the present application, the capacity conversion module CTM is a module logically divided, and there are various forms of implementation thereof. For example, the CTM may be a software module running on the memory controller 10, and the memory controller 10 implements the functions of the CTM by running CTM software code through a central processing unit (English: central processing unit, CPU). For another example, the CTM may be a physical chip on the memory controller 10, such as an application specific integrated circuit (English: application specific integrated circuit, ASIC) chip.
It should be noted that, the storage controller 10 merges the SSDs 20 to construct a virtual SSD, which means that the logical merge does not change the physical structure of each SSD20. For the above application, the application performs data reading and writing according to a command specified by a protocol, for example, when the SSD20 is a PCI-E SSD20, the application uses an NVMe command to read and write data, and the application does not care whether the attribute set of the SSD20 maintained by the application corresponds to the physical SSD20 disk or the virtual SSD disk.
In another possible implementation manner, in an embodiment of the present application, the storage controller 10 merges at least one SSD20 into a virtual SSD according to a preset rule, where the preset rule may be any one of the following:
the storage controller 10 accumulates the storage space sizes in the capacity attributes obtained by scanning in preset rule 1, and constructs a virtual SSD according to a plurality of attribute sets participating in storage space size accumulation after the accumulated storage space sizes reach the preset sizes.
For example, after the storage controller 10 sets a preset capacity value, such as 10TB, the storage controller 10 scans all SSDs 20 in the storage system, and obtains a set of attributes of each SSD20, where the set of attributes includes the capacity of each SSD20. The storage controller 10 accumulates the capacities of the SSDs 20, merges the SSDs 20 with the sum of the capacities reaching the preset capacity value into one virtual SSD, for example, merges 10 1T SSDs 20 into one virtual SSD, and generates an attribute set of the virtual SSD, for example, the capacity of the virtual SSD and the identifier of the virtual SSD.
In practical situations, the application only concerns the storage space, but does not concern the physical distribution of the storage position, so the storage controller 10 performs SSD20 merging through the merging rule, thereby not only meeting the requirement of the application on the storage space capacity, but also reducing the number of the maintained attribute sets and reducing the resource consumption.
The preset rule 2, the storage controller 10 counts the attribute sets obtained by scanning, and after the count reaches the preset number, a virtual SSD is constructed according to the attribute sets participating in the count.
For example, after the storage controller 10 sets a preset value, such as 10, the storage controller 10 scans all the SSDs 20 in the storage system, records the attribute set of each SSD20, and then the storage controller 10 merges the 10 SSDs 20 into a virtual SSD, and generates the attribute set of the merged virtual SSD, such as the capacity of the virtual SSD and the identifier of the virtual SSD, according to the attribute set of the 10 SSDs 20.
The storage controller 10 performs the combination of the SSDs 20 according to the number of the SSDs 20, and has simple implementation and small operation amount.
The preset rule 3 may have a small number of SSDs 20 remaining after the SSDs 20 are merged according to the rule of the preset rule 1 or the preset rule 2, and the SSDs 20 do not satisfy the merging rule, but the SSDs 20 are not yet merged but are SSDs 20 stored in the storage system, so that the SSDs 20 may be directly merged to construct a virtual SSD.
For example, in combination with the preset rule 1, the storage system includes 95 SSDs 20 in total, the capacity of each SSD20 is 1TB, the storage controller 10 merges 90 SSDs 20 into 9 virtual SSDs according to the preset capacity value 10TB, and the remaining 5 SSDs 20 do not reach the preset capacity value 10TB, but since the storage system does not have the uncombined SSDs 20, the storage controller 10 directly merges the 5 SSDs 20 to construct a virtual SSD.
For another example, in combination with the preset rule 2, the storage system includes 95 SSDs 20 in total, the storage controller 10 merges 90 SSDs 20 into 9 virtual SSDs according to the preset number value 10, and the remaining 5 SSDs 20 do not reach the preset number value 10, but since the storage system does not have the uncombined SSDs 20, the storage controller 10 directly merges the 5 SSDs 20 to construct a virtual SSD.
In the embodiment of the present application, the storage controller 10 may perform the above-mentioned merging operation on all scanned SSDs 20, or may perform the above-mentioned merging operation on only a part of SSDs 20, which is not limited in the embodiment of the present application.
In another possible implementation, some or all of the SSDs 20 in the storage system have multiple SSD controllers (i.e., control chips), and one SSD20 is provided with multiple SSD controllers in order to increase the access speed of the SSD20. However, when the storage controller 10 scans the SSD20 provided with the plurality of SSD controllers, a plurality of attribute sets are obtained by scanning the SSD controller number of the SSD20. For example, when an NVMe driver scans an SSD20 having 4 SSD controllers, the scan obtains 4 attribute sets, in other words, the NVMe driver recognizes one physical SSD20 disk as 4 SSDs 20. In this case, after the storage controller 10 reports the SSD attribute set obtained by scanning to the application, the number of attribute sets that the application needs to maintain increases.
To solve this problem, in the embodiment of the present application, the storage controller 10 may perform SSD20 merging according to the SSD attribute set obtained by scanning.
For example, when the SSD20 is combined in the foregoing manner 1, the preset capacity value set by the storage controller 10 is 10TB, and each of the first SSD20, the second SSD20, and the third SSD20 has 4 SSD controllers. After scanning the first SSD20, the storage controller 10 obtains an attribute set 1, an attribute set 2, an attribute set 3, and an attribute set 4, which respectively correspond to the logical SSD201, the logical SSD202, the logical SSD203, and the logical SSD204; similarly, the storage controller 10 scans the second SSD20 as the SSD205, the SSD206, the SSD207, the SSD208, and scans the third SSD20 as the SSD209, the SSD2010, the SSD2011, the SSD2012, and the set of attributes of each SSD20 in the SSDs 201 to 2012 indicates that the capacity thereof is 1TB. When the storage controller 10 merges the SSDs 20, it accumulates the capacities of the SSDs 201 to 2012, determines that the sum of the capacities of the SSDs 201 to 2010 reaches 10TB, and generates an attribute set of the virtual SSDs from the attribute set 1 to the attribute set 10, thereby constructing the virtual SSDs.
For another example, when the SSD20 is merged in the above-described embodiment 2, the storage controller 10 adds up the numbers of the attribute sets 1 to 12 to determine that the sum of the numbers of the attribute sets 1 to 10 reaches the preset number value 10, and generates the attribute sets of the virtual SSD from the attribute sets 1 to 10 to construct the virtual SSD when the SSD20 is merged.
It can be seen that if one SSD20 physical disk is scanned into multiple SSDs 20 in a logical sense, the storage controller 10 does not care about the physical distribution of the SSDs 20 scanned when constructing the virtual SSDs, and therefore, a first portion of SSDs 20 scanned by one SSD20 can be merged into a first virtual SSD, while a second portion of SSDs 20 scanned by that SSD20 is merged into a second virtual SSD.
Through the above technical scheme, under the condition that the SSD20 is provided with a plurality of SSD controllers, SSD attribute sets required to be maintained by the application can be reduced, and resource consumption of the application is reduced.
In the embodiment of the present application, after the storage controller 10 generates the virtual SSDs, the mapping between the logical address of each virtual SSD and the physical address in the SSD20 is saved. The application maintains an attribute set of the virtual SSD, and accesses the virtual SSD according to the attribute set of the virtual SSD, wherein one possible implementation manner is as follows:
the application sends a first access request to the memory controller 10, the first access request including a first logical address in the first virtual SSD.
The storage controller 10 determines that the first logical address in the first virtual SSD corresponds to the first physical address in the first SSD according to the stored mapping. Then, the storage controller 10 sends a second access request to the first SSD entity, the second access request being identical to the data operation requested by the first access request. The second access request is identical to the data operation requested by the first access request, and means that: the second access request is simply a forwarding of the first access request, and is different in that the address of the data is expressed differently, in the first access request, the address of the data is the first logical address in the virtual SSD, and in the second access request, the address of the data is the first physical address in the first SSD20.
Optionally, in combination with the above technical solution that the storage controller 10 sends the second access request to the SSD20, the SSD20 returns an access result to the storage controller 10 according to the second access request, for example, when the second access request is a read data request, the access result is the target data; for another example, when the second access request is a write data request, the access result is a data write success/failure message.
And the memory controller 10 returns the access result to the application after receiving the access result so that the application can obtain the access result.
In the embodiment of the present application, one storage controller 10 may report the attribute set of the virtual SSD to a plurality of applications, and each application may perform data access according to the attribute set of the virtual SSD. In such a system architecture, each application only needs to maintain a small set of attributes of the virtual SSD, and when access to the data is required, the application sends the address of the data in the virtual SSD to the storage controller 10, and the storage controller 10 can translate the address into an address in the SSD20 and forward the access request of the application to the SSD20. In other words, the application need only care about a small number of virtual SSDs, with the storage controller 10 being responsible for the transitions between virtual SSDs and SSDs 20. When one storage controller 10 serves a plurality of applications, the burden on each application is greatly reduced, and the efficiency of the entire system can be greatly improved.
In one possible implementation, when the storage controller 10 is in the form shown in fig. 1b, the storage controller 10 can scan the SSD20 in the hard disk frame itself, and can scan the SSD20 in other hard disk frames via the network.
The embodiment of the present application further provides a method for managing a storage system, referring to fig. 2, the method is performed by the storage controller 10 shown in any one of fig. 1a and 1b, and the method includes the following steps:
step 301: the storage controller scans at least one SSD to obtain M item attribute sets of the at least one SSD, and each SSD corresponds to at least one attribute set;
step 302: the storage controller constructs N virtual SSDs according to M attribute sets obtained by scanning, each virtual SSD is constructed according to at least two attribute sets, the attribute set of each virtual SSD is formed by combining the at least two attribute sets, M is an integer greater than or equal to 2, and N is a positive integer less than M;
step 303: and the storage controller reports the attribute sets of the N virtual SSDs to an application, so that the application accesses the N virtual SSDs according to the attribute sets of the N virtual SSDs.
In one possible implementation, each attribute set includes a storage space size, step 302: constructing N virtual SSDs according to the M attribute sets obtained by scanning, wherein the N virtual SSDs comprise:
and merging the storage space sizes in the attribute sets, and constructing a virtual SSD according to the at least two attribute sets with the merged storage space sizes reaching a preset capacity.
In one possible implementation, step 302: constructing N virtual SSDs according to the M attribute sets obtained by scanning, wherein the N virtual SSDs comprise:
and constructing a virtual SSD according to the preset number of attribute sets.
In one possible implementation, referring to fig. 3, the method further includes, simultaneously with or after the step 302, the following steps:
step 304: a storage controller storing a mapping of logical addresses of each of the virtual SSDs to physical addresses in the at least one;
after step 303, the method further comprises the steps of:
step 305: the storage controller obtains a first access request of the application, wherein the first access request comprises a logic address in a first virtual SSD in the N virtual SSDs;
step 306: the storage controller determines a physical address of the first SSD in the at least one corresponding to the logical address according to the stored mapping;
step 307: the storage controller sends a second access request to the first SSD, the second access request including the physical address, the second access request being identical to the data operation requested by the first access request.
In one possible implementation, the second SSD of the at least one includes a plurality of SSD controllers; in the execution process of step 301, one attribute set is obtained according to each SSD controller scan of the second SSD.
The steps 301 to 307 are performed by the memory controller 10 in fig. 1a or 1b, and the detailed implementation of the steps may refer to the previous description of the functions of the memory controller 10, which is not repeated here.
The embodiment of the present application also provides an apparatus for managing a storage system, referring to fig. 4, the apparatus includes:
the SSD driving module 401 is configured to scan at least one SSD to obtain M attribute sets of the at least one SSD, where each SSD corresponds to at least one attribute set;
the capacity conversion module 402 is configured to construct N virtual SSDs according to the M attribute sets obtained by scanning, where each virtual SSD is constructed according to at least two attribute sets, and the attribute set of each virtual SSD is formed by combining the at least two attribute sets, M is an integer greater than or equal to 2, and N is a positive integer less than M;
and the sending module 403 is configured to report the respective attribute sets of the N virtual SSDs to an application, so that the application accesses the N virtual SSDs according to the attribute sets of the N virtual SSDs.
In one possible implementation, each attribute set includes a storage space size, and the capacity conversion module 402 is specifically configured to: and merging the storage space sizes in the attribute sets, and constructing a virtual SSD according to the at least two attribute sets with the merged storage space sizes reaching a preset capacity.
In one possible implementation, the capacity conversion module 402 is specifically configured to: and constructing a virtual SSD according to the preset number of attribute sets.
In one possible implementation, the apparatus further includes:
a storage module 404, configured to store a mapping between a logical address of each of the virtual SSDs and a physical address in the at least one virtual SSD;
a receiving module 405, configured to obtain a first access request of the application, where the first access request includes a logical address in a first virtual SSD of the N virtual SSDs;
a mapping module 406, configured to determine a physical address of the first SSD in the at least one corresponding to the logical address according to the mapping stored in the storage module; the mapping module 406 may be the same module as the capacity conversion module 402;
the sending module 403 is further configured to send a second access request to the first SSD, where the second access request includes the physical address, and the second access request is the same as the data operation requested by the first access request.
In one possible implementation, the second SSD of the at least one includes a plurality of SSD controllers; the SSD drive module 401 specifically is configured to: scanning the second SSD, and obtaining one attribute set according to scanning of each SSD controller of the second SSD.
The above-described embodiments of the modules of the device for managing a storage system refer to the functions implemented by the storage controller 10 in any one of fig. 1a and 1b, and are not repeated here.
An embodiment of the present application further provides a memory controller, referring to fig. 5, where the memory controller includes a processor 501, a transceiver 502, and a bus 503, and the processor 501 communicates with the transceiver 502 through the bus 503. Transceiver 502 is used to communicate with other network elements in the network, such as multiple SSDs, as well as servers. The processor 501 is configured to implement the functionality of the memory controller of fig. 1a via the transceiver 502, and the embodiments of the processor 501 and the transceiver 502 may be referred to above in the description of the memory controller embodiment of fig. 1 a.
In an embodiment of the present application, the processor 501 may be a processing element, for example, the processor 501 may be a CPU, where the function of the storage controller 10 is implemented by the CPU, for example, scanning the multiple SSDs 20 through a transceiver is implemented, and for example, constructing a virtual SSD according to the attribute set of the SSD20 obtained by the scanning. The processor 501 may also be a generic term for a plurality of processing elements. For example, the processor 501 of the memory controller 10 includes a CPU that performs scanning of the plurality of SSDs 20 through a transceiver, and an ASIC for constructing a virtual SSD from the attribute set of the SSDs 20 obtained by the scanning.
The transceiver may be a wired communication type transceiver, such as an ethernet data transceiver; the transceiver may also be a wireless communication type transceiver, such as a transceiver including an antenna and a radio frequency module coupled to the antenna.
Optionally, the memory controller may further include a memory 504, where the memory 504 is configured to store executable program code or parameters, data, scan obtained SSD20 attribute sets, and the like, required for the memory controller 10 to operate. And the memory may include a random-access memory (RAM) or a non-volatile memory (NVM), etc. Memory 504 in fig. 5 illustrates that memory 504 is not a necessary element to implement the memory controller functionality in embodiments of the present application.
The embodiment of the present application further provides a storage device, which includes at least one SSD and the storage controller in fig. 1b, and the implementation of the storage controller is referred to the implementation of the storage controller 10 in fig. 1b, which is not described in detail herein.
In embodiments of the present application, the memory controller may include 1 or more processors, such as 1 or more CPUs, or 1 or more ASICs, or a combination of CPUs and ASICs. When the memory controller includes a processor, the memory controller functions are implemented by the processor; where the memory controller includes a plurality of processors, each processor implements a portion of the memory controller's functionality.
In one possible implementation, the storage devices in the embodiments of the present application are connected through a network, where the storage controller in each storage device may scan at least one SSD in the present storage device, and may scan SSDs in other storage devices through the network, and construct a virtual SSD according to a set of attributes obtained by scanning SSDs in other storage devices.
It will be appreciated by those skilled in the art that embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
The present application is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems) and computer program products according to embodiments of the application. It will be understood that each flow and/or block of the flowchart illustrations and/or block diagrams, and combinations of flows and/or blocks in the flowchart illustrations and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
It will be apparent to those skilled in the art that various modifications and variations can be made to the present application without departing from the spirit or scope of the application. Thus, it is intended that the present application also include such modifications and alterations insofar as they come within the scope of the appended claims or the equivalents thereof.

Claims (10)

1. A method of managing a storage system, comprising:
scanning at least one SSD in a storage system to obtain M first namespaces; wherein each SSD includes at least one first namespace;
merging the M first namespaces into N second namespaces, wherein M is a positive integer greater than or equal to 2, and N is a positive integer less than M;
and providing the N second namespaces for application use.
2. The method of claim 1, wherein each namespace comprises a plurality of logical blocks, the merging the M first namespaces into N second namespaces comprising:
and merging the logic blocks of the first naming space, and merging the first naming space to which the merged logic block belongs into a second naming space when the size of the merged logic block reaches a preset capacity.
3. The method of claim 1, wherein the merging the M first namespaces into N second namespaces comprises:
a second namespace is constructed based on the preset number of first namespaces.
4. The method of any of claims 1-3, wherein each second namespace corresponds to a virtual SSD, and after merging the M first namespaces into N second namespaces, further comprising:
storing a mapping of a logical address of each of the virtual SSDs to a physical address in the at least one SSD;
the method further comprises the steps of:
obtaining a first access request of the application, wherein the first access request comprises a logic address in a first virtual SSD in the N virtual SSDs;
determining a physical address of a first SSD in the at least one SSD corresponding to the logical address according to the stored mapping;
and sending a second access request to the first SSD, wherein the second access request comprises the physical address, and the second access request is identical to the data operation requested by the first access request.
5. The method of any of claims 1-3, wherein a second SSD of the at least one SSD includes a plurality of SSD controllers; scanning the second SSD to obtain an attribute set of the second SSD, wherein the scanning comprises the following steps:
and scanning and obtaining one attribute set according to each SSD controller of the second SSD.
6. An apparatus for managing a storage system, comprising:
the SSD driving module scans at least one SSD in the storage system to obtain M first namespaces; wherein each SSD includes at least one first namespace;
the capacity conversion module is used for merging the M first namespaces into N second namespaces, wherein M is a positive integer greater than or equal to 2, and N is a positive integer less than M;
and the sending module is used for providing the N second namespaces for the application.
7. The apparatus of claim 6, wherein each namespace comprises a plurality of logical blocks, the capacity conversion module being specifically configured to: and merging the logic blocks of the first naming space, and merging the first naming space to which the merged logic block belongs into a second naming space when the size of the merged logic block reaches a preset capacity.
8. The apparatus of claim 6, wherein the capacity conversion module is specifically configured to:
a second namespace is constructed based on the preset number of first namespaces.
9. The apparatus of any of claims 6 to 8, wherein each second namespace corresponds to a virtual SSD, the apparatus further comprising:
the storage module is used for storing the mapping between the logical address of each virtual SSD and the physical address in the at least one SSD;
the receiving module is used for obtaining a first access request of the application, wherein the first access request comprises logic addresses in a first virtual SSD in N virtual SSDs;
the mapping module is used for determining a physical address of a first SSD in the at least one SSD corresponding to the logical address according to the mapping stored in the storage module;
the sending module is further configured to send a second access request to the first SSD, where the second access request includes the physical address, and the second access request is the same as the data operation requested by the first access request.
10. The apparatus of any of claims 6 to 8, wherein a second SSD of the at least one SSD includes a plurality of SSD controllers; the SSD driving module is specifically used for: and scanning the second SSD, and obtaining an attribute set according to scanning of each SSD controller of the second SSD.
CN201910920051.9A 2016-04-29 2016-04-29 Method and equipment for managing storage system Active CN110851383B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910920051.9A CN110851383B (en) 2016-04-29 2016-04-29 Method and equipment for managing storage system

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201910920051.9A CN110851383B (en) 2016-04-29 2016-04-29 Method and equipment for managing storage system
CN201610281745.9A CN105892955B (en) 2016-04-29 2016-04-29 A kind of method and apparatus managing storage system

Related Parent Applications (1)

Application Number Title Priority Date Filing Date
CN201610281745.9A Division CN105892955B (en) 2016-04-29 2016-04-29 A kind of method and apparatus managing storage system

Publications (2)

Publication Number Publication Date
CN110851383A CN110851383A (en) 2020-02-28
CN110851383B true CN110851383B (en) 2023-08-22

Family

ID=56703115

Family Applications (2)

Application Number Title Priority Date Filing Date
CN201910920051.9A Active CN110851383B (en) 2016-04-29 2016-04-29 Method and equipment for managing storage system
CN201610281745.9A Active CN105892955B (en) 2016-04-29 2016-04-29 A kind of method and apparatus managing storage system

Family Applications After (1)

Application Number Title Priority Date Filing Date
CN201610281745.9A Active CN105892955B (en) 2016-04-29 2016-04-29 A kind of method and apparatus managing storage system

Country Status (1)

Country Link
CN (2) CN110851383B (en)

Families Citing this family (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108614671B (en) * 2016-12-12 2023-02-28 北京忆恒创源科技股份有限公司 Key-data access method based on namespace and solid-state storage device
JP6773229B2 (en) 2016-12-29 2020-10-21 ホアウェイ・テクノロジーズ・カンパニー・リミテッド Storage controller and IO request processing method
CN109799956B (en) 2017-01-05 2023-11-17 华为技术有限公司 Memory controller and IO request processing method
CN113515469A (en) * 2017-03-22 2021-10-19 北京忆恒创源科技股份有限公司 Method for creating and deleting name space and storage device
CN107526548B (en) * 2017-08-31 2020-09-25 苏州浪潮智能科技有限公司 Multi-namespace solid state disk and data deleting method and device
CN109002258A (en) * 2018-06-27 2018-12-14 郑州云海信息技术有限公司 NameSpace distribution method, system and equipment and storage medium in solid state hard disk
CN109491601B (en) * 2018-10-26 2021-11-26 深圳市硅格半导体有限公司 Parallel processing method and device for solid state disk data and readable storage medium
CN110321678B (en) * 2019-06-19 2021-08-31 北京信安世纪科技股份有限公司 Control method, device, equipment and medium of virtual system
US11620083B2 (en) 2021-07-02 2023-04-04 Samsung Electronics Co., Ltd. Method for implementing predictable latency mode feature in SSD, and non-volatile memory (NVM) based storage device

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101387989A (en) * 2008-10-29 2009-03-18 北京世纪红山科技有限公司 Computer system and method for constructing virtual storage device based on sectorization management
CN101681253A (en) * 2007-05-09 2010-03-24 金士顿科技股份有限公司 Secure and scalable solid state disk system
WO2011082653A1 (en) * 2010-01-05 2011-07-14 北京联想软件有限公司 Controller and terminal device used for multi-storages and start-up and access method thereof
WO2012114338A1 (en) * 2011-02-22 2012-08-30 Infinidat Ltd. Cloud storage arrangement and method of operating thereof
CN102830941A (en) * 2012-06-15 2012-12-19 记忆科技(深圳)有限公司 Solid-state hard disk driving method and storage system

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8943270B2 (en) * 2012-07-24 2015-01-27 Hitachi, Ltd. Storage system, storage control method and storage control program
US9323662B2 (en) * 2012-12-31 2016-04-26 SanDisk Technologies, Inc. Flash memory using virtual physical addresses

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101681253A (en) * 2007-05-09 2010-03-24 金士顿科技股份有限公司 Secure and scalable solid state disk system
CN101387989A (en) * 2008-10-29 2009-03-18 北京世纪红山科技有限公司 Computer system and method for constructing virtual storage device based on sectorization management
WO2011082653A1 (en) * 2010-01-05 2011-07-14 北京联想软件有限公司 Controller and terminal device used for multi-storages and start-up and access method thereof
WO2012114338A1 (en) * 2011-02-22 2012-08-30 Infinidat Ltd. Cloud storage arrangement and method of operating thereof
CN102830941A (en) * 2012-06-15 2012-12-19 记忆科技(深圳)有限公司 Solid-state hard disk driving method and storage system

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
连续数据存储中面向RAID5的写操作优化设计;孙志卓;张全新;李元章;谭毓安;刘靖宇;马忠梅;;计算机研究与发展(第08期);全文 *

Also Published As

Publication number Publication date
CN110851383A (en) 2020-02-28
CN105892955A (en) 2016-08-24
CN105892955B (en) 2019-10-18

Similar Documents

Publication Publication Date Title
CN110851383B (en) Method and equipment for managing storage system
US10410693B2 (en) Multiprocessor system with independent direct access to bulk solid state memory resources
US9229826B2 (en) Volatile memory representation of nonvolatile storage device set
US11392571B2 (en) Key-value storage device and method of operating the same
US10503434B2 (en) Scalable low-latency storage interface
CN101477511B (en) Method and apparatus for sharing memory medium between multiple operating systems
US8942072B2 (en) Efficient access to storage devices with usage bitmaps
US10789170B2 (en) Storage management method, electronic device and computer readable medium
US20200192592A1 (en) Storage device and operating method thereof
US11176091B2 (en) Techniques for dynamic multi-storage format database access
US20240143219A1 (en) Software-hardware combination method for internal mapping address query of zoned namespace
US20230236971A1 (en) Memory management method and apparatus
CN108628760B (en) Method and device for atomic write command
CN108628761B (en) Atomic command execution method and device
US20190243779A1 (en) Method and system for operating nand flash physical space to extend memory capacity
US12093174B2 (en) Methods and apparatus for persistent data structures
US8593472B1 (en) System and method for accessing a frame buffer via a storage driver
KR20210085674A (en) Storage device configured to support multi-streams and operation method thereof
US11797183B1 (en) Host assisted application grouping for efficient utilization of device resources
CN111367825A (en) Virtual parity data caching for storage devices

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