WO2017008571A1 - 卷的空间分配方法和装置 - Google Patents

卷的空间分配方法和装置 Download PDF

Info

Publication number
WO2017008571A1
WO2017008571A1 PCT/CN2016/082351 CN2016082351W WO2017008571A1 WO 2017008571 A1 WO2017008571 A1 WO 2017008571A1 CN 2016082351 W CN2016082351 W CN 2016082351W WO 2017008571 A1 WO2017008571 A1 WO 2017008571A1
Authority
WO
WIPO (PCT)
Prior art keywords
volume
space
storage layer
size
allocation
Prior art date
Application number
PCT/CN2016/082351
Other languages
English (en)
French (fr)
Inventor
刘卯银
Original Assignee
中兴通讯股份有限公司
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 中兴通讯股份有限公司 filed Critical 中兴通讯股份有限公司
Publication of WO2017008571A1 publication Critical patent/WO2017008571A1/zh

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F12/00Accessing, addressing or allocating within memory systems or architectures

Definitions

  • This application relates to, but is not limited to, the field of storage technology.
  • a storage system of the related art is a member disk of a RAID (Redundant Arrays of Independent Disks).
  • the storage system of the virtualized resource pool uses a virtual disk, that is, a volume is used as a member disk of the RAID, and the virtual disk is divided into small blocks for address mapping, so that more small virtual disks and small virtual disks are interposed. Establish a RAID relationship network.
  • Virtualized pool storage systems typically have tens to hundreds of member disks. When the storage system has a disk failure. The disk reconstruction performance of the related art RAID storage system is limited by the performance of the hot spare disk. In the virtualized pool storage system, when the disk fails, the recovery speed of the virtualized pool storage system is much faster than that of the related art RAID storage system.
  • the virtualized pool storage system may divide the virtual disk into small blocks, so that the original consecutive address access may become random access.
  • the I/O input/output, input/output port
  • the partition of the disk block is small, the continuity of the reconstructed I/O is reduced, so that the reconstruction is performed. The performance of I/O is degraded.
  • a method for solving the above problem in the related art is to increase the division of the disk block, and increasing the size of the disk block can reduce the probability that the sequential I/O becomes random I/O, but increasing the disk block will bring
  • the problem of hotspot migration is that the larger the disk block of the hotspot migration, the less accurate the control of the hotspot will be, and the overall hotspot migration effect will be worse.
  • This paper provides a method and device for spatial allocation of volumes, which solves the technical problem that the sequential access I/O performance is poor and cannot balance the hotspot migration effect.
  • a space allocation method for a volume comprising:
  • a corresponding space is allocated to the volume in each storage layer.
  • the volume that is calculated according to the calculation occupies a space size of each storage layer, and allocates a corresponding space to the volume in each storage layer, including:
  • the method further includes:
  • the storage layer After the space of one of the storage layers is allocated, the storage layer is re-established, or a new space is allocated to the storage layer;
  • a corresponding space is allocated to the volume in each storage layer according to the size of the CK.
  • the method further includes:
  • the resources in the resource pool are migrated with CK as the hotspot migration granularity.
  • the volume to an address mapping table in the resource pool also includes:
  • the method further includes:
  • the volume that is calculated according to the calculation occupies a space size of each storage layer, and allocates a corresponding space to the volume in each storage layer, including:
  • a volume space distribution device comprising:
  • Get the module set to: get the space size of the volume to be created;
  • a calculation module configured to: calculate, according to a preset allocation policy and a space size of the volume acquired by the acquiring module, a size of a space of each storage layer in the volume occupied resource pool;
  • the allocation module is configured to allocate a corresponding space to the volume in each storage layer according to the space size of each storage layer occupied by the volume calculated by the calculation module.
  • the allocation module includes:
  • a dividing unit configured to: divide the volume into a size of an allocation granularity AS;
  • a first allocation unit configured to allocate a corresponding space to the volume in each storage layer according to the size of the AS divided by the dividing unit;
  • the establishing unit is configured to: establish an address mapping table of the volume to the resource pool according to an address mapping granularity CK, where the AS is an integer multiple of the CK.
  • the allocating module further includes:
  • a processing unit configured to: after the space of one of the storage layers is allocated, re-establish the storage layer, or allocate a new space to the storage layer;
  • a detecting unit configured to: re-establish the storage layer or allocate a new space to the storage When the reservoir fails, detecting whether there is unallocated CK in the AS of the storage layer;
  • the second allocation unit is configured to: if there is an unallocated CK in the AS of the storage layer, allocate a corresponding space to the volume in each storage layer according to the size of the CK.
  • the allocating module further includes a migration unit, configured to: when the instruction of the hotspot migration is detected, use CK as the hotspot migration granularity to migrate the resources in the resource pool.
  • a migration unit configured to: when the instruction of the hotspot migration is detected, use CK as the hotspot migration granularity to migrate the resources in the resource pool.
  • the allocating module further includes: a starting unit, configured to: when the disk in the storage layer fails, start multiple ASs in parallel according to the number of disks in the storage layer and the disk array parameters Rebuild the operation of the I/O of the input and output ports.
  • a starting unit configured to: when the disk in the storage layer fails, start multiple ASs in parallel according to the number of disks in the storage layer and the disk array parameters Rebuild the operation of the I/O of the input and output ports.
  • the space allocation device of the volume further includes a determining module, configured to: determine whether a solid state hard disk exists in the resource pool;
  • the allocation module is further configured to: when the determining module determines that the solid state hard disk exists in the resource pool, divide the volume in the corresponding storage layer of the solid state hard disk into a size of CK, according to the size of the CK A corresponding space is allocated to the volume in the solid state hard disk, and an address mapping table of the volume to the resource pool is established according to CK.
  • the space allocation method and device for a volume provided by the embodiment of the present invention allocates a corresponding space to the volume in each storage layer by calculating the size of the space occupied by each volume in the resource pool, so that the volume can be By utilizing the performance of multiple physical disks in the resource pool, the continuous access of the I/O on the volume can be effectively converted into continuous access on the storage layer disk by allocating a large contiguous space AS, reducing the head rotation to the disk. The effect of performance improves the performance of sequential access I/O.
  • the AS is cut into multiple CKs to establish an address mapping table, thereby taking into account the effect of hotspot migration.
  • FIG. 1 is a schematic flowchart of a first embodiment of a method for allocating a volume of a volume according to an embodiment of the present invention
  • FIG. 2 is a schematic flowchart of a second embodiment of a method for allocating space of a volume according to an embodiment of the present invention
  • FIG. 3 is a schematic flowchart of a third embodiment of a method for allocating a volume of a volume according to an embodiment of the present invention
  • FIG. 4 is a schematic flowchart of a fourth embodiment of a method for allocating space of a volume according to an embodiment of the present invention
  • FIG. 5 is a schematic diagram of functional modules of a first embodiment of a space allocation device according to an embodiment of the present invention.
  • FIG. 6 is a schematic diagram of functional modules of a second embodiment of a space allocation device according to an embodiment of the present invention.
  • FIG. 7 is a schematic diagram of functional modules of a third embodiment of a space allocation apparatus according to an embodiment of the present invention.
  • FIG. 8 is a schematic diagram of functional modules of a fourth embodiment of a space allocation device according to an embodiment of the present invention.
  • the main solution of the embodiment of the present invention is: obtaining a space size of a volume to be created; calculating a space size of each storage layer in the volume occupied resource pool according to the space size of the volume and a preset allocation policy; The calculated volume occupies a space size of each storage layer, and a corresponding space is allocated to the volume in each storage layer.
  • the corresponding space is allocated to the volume in each storage layer, so that the volume can utilize the performance of multiple storage layers in the resource pool, by assigning a larger Continuous space AS realizes that I/O continuous access on the volume can be effectively converted into continuous access on the disk, reducing the impact of head rotation on the performance of the disk, improving the performance of sequential access I/O, and by setting
  • the small mapping granularity CK is used to cut the AS into multiple CKs to establish an address mapping table, thereby taking into account the effect of hotspot migration.
  • an embodiment of the present invention provides a space allocation method for a volume.
  • FIG. 1 is a schematic flowchart diagram of a first embodiment of a space allocation method of a volume according to an embodiment of the present invention.
  • the volume allocation method of the volume may include steps S10 to S30:
  • Step S10 obtaining a space size of the volume to be created
  • Step S20 Calculate, according to the space size of the volume and a preset allocation policy, a space size of each storage layer in the volume occupied resource pool;
  • the virtualized resource pool pool storage system obtains the space size of the volume to be created by the user, and calculates the volume according to the space size of the volume and the allocation policy preset by the user.
  • the size of the space of each storage layer is occupied in the resource pool (hereinafter referred to as "pool"), and the size of the space occupied by each volume by the volume is obtained.
  • the volume layer to the pool layer of the storage array of the virtualized pool storage system has a mapping of an address space (when the volume is a thin volume, in addition to the mapping, there is a mapping of a thin volume.
  • Thin volume refers to a volume with automatic thin provisioning.
  • the thin provisioning is a storage management feature.
  • the core principle is to "spoof" the client operating system, so that the client operating system thinks that a large logical resource has been allocated. For example, the client operating system sees a 2TB (terabyte, terabyte) logical resource, but in fact, the network storage device only allocates tens or hundreds of GB (gigabytes) of physical space for this resource. The rest of the space is virtual. As the application writes more and more data, the physical storage utilization will be higher and higher. When the actual allocated physical space is insufficient, additional physical space will be allocated. Need to expand). There are three levels in the pool, namely tier0, tier1, tier2.
  • the tier0 level is SSD (Solid State Drives)
  • the tier1 level is SAS (Serial Attached SCSI, Serial Attached SCSI interface, SCSI (Small Computer System Interface))
  • tier2 is SATA ( Serial ATA, serial hard drive).
  • the preset allocation policy is tier0
  • the volume allocation of the tier1 and tier2 level storage pools in the pool is 2:3.
  • the virtualized pool storage system calculates, according to the preset allocation policy, that the volume of the SSD in the pool is 20 GB, the space in the SAS is 30 GB, and the space in the SATA is 50 GB. .
  • Step S30 according to the calculated size of the volume occupied by each volume of the storage layer, in each A corresponding space is allocated to the volume in the storage layer.
  • the virtualized pool storage system allocates a corresponding space to the volume in each storage layer according to the calculated volume occupied by the volume occupying each storage layer in the pool.
  • the virtualized pool storage system allocates 20 GB of space to the volume in the SSD in the pool according to the size of the SSD, SAS and SATA internal space in the pool, and the volume in the pool.
  • a 30 GB space is allocated to the volume in the SAS, and 50 GB of space is allocated to the volume in the SATA in the pool.
  • a corresponding space is allocated to the volume in each storage layer, so that the volume can utilize the performance of multiple physical disks in the resource pool.
  • Allocating a large contiguous space AS to achieve continuous access of the I/O on the volume can be effectively converted into continuous access on the storage tier disk, reducing the impact of head rotation on the performance of the disk, and improving sequential access I/O.
  • Performance at the same time, by setting a smaller mapping granularity CK, the AS is cut into multiple CKs to establish an address mapping table, thereby taking into account the effect of hotspot migration.
  • FIG. 2 is a schematic flowchart diagram of a second embodiment of a space allocation method of a volume according to an embodiment of the present invention, and a second embodiment of a space allocation method of a volume according to an embodiment of the present invention is proposed based on the first embodiment.
  • the step S30 includes steps S31 to S37:
  • Step S31 dividing the volume into a size of an allocation granularity AS
  • Step S32 allocating a corresponding space to the volume in each storage layer according to the size of the AS;
  • the virtualized pool storage system occupies a space size of each storage layer according to the calculated volume.
  • the volume is in each storage layer in the pool.
  • the size of the space is divided into the size of the AS (Alloc Size), and the corresponding space is allocated to the volume in the RAID group of the disk array according to the size of the AS.
  • Step S33 after the space of one of the storage layers is allocated, re-establish the storage layer, or allocate a new space to the storage layer;
  • Step S34 when the storage layer is re-established or a new space is allocated to the storage layer, the storage layer fails. At the time of detecting whether there is unallocated CK in the AS of the storage layer;
  • step S35 if there is an unallocated CK in the AS of the storage layer, a corresponding space is allocated to the volume in each storage layer according to the size of the CK.
  • the RAID group of the storage layer is newly created or a new physical medium is allocated from other storage layers in the pool.
  • the space expands the RAID group of the storage layer.
  • the virtualized pool storage system allocates a RAID group space in the storage layer in the pool to the volume.
  • the virtualized pool storage system checks whether there is an unallocated CK in the AS in the RAID group of the allocated storage layer from the beginning, when the AS memory is used.
  • space is allocated to the volume at a granularity of CK; if the CK in the AS has been allocated, it indicates that the space allocation of the storage layer fails.
  • the virtualization pool storage system selects a RAID group allocated from another storage layer in the pool to the RAID layer of the storage layer according to an allocation policy set by the user, or prompts the user to space in the RAID group of the storage layer. The allocation failed, ie the volume creation failed.
  • Step S36 Establish an address mapping table of the volume to the resource pool according to an address mapping granularity CK, where the AS is an integer multiple of the CK.
  • the address mapping table of the CK in the volume to the CK in the pool is established according to CK (chunk, address mapping granularity).
  • the AS is an integer multiple of the CK.
  • an AS can consist of 4 CKs.
  • the ID (identification) of the CK in the volume corresponds to the ID of the CK in the pool.
  • the virtualized pool storage system allocates space from the RAID groups of different storage tiers in the pool through the volume, so that the volume can utilize the performance of multiple physical disks in the pool.
  • the AS is not set too large, and the AS is set to a size of a RAID group composed of small blocks divided on physical disks in the pool.
  • step S37 when the hot spot migration instruction is detected, the resources in the resource pool are migrated by using CK as the hotspot migration granularity.
  • the CK is used as the hotspot migration granularity to migrate the resources in the pool. For example, when the virtualized pool storage system reads and writes data, and finds that some data in the SAS in the pool is used frequently, the frequently used data is migrated into the SSD at the CK granularity.
  • the SAS migration in the virtualized pool storage system pool may result in a hole in the AS, when the SAS cannot allocate space to the volume according to the AS, the CK of the intra-AS hole is selected to be allocated. Space is given to the volume.
  • the space allocation method of the volume of the embodiment by calculating the space allocation ratio of each storage layer in the resource pool, allocating the space in the storage layer to the corresponding volume according to the AS, and establishing the volume according to CK to the An address mapping table within the resource pool.
  • the use of the size of the AS for space allocation, the use of CK for hotspot migration, while maintaining a small granularity migration, improves the performance of sequential I / O access.
  • FIG. 3 is a schematic flowchart diagram of a third embodiment of a space allocation method according to an embodiment of the present invention, and a third embodiment of a space allocation method for a volume in an embodiment of the present invention is proposed based on a second embodiment. .
  • This embodiment is based on the space allocation method of the volume shown in FIG. 2, and after the step S36, the method further includes:
  • step S38 when the disk in the storage layer fails, the multiple ASs are simultaneously started to perform the operation of rebuilding the I/O according to the number of disks in the storage layer and the disk array parameters.
  • the virtualized pool storage system needs to rebuild the I/O, and the reconstructed I/O is sequential I/O.
  • the ASs in the plurality of RAID groups in the storage layer of the pool can be concurrently performed. .
  • the number of concurrent ASs depends on the number of disks in the storage tier in the pool and the RAID parameters in the disk.
  • the number of concurrent I/Os of the disk reconstruction is 4, that is, each The ASs are internally scheduled to re-establish I/O, similar to the sequential flow of multiple channels.
  • the number of concurrent I/Os is also limited based on how busy the host I/O is.
  • FIG. 4 is a schematic flowchart diagram of a fourth embodiment of a space allocation method of a volume according to an embodiment of the present invention, and a fourth embodiment of a space allocation method for a volume in an embodiment of the present invention is proposed based on the first embodiment. .
  • the embodiment is based on the space allocation method of the volume shown in FIG. 1 , and after the step S20, the method further includes:
  • Step S40 determining whether a solid state hard disk exists in the resource pool
  • the step S30 may be: dividing the volume in the storage layer corresponding to the SSD into a size of the CK, and allocating a corresponding space in the SSD according to the size of the CK.
  • the volume establishes an address mapping table of the volume to the resource pool according to CK.
  • the virtualized pool storage system determines whether there is an SSD in the storage layer in the pool.
  • the CK may be used as the granularity.
  • a storage layer that does not have an SSD performs spatial allocation at a granularity of AS.
  • the virtualized pool storage system divides the space on the volume into the size of the CK, a space of CK size is allocated from the SSD to the volume.
  • the virtualized pool storage system creates a RAID group in the SSD, or allocates a new physical space from other storage layers in the pool to the The RAID group of the SSD is expanded.
  • the virtualized pool storage system allocates a CK size space of the RAID group in the SSD in the pool to the volume.
  • the virtualization pool storage system selects a RAID group that allocates space from other storage tiers in the pool to the SSD according to an allocation policy set by the user, or prompts The space allocation in the RAID group of the SSD of the user fails, that is, the volume creation fails.
  • the space in the SSD layer disk array group is allocated to the corresponding volume according to CK. It realizes the performance of sequential I/O access while maintaining a small granularity migration while the pool of the virtualized pool storage system is in the SSD.
  • Embodiments of the present invention also provide a space allocation device for a roll.
  • FIG. 5 is a diagram showing the function of a first embodiment of a space allocating device according to an embodiment of the present invention. Module schematic.
  • the space allocation device of the volume includes:
  • the obtaining module 10 is configured to: obtain a space size of the volume to be created;
  • the calculating module 20 is configured to calculate, according to a preset allocation policy and a space size of the volume acquired by the acquiring module 10, a spatial size of each storage layer in the volume occupied resource pool;
  • the virtualized pool storage system obtains the size of the space of the volume to be created by the user, and calculates the size of the space occupied by the volume in the pool according to the size of the volume and the allocation policy preset by the user. Get the size of the space occupied by the volume for each storage layer.
  • the volume layer to the pool layer of the storage array of the virtualized pool storage system has a mapping of an address space (when the volume is a thin volume, in addition to the mapping, there is a mapping of a thin volume.
  • the thin volume is Refers to the volume with the thin provisioning function.
  • the thin provisioning is a storage management feature.
  • the core principle is to "spoof" the client operating system, so that the client operating system thinks that a large logical resource has been allocated, such as a client.
  • the operating system sees a 2TB (terabyte, terabyte) logical resource. In fact, only tens or hundreds of GB (Gigabyte) physical space is allocated to the resource on the network storage device. All are virtual. As the application writes more and more data, the physical storage utilization will be higher and higher. When the actual allocated physical space is insufficient, additional physical space will be allocated and expanded as needed. . There are three levels in the pool, namely tier0, tier1, tier2. The tier0 level is SSD (Solid State Drives), the tier1 level is SAS (Serial Attached SCSI), and the tier2 level is SATA (Serial ATA).
  • SSD Solid State Drives
  • SAS Serial Attached SCSI
  • SATA Serial ATA
  • the virtualized pool storage system calculates, according to the preset allocation policy, that the volume of the SSD in the pool is 20 GB, the space in the SAS is 30 GB, and the space in the SATA is 50 GB. .
  • the distribution module 30 is configured to allocate a corresponding space to the volume in each storage layer according to the size of the space occupied by the volume calculated by the calculation module 20 for each storage layer.
  • the virtualized pool storage system allocates a corresponding space to the volume in each storage layer according to the calculated volume occupied by the volume occupying each storage layer in the pool.
  • SAS and SATA internal space of the volume in the pool 20 GB of space is allocated to the volume in the SSD in the pool, 30 GB of space is allocated to the volume in the SAS in the pool, and 50 GB of space is allocated to the volume in the SATA in the pool.
  • a corresponding space is allocated to the volume in each storage layer, so that the volume can utilize the performance of multiple physical disks in the resource pool.
  • Allocating a large contiguous space AS to achieve continuous access of the I/O on the volume can be effectively converted into continuous access on the storage tier disk, reducing the impact of head rotation on the performance of the disk, and improving sequential access I/O.
  • Performance at the same time, by setting a smaller mapping granularity CK, the AS is cut into multiple CKs to establish an address mapping table, thereby taking into account the effect of hotspot migration.
  • FIG. 6 is a schematic diagram of functional modules of a second embodiment of a space allocation device according to an embodiment of the present invention, and a second implementation of a space allocation device for a volume according to an embodiment of the present invention is proposed based on the first embodiment. example.
  • the distribution module 30 further includes:
  • the dividing unit 31 is configured to: divide the volume into a size of an allocation granularity AS;
  • the first allocating unit 32 is configured to: allocate a corresponding space to the volume in each storage layer according to the size of the AS divided by the dividing unit 31;
  • the virtualized pool storage system occupies a space size of each storage layer according to the calculated volume.
  • the volume is in each storage layer in the pool.
  • the size of the space is divided into the size of the AS (Alloc Size), and the corresponding space is allocated to the volume in the RAID group of the disk array according to the size of the AS.
  • the processing unit 33 is configured to: after the space of one of the storage layers is allocated, re-establish the storage layer, or allocate a new space to the storage layer;
  • the detecting unit 34 is configured to: when the storage layer is re-established or a new space is allocated to the storage layer, detecting whether there is an unallocated CK in the AS of the storage layer;
  • the second allocating unit 35 is configured to allocate a corresponding space to the volume in each storage layer according to the size of the CK if there is an unallocated CK in the AS of the storage layer.
  • the RAID group of the storage layer is newly created or a new physical medium is allocated from other storage layers in the pool.
  • the space expands the RAID group of the storage layer.
  • the virtualized pool storage system allocates a RAID group space in the storage layer in the pool to the volume.
  • the virtualized pool storage system checks whether there is an unallocated CK in the AS in the RAID group of the allocated storage layer from the beginning, when the AS memory is used.
  • space is allocated to the volume at a granularity of CK; if the CK in the AS has been allocated, it indicates that the space allocation of the storage layer fails.
  • the virtualization pool storage system selects a RAID group allocated from another storage layer in the pool to the RAID layer of the storage layer according to an allocation policy set by the user, or prompts the user to space in the RAID group of the storage layer. The allocation failed, ie the volume creation failed.
  • the establishing unit 36 is configured to: establish an address mapping table of the volume to the resource pool according to an address mapping granularity CK, where the AS is an integer multiple of the CK.
  • the address mapping table of the CK in the volume to the CK in the pool is established according to CK (chunk, address mapping granularity).
  • the AS is an integer multiple of the CK.
  • an AS can consist of 4 CKs.
  • the ID (identification) of the CK in the volume corresponds to the ID of the CK in the pool.
  • the virtualized pool storage system allocates space from the RAID groups of different storage tiers in the pool through the volume, so that the volume can utilize the performance of multiple physical disks in the pool.
  • the AS is not set too large, and the AS is set to a size of a RAID group composed of small blocks divided on physical disks in the pool.
  • the migration unit 37 is configured to: when the hot spot migration instruction is detected, migrate the resources in the resource pool with the CK as the hotspot migration granularity.
  • the CK is used as the hotspot migration granularity to migrate the resources in the pool. For example, when the virtualized pool storage system reads and writes data, and finds that some data in the SAS in the pool is used frequently, These frequently used data are migrated into the SSD at the CK granularity.
  • the SAS migration in the virtualized pool storage system pool may result in a hole in the AS, when the SAS cannot allocate space to the volume according to the AS, the CK of the intra-AS hole is selected to be allocated. Space is given to the volume.
  • the space allocation device of the volume of the embodiment allocates the space in the storage layer to the corresponding volume according to the AS by calculating the space allocation ratio of each storage layer in the resource pool, and establishes the volume according to CK to the An address mapping table within the resource pool.
  • the use of the size of the AS for space allocation, the use of CK for hotspot migration, while maintaining a small granularity migration, improves the performance of sequential I / O access.
  • FIG. 7 is a schematic diagram of functional modules of a third embodiment of a space allocation device according to an embodiment of the present invention, and a third implementation of a space allocation device for a volume according to an embodiment of the present invention is proposed based on a second embodiment. example.
  • the distribution module 30 further includes:
  • the booting unit 38 is configured to: when the disk in the storage layer fails, start multiple ASs to perform the operation of rebuilding the I/O in parallel according to the number of disks in the storage layer and the disk array parameters.
  • the virtualized pool storage system needs to rebuild the I/O, and the reconstructed I/O is sequential I/O.
  • the ASs in the plurality of RAID groups in the storage layer of the pool can be concurrently performed. .
  • the number of concurrent ASs depends on the number of disks in the storage tier in the pool and the RAID parameters in the disk.
  • the number of concurrent I/Os of the disk reconstruction is 4, that is, each The ASs are internally scheduled to re-establish I/O, similar to the sequential flow of multiple channels.
  • the number of concurrent I/Os is also limited based on how busy the host I/O is.
  • FIG. 8 is a schematic diagram of functional modules of a fourth embodiment of a space allocation device according to an embodiment of the present invention, and a fourth implementation of a space allocation device for a volume according to an embodiment of the present invention is proposed based on the first embodiment. example.
  • the present embodiment is based on the structure of the space distribution device of the roll shown in FIG. 5, and the space allocation device of the roll further includes:
  • the determining module 40 is configured to: determine whether a solid state hard disk exists in the resource pool;
  • the allocating module 30 is further configured to: divide the volume in the corresponding storage layer of the solid state hard disk into a size of CK, and according to the size of the CK in the solid state hard disk A corresponding space is allocated to the volume, and an address mapping table of the volume to the resource pool is established according to CK.
  • the virtualized pool storage system determines whether there is an SSD in the storage layer in the pool.
  • the CK may be used as the granularity.
  • a storage layer that does not have an SSD performs spatial allocation at a granularity of AS.
  • the virtualized pool storage system divides the space on the volume into the size of the CK, a space of CK size is allocated from the SSD to the volume.
  • the virtualized pool storage system creates a RAID group in the SSD, or allocates a new physical space from other storage layers in the pool to the The RAID group of the SSD is expanded.
  • the virtualized pool storage system allocates a CK size space of the RAID group in the SSD in the pool to the volume.
  • the virtualization pool storage system selects a RAID group that allocates space from other storage tiers in the pool to the SSD according to an allocation policy set by the user, or prompts The space allocation in the RAID group of the SSD of the user fails, that is, the volume creation fails.
  • the space in the SSD layer disk array group is allocated to the corresponding volume according to CK. It realizes the performance of sequential I/O access while maintaining a small granularity migration while the pool of the virtualized pool storage system is in the SSD.
  • all or part of the steps of the above embodiments may also be implemented by using an integrated circuit. These steps may be separately fabricated into individual integrated circuit modules, or multiple modules or steps may be fabricated into a single integrated circuit module. achieve.
  • the devices/function modules/functional units in the above embodiments may be implemented by a general-purpose computing device, which may be centralized on a single computing device or distributed over a network of multiple computing devices.
  • the device/function module/functional unit in the above embodiment When the device/function module/functional unit in the above embodiment is implemented in the form of a software function module and sold or used as a stand-alone product, it can be stored in a computer readable storage medium.
  • the above mentioned computer readable storage medium may be a read only memory, a magnetic disk or an optical disk or the like.
  • a corresponding space is allocated to the volume in each storage layer, so that the volume can utilize the performance of multiple physical disks in the resource pool.
  • I/O continuous access on the volume can be effectively converted into continuous access on the storage tier disk, reducing the impact of head rotation on the performance of the disk, and improving sequential access I/O.
  • the performance of the hotspot migration is achieved by setting the smaller mapping granularity CK and cutting the AS into multiple CKs to establish an address mapping table.

Landscapes

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

Abstract

一种卷的空间分配方法和装置,该方法包括:获取待创建的卷的空间大小;根据所述卷的空间大小和预设的分配策略,计算所述卷占用资源池中每个存储层的空间大小;根据计算得到的所述卷占用每个存储层的空间大小,在每个存储层中分配对应的空间给所述卷。

Description

卷的空间分配方法和装置 技术领域
本申请涉及但不限于存储技术领域。
背景技术
相关技术的存储系统是以物理磁盘作为RAID(Redundant Arrays of Independent Disks,磁盘阵列)成员盘,一般组成RAID的成员盘数是个位数级别。虚拟化资源池(pool)的存储系统使用虚拟磁盘,即使用卷作为RAID的成员盘,通过将虚拟磁盘划分成小块进行地址映射,让更多的小块虚拟磁盘和小块虚拟磁盘之间建立RAID关系网。虚拟化pool存储系统一般有数十到上百个成员盘。当存储系统有磁盘发生故障的时候。相关技术的RAID存储系统的磁盘重建性能会受限于热备磁盘的性能。而虚拟化pool存储系统在磁盘发生故障时,虚拟化pool的存储系统的恢复速度远大于相关技术的RAID存储系统。
相对于相关技术的RAID存储系统,虚拟化pool存储系统因为将虚拟磁盘划分成了小块,使原本连续的地址访问有可能会变成随机访问。然而当发生故障时,需要重建的I/O(input/output,输入输出端口)就是典型的顺序I/O,当所述磁盘块划分的较小时,重建I/O的连续性降低,使得重建I/O的性能降低。
发明内容
以下是对本文详细描述的主题的概述。本概述并非是为了限制权利要求的保护范围。
相关技术中解决上述问题的方法为增大对所述磁盘块的划分,增大所述磁盘块的大小虽然可以减少顺序I/O变成随机I/O的概率,但是增大磁盘块会带来热点迁移的问题,热点迁移的磁盘块越大,对热点的把控就会越不准确,使得整体的热点迁移效果变差。
本文提供一种卷的空间分配方法和装置,解决顺序访问I/O性能差,且不能兼顾热点迁移效果的技术问题。
一种卷的空间分配方法,包括:
获取待创建的卷的空间大小;
根据所述卷的空间大小和预设的分配策略,计算所述卷占用资源池中每个存储层的空间大小;
根据计算得到的所述卷占用每个存储层的空间大小,在每个存储层中分配对应的空间给所述卷。
可选地,所述根据计算得到的所述卷占用每个存储层的空间大小,在每个存储层中分配对应的空间给所述卷,包括:
将所述卷划分成分配粒度AS的大小;
根据所述AS的大小在每个存储层中分配对应的空间给所述卷;
根据地址映射粒度CK建立所述卷到所述资源池的地址映射表,所述AS是所述CK的整数倍。
可选地,所述根据所述AS的大小在每个存储层中分配对应的空间给所述卷之后,还包括:
当其中一个存储层的空间分配完之后,重新建立所述存储层,或者分配新的空间给所述存储层;
当重新建立所述存储层或者分配新的空间给所述存储层失败时,检测所述存储层的AS内是否有未分配的CK;
若所述存储层的AS内有未分配的CK,根据所述CK的大小在每个存储层中分配对应的空间给所述卷。
可选地,所述根据CK建立所述卷到所述资源池内的地址映射表之后,还包括:
当侦测到热点迁移的指令时,以CK作为热点迁移的粒度对资源池内的资源进行迁移。
可选地,所述根据CK建立所述卷到所述资源池内的地址映射表之后, 还包括:
当所述存储层中的磁盘出现故障时,根据所述存储层中磁盘的个数和磁盘阵列参数,同时启动多个AS并行执行重建输入输出端口I/O的操作。
可选地,所述根据所述卷的空间大小和预设的分配策略,计算所述卷占用资源池中每个存储层的空间大小之后,还包括:
判断所述资源池中是否存在固态硬盘;
若所述资源池中存在固态硬盘,所述根据计算得到的所述卷占用每个存储层的空间大小,在每个存储层中分配对应的空间给所述卷,包括:
将所述固态硬盘对应存储层中的卷划分成CK的大小,根据所述CK的大小在固态硬盘中分配对应的空间给所述卷,根据CK建立所述卷到所述资源池的地址映射表。
一种卷的空间分配装置,包括:
获取模块,设置为:获取待创建的卷的空间大小;
计算模块,设置为:根据预设的分配策略和所述获取模块获取的所述卷的空间大小,计算所述卷占用资源池中每个存储层的空间大小;
分配模块,设置为:根据所述计算模块计算得到的所述卷占用每个存储层的空间大小,在每个存储层中分配对应的空间给所述卷。
可选地,所述分配模块包括:
划分单元,设置为:将所述卷划分成分配粒度AS的大小;
第一分配单元,设置为:根据所述划分单元划分出的AS的大小在每个存储层中分配对应的空间给所述卷;
建立单元,设置为:根据地址映射粒度CK建立所述卷到所述资源池的地址映射表,所述AS是所述CK的整数倍。
可选地,所述分配模块还包括:
处理单元,设置为:当其中一个存储层的空间分配完之后,重新建立所述存储层,或者分配新的空间给所述存储层;
检测单元,设置为:当重新建立所述存储层或者分配新的空间给所述存 储层失败时,检测所述存储层的AS内是否有未分配的CK;
第二分配单元,设置为:若所述存储层的AS内有未分配的CK,根据所述CK的大小在每个存储层中分配对应的空间给所述卷。
可选地,所述分配模块还包括迁移单元,设置为:当侦测到热点迁移的指令时,以CK作为热点迁移的粒度对资源池内的资源进行迁移。
可选地,所述分配模块还包括启动单元,设置为:当所述存储层中的磁盘出现故障时,根据所述存储层中磁盘的个数和磁盘阵列参数,同时启动多个AS并行执行重建输入输出端口I/O的操作。
可选地,所述卷的空间分配装置还包括判断模块,设置为:判断所述资源池中是否存在固态硬盘;
所述分配模块,还设置为:在所述判断模块判断出所述资源池中存在固态硬盘时,将所述固态硬盘对应存储层中的卷划分成CK的大小,根据所述CK的大小在固态硬盘中分配对应的空间给所述卷,根据CK建立所述卷到所述资源池的地址映射表。
本发明实施例提供的卷的空间分配方法和装置,通过计算卷在资源池中占用每个存储层的空间大小,在每个存储层中分配对应的空间给所述卷,使所述卷能够利用资源池内多个物理磁盘的性能,通过分配较大的连续空间AS来实现了I/O在卷上的连续访问能够有效的转换成在存储层磁盘上的连续访问,减少磁头转动对磁盘的性能的影响,提高顺序访问I/O的性能,同时通过设置较小的映射粒度CK,将所述AS切成多个CK来建立地址映射表,进而兼顾热点迁移的效果。
在阅读并理解了附图和详细描述后,可以明白其他方面。
附图概述
图1为本发明实施例卷的空间分配方法的第一实施例的流程示意图;
图2为本发明实施例卷的空间分配方法的第二实施例的流程示意图;
图3为本发明实施例卷的空间分配方法的第三实施例的流程示意图;
图4为本发明实施例卷的空间分配方法的第四实施例的流程示意图;
图5为本发明实施例卷的空间分配装置的第一实施例的功能模块示意图;
图6为本发明实施例卷的空间分配装置的第二实施例的功能模块示意图;
图7为本发明实施例卷的空间分配装置的第三实施例的功能模块示意图;
图8为本发明实施例卷的空间分配装的置第四实施例的功能模块示意图。
本发明的实施方式
下文中将结合附图对本发明的实施方式进行详细说明。需要说明的是,在不冲突的情况下,本文中的实施例及实施例中的特征可以相互任意组合。
在附图的流程图示出的步骤可以在诸如一组计算机可执行指令的计算机系统中执行。并且,虽然在流程图中示出了逻辑顺序,但是在某些情况下,可以以不同于此处的顺序执行所示出或描述的步骤。
应当理解,此处所描述的实施例仅仅用以解释本发明,并不用于限定本发明。
本发明实施例的主要解决方案是:获取待创建的卷的空间大小;根据所述卷的空间大小和预设的分配策略,计算所述卷占用资源池中每个存储层的空间大小;根据计算得到的所述卷占用每个存储层的空间大小,在每个存储层中分配对应的空间给所述卷。通过计算卷在资源池占用每个存储层的空间大小,在每个存储层中分配对应的空间给所述卷,使所述卷能够利用资源池内多个存储层的性能,通过分配较大的连续空间AS来实现了I/O在卷上的连续访问能够有效的转换成在磁盘上的连续访问,减少磁头转动对磁盘的性能的影响,提高顺序访问I/O的性能,同时通过设置较小的映射粒度CK,将所述AS切成多个CK来建立地址映射表,进而兼顾热点迁移的效果。
由于相关技术的存储系统在重建I/O时连续性较低,使得重建的性能降低,且热点迁移的整体效果不佳。
基于上述问题,本发明实施例提供一种卷的空间分配方法。
参照图1,图1为本发明实施例卷的空间分配方法的第一实施例的流程示意图。
在本实施例中,所述卷的空间分配方法可以包括步骤S10~步骤S30:
步骤S10,获取待创建的卷的空间大小;
步骤S20,根据所述卷的空间大小和预设的分配策略,计算所述卷占用资源池中每个存储层的空间大小;
虚拟化资源池pool存储系统(以下称为:虚拟化pool存储系统)获取其用户指定待创建的卷的空间大小,根据所述卷的空间大小和其用户预设的分配策略,计算所述卷在所述资源池(以下称为:pool)中占用每个存储层的空间大小,得到所述卷占用每个存储层的空间大小。所述虚拟化pool存储系统的存储阵列的卷(volume)层到pool层有一层地址空间的映射(当卷为thin卷时,除了所述映射外,还会有一层thin卷的映射。所述thin卷是指有自动精简配置功能的卷。所述自动精简配置是一种存储管理的特性,核心原理是“欺骗”客户端操作系统,让客户端操作系统认为已经分配了很大逻辑资源,比如客户端操作系统看到一个2TB(terabyte,太字节)的逻辑资源,而实际上网络存储设备上只为这个资源分配了几十或者几百GB(Gigabyte,十亿字节)的物理空间,其余空间都是虚拟出来的。随着应用程序写入越来越多的数据,物理存储利用率也会越来越高,当实际分配的物理空间不足时,再分配额外的物理空间,随需扩展)。所述pool内有三个层级,分别为tier0,tier1,tier2。所述tier0级为SSD(Solid State Drives,固态硬盘),tier1级为SAS(Serial Attached SCSI,串行连接SCSI接口,其中SCSI(Small Computer System Interface,小型计算机系统接口)),tier2级为SATA(Serial ATA,串口硬盘)。如当所述虚拟化pool存储系统用户定义所述卷的空间为100GB,所述预设的分配策略为tier0,tier1和tier2层级的卷在所述pool内存储层的空间分配比例为2:3:5,则所述虚拟化pool存储系统根据所述预设的分配策略计算得出所述卷在所述pool内的SSD的空间为20GB,在SAS的空间为30GB,在SATA的空间为50GB。
步骤S30,根据计算得到的所述卷占用每个存储层的空间大小,在每个 存储层中分配对应的空间给所述卷。
虚拟化pool存储系统根据计算得到的所述卷占用所述pool内每个存储层的空间大小,在每个存储层中分配对应的空间给所述卷。如所述虚拟化pool存储系统根据所述卷在所述pool内的SSD,SAS和SATA内空间的大小,在所述pool内SSD中分配20GB的空间给所述卷,在所述pool内的SAS中分配30GB的空间给所述卷,在所述pool内的SATA中分配50GB的空间给所述卷。
本实施例通过计算卷在资源池中占用每个存储层的空间大小,在每个存储层中分配对应的空间给所述卷,使所述卷能够利用资源池内多个物理磁盘的性能,通过分配较大的连续空间AS来实现了I/O在卷上的连续访问能够有效的转换成在存储层磁盘上的连续访问,减少磁头转动对磁盘的性能的影响,提高顺序访问I/O的性能,同时通过设置较小的映射粒度CK,将所述AS切成多个CK来建立地址映射表,进而兼顾热点迁移的效果。
可选地,参照图2,图2为本发明实施例卷的空间分配方法的第二实施例的流程示意图,基于第一实施例提出本发明实施例卷的空间分配方法的第二实施例。
本实施例在上述图1所示卷的空间分配方法的基础上,所述步骤S30包括步骤S31~步骤S37:
步骤S31,将所述卷划分成分配粒度AS的大小;
步骤S32,根据所述AS的大小在每个存储层中分配对应的空间给所述卷;
虚拟化pool存储系统根据计算得到的所述卷占用每个存储层的空间大小,当所述存储层内的磁盘为机械盘或者是SSD时,将所述卷在其pool内每个存储层中的空间大小划分成AS(Alloc Size,分配粒度)的大小,并根据所述AS的大小,在所述存储层内的磁盘阵列组RAID group中分配对应的空间给所述卷。
步骤S33,当其中一个存储层的空间分配完之后,重新建立所述存储层,或者分配新的空间给所述存储层;
步骤S34,当重新建立所述存储层或者分配新的空间给所述存储层失败 时,检测所述存储层的AS内是否有未分配的CK;
步骤S35,若所述存储层的AS内有未分配的CK,根据所述CK的大小在每个存储层中分配对应的空间给所述卷。
当所述虚拟化pool存储系统中所述pool内某个存储层的RAID group的空间已分配完时,则新建所述存储层的RAID group或者从所述pool内其它存储层内分配新的物理空间给所述存储层的RAID group扩容。当所述存储层的RAID group新建或者扩容成功后,所述虚拟化pool存储系统将所述pool内存储层中的RAID group空间分配给卷。当所述存储层的RAID group新建或者扩容失败时,所述虚拟化pool存储系统则从头开始检查空间分配完的存储层的RAID group中的AS内是否有未分配的CK,当所述AS内存在未分配的CK时,以CK为粒度来分配空间给所述卷;若所述AS内的CK已分配完,则表明所述存储层的空间分配失败。所述虚拟化pool存储系统根据其用户设置的分配策略选择从所述pool内其它存储层中分配空间给所述存储层的RAID group,或者提示所述用户所述存储层的RAID group中的空间分配失败,即创建卷失败。
步骤S36,根据地址映射粒度CK建立所述卷到所述资源池的地址映射表,所述AS是所述CK的整数倍。
当所述虚拟化pool存储系统为所述pool内存储层的卷分配了AS的空间之后,根据CK(chunk,地址映射粒度)建立所述卷内CK到所述pool内CK的地址映射表。所述AS是所述CK的整数倍。如一个AS可以由4个CK组成。所述卷内CK的ID(identification,身份标识符)与所述pool内CK的ID一一对应。当所述虚拟化pool存储系统建立了所述卷内CK到所述pool内CK的地址映射表时,所述虚拟化pool存储系统已为所述卷分配空间,创建所述卷成功。所述虚拟化pool存储系统通过所述卷从所述pool内不同存储层的RAID group上分配空间,以使所述卷能够利用pool内多个物理磁盘的性能。所述AS不会设置的太大,所述AS最大设置为从所述pool内物理磁盘上划分的小块组成的RAID group的大小。
步骤S37,当侦测到热点迁移的指令时,以CK作为热点迁移的粒度对资源池内的资源进行迁移。
当所述虚拟化pool存储系统侦测到所述pool内的热点迁移指令时,以CK作为热点迁移的粒度对所述pool内的资源进行迁移。如当所述虚拟化pool存储系统在读写数据时,发现所述pool内SAS中的某些数据使用频繁,则将这些使用频繁的数据以CK为粒度迁移到SSD内。当所述虚拟化pool存储系统pool内的SAS迁移后,可能会导致AS内部出现空洞,则当所述SAS内按照AS已经不能分配空间给所述卷时,再选择AS内空洞的CK来分配空间给所述卷。
本实施例的卷的空间分配方法,通过计算卷在资源池中每个存储层的空间分配比例,将存储层内的空间按照AS分配给对应的卷,并按照CK建立所述卷到所述资源池内的地址映射表。实现了使用AS的大小进行空间分配,使用CK进行热点迁移,在保持较小的粒度迁移的同时,提高了顺序I/O访问的性能。
可选地,参照图3,图3为本发明实施例卷的空间分配方法的第三实施例的流程示意图,基于第二实施例提出本发明实施例中卷的空间分配方法的第三实施例。
本实施例在上述图2所示卷的空间分配方法的基础上,所述步骤S36之后,还包括:
步骤S38,当所述存储层中的磁盘出现故障时,根据所述存储层中磁盘的个数和磁盘阵列参数,同时启动多个AS并行执行重建I/O的操作。
当虚拟化pool存储系统的pool内存储层中的某个磁盘出现故障时,所述虚拟化pool存储系统需要重建I/O,重建的I/O都是顺序的I/O。当所述虚拟化pool存储系统在重建I/O的时候,要要保证充分利用所述存储层内所有磁盘的性能,因此需要所述pool内存储层中多个RAID group中的AS能够并发进行。并发的AS数取决于所述pool内存储层中磁盘的数量以及所述磁盘中RAID参数。如当所述pool内存储层中磁盘的数量以及所述磁盘中RAID参数决定重建I/O时并发的AS数为4个,则所述磁盘重建的I/O并发数为4,即在每个AS内部顺序下发重建I/O,类似于多路的顺序流。在一个AS的内部,也会根据主机I/O的繁忙程度来限制重建I/O的并发数。
本实施例通过当资源池中存储层的磁盘出现故障时,同时启动多个AS 并行执行重建I/O的操作,提高了磁盘故障时I/O的重建性能。
可选地,参照图4,图4为本发明实施例卷的空间分配方法的第四实施例的流程示意图,基于第一实施例提出本发明实施例中卷的空间分配方法的第四实施例。
本实施例在在上述图1所示卷的空间分配方法的基础上,所述步骤S20之后,还包括:
步骤S40,判断所述资源池中是否存在固态硬盘;
若所述资源池中存在固态硬盘,则所述步骤S30可以为:将固态硬盘对应存储层中的卷划分成CK的大小,根据所述CK的大小在固态硬盘中分配对应的空间给所述卷,根据CK建立所述卷到所述资源池的地址映射表。
虚拟化pool存储系统判断其pool内的存储层是否存在SSD,当所述pool内的存储层存在SSD时,在对所述SSD中的RAID group空间进行分配时,可以以CK为粒度进行,其它不存在SSD的存储层以AS为粒度进行空间分配。当所述虚拟化pool存储系统将卷上的空间划分成CK的大小后,从所述SSD分配CK大小的空间给所述卷。若所述SSD中RAID group的CK大小的空间分配完成之后,所述虚拟化pool存储系统新建所述SSD中的RAID group,或者从所述pool内其它存储层中分配新的物理空间给所述SSD的RAID group进行扩容。当新建所述SSD的RAID group或者对所述SSD的RAID group扩容后,所述虚拟化pool存储系统将所述pool内的SSD中RAID group的CK大小的空间分配给所述卷。当所述SSD层的RAID group新建或者扩容失败时,所述虚拟化pool存储系统根据其用户设置的分配策略选择从所述pool内其它存储层中分配空间给所述SSD的RAID group,或者提示所述用户所述SSD的RAID group中的空间分配失败,即创建卷失败。
本实施例通过将SSD层磁盘阵列组中的空间按照CK分配给对应的卷。实现了当虚拟化pool存储系统的pool内存在SSD时,保持较小的粒度迁移的同时,提高了顺序I/O访问的性能。
本发明实施例还提供一种卷的空间分配装置。
参照图5,图5为本发明实施例卷的空间分配装置的第一实施例的功能 模块示意图。
在本实施例中,所述卷的空间分配装置包括:
获取模块10,设置为:获取待创建的卷的空间大小;
计算模块20,设置为:根据预设的分配策略和所述获取模块10获取的所述卷的空间大小,计算所述卷占用资源池中每个存储层的空间大小;
虚拟化pool存储系统获取其用户指定待创建的卷的空间大小,根据所述卷的空间大小和其用户预设的分配策略,计算所述卷在所述pool中占用每个存储层的空间大小,得到所述卷占用每个存储层的空间大小。所述虚拟化pool存储系统的存储阵列的volume层到pool层有一层地址空间的映射(当卷为thin卷时,除了所述映射外,还会有一层thin卷的映射。所述thin卷是指有自动精简配置功能的卷。所述自动精简配置是一种存储管理的特性,核心原理是“欺骗”客户端操作系统,让客户端操作系统认为已经分配了很大逻辑资源,比如客户端操作系统看到一个2TB(terabyte,太字节)的逻辑资源,而实际上网络存储设备上只为这个资源分配了几十或者几百GB(Gigabyte,十亿字节)的物理空间,其余空间都是虚拟出来的。随着应用程序写入越来越多的数据,物理存储利用率也会越来越高,当实际分配的物理空间不足时,再分配额外的物理空间,随需扩展)。所述pool内有三个层级,分别为tier0,tier1,tier2。所述tier0级为SSD(Solid State Drives,固态硬盘),tier1级为SAS(Serial Attached SCSI,串行连接SCSI接口),tier2级为SATA(Serial ATA,串口硬盘)。如当所述虚拟化pool存储系统用户定义所述卷的空间为100GB,所述预设的分配策略为tier0,tier1和tier2层级的卷在所述pool内存储层的空间分配比例为2:3:5,则所述拟化pool存储系统根据所述预设的分配策略计算得出所述卷在所述pool内的SSD的空间为20GB,在SAS的空间为30GB,在SATA的空间为50GB。
分配模块30,设置为:根据所述计算模块20计算得到的所述卷占用每个存储层的空间大小,在每个存储层中分配对应的空间给所述卷。
虚拟化pool存储系统根据计算得到的所述卷占用所述pool内每个存储层的空间大小,在每个存储层中分配对应的空间给所述卷。如所述虚拟化pool存储系统根据所述卷在所述pool内的SSD,SAS和SATA内空间的大小,在 所述pool内SSD中分配20GB的空间给所述卷,在所述pool内的SAS中分配30GB的空间给所述卷,在所述pool内的SATA中分配50GB的空间给所述卷。
本实施例通过计算卷在资源池中占用每个存储层的空间大小,在每个存储层中分配对应的空间给所述卷,使所述卷能够利用资源池内多个物理磁盘的性能,通过分配较大的连续空间AS来实现了I/O在卷上的连续访问能够有效的转换成在存储层磁盘上的连续访问,减少磁头转动对磁盘的性能的影响,提高顺序访问I/O的性能,同时通过设置较小的映射粒度CK,将所述AS切成多个CK来建立地址映射表,进而兼顾热点迁移的效果。
可选地,参照图6,图6为本发明实施例卷的空间分配装置的第二实施例的功能模块示意图,基于第一实施例提出本发明实施例中卷的空间分配装置的第二实施例。
本实施例中在上述图5所示卷的空间分配装置的结构基础上,所述分配模块30还包括:
划分单元31,设置为:将所述卷划分成分配粒度AS的大小;
第一分配单元32,设置为:根据所述划分单元31划分出的AS的大小在每个存储层中分配对应的空间给所述卷;
虚拟化pool存储系统根据计算得到的所述卷占用每个存储层的空间大小,当所述存储层内的磁盘为机械盘或者是SSD时,将所述卷在其pool内每个存储层中的空间大小划分成AS(Alloc Size,分配粒度)的大小,并根据所述AS的大小,在所述存储层内的磁盘阵列组RAID group中分配对应的空间给所述卷。
处理单元33,设置为:当其中一个存储层的空间分配完之后,重新建立所述存储层,或者分配新的空间给所述存储层;
检测单元34,设置为:当重新建立所述存储层或者分配新的空间给所述存储层失败时,检测所述存储层的AS内是否有未分配的CK;
第二分配单元35,设置为:若所述存储层的AS内有未分配的CK,则根据所述CK的大小在每个存储层中分配对应的空间给所述卷。
当所述虚拟化pool存储系统中所述pool内某个存储层的RAID group的空间已分配完时,则新建所述存储层的RAID group或者从所述pool内其它存储层内分配新的物理空间给所述存储层的RAID group扩容。当所述存储层的RAID group新建或者扩容成功后,所述虚拟化pool存储系统将所述pool内存储层中的RAID group空间分配给卷。当所述存储层的RAID group新建或者扩容失败时,所述虚拟化pool存储系统则从头开始检查空间分配完的存储层的RAID group中的AS内是否有未分配的CK,当所述AS内存在未分配的CK时,以CK为粒度来分配空间给所述卷;若所述AS内的CK已分配完,则表明所述存储层的空间分配失败。所述虚拟化pool存储系统根据其用户设置的分配策略选择从所述pool内其它存储层中分配空间给所述存储层的RAID group,或者提示所述用户所述存储层的RAID group中的空间分配失败,即创建卷失败。
建立单元36,设置为:根据地址映射粒度CK建立所述卷到所述资源池的地址映射表,所述AS是所述CK的整数倍。
当所述虚拟化pool存储系统为所述pool内存储层的卷分配了AS的空间之后,根据CK(chunk,地址映射粒度)建立所述卷内CK到所述pool内CK的地址映射表。所述AS是所述CK的整数倍。如一个AS可以由4个CK组成。所述卷内CK的ID(identification,身份标识符)与所述pool内CK的ID一一对应。当所述虚拟化pool存储系统建立了所述卷内CK到所述pool内CK的地址映射表时,所述虚拟化pool存储系统已为所述卷分配空间,创建所述卷成功。所述虚拟化pool存储系统通过所述卷从所述pool内不同存储层的RAID group上分配空间,以使所述卷能够利用pool内多个物理磁盘的性能。所述AS不会设置的太大,所述AS最大设置为从所述pool内物理磁盘上划分的小块组成的RAID group的大小。
迁移单元37,设置为:当侦测到热点迁移的指令时,以CK作为热点迁移的粒度对资源池内的资源进行迁移。
当所述虚拟化pool存储系统侦测到所述pool内的热点迁移指令时,以CK作为热点迁移的粒度对所述pool内的资源进行迁移。如当所述虚拟化pool存储系统在读写数据时,发现所述pool内SAS中的某些数据使用频繁,则将 这些使用频繁的数据以CK为粒度迁移到SSD内。当所述虚拟化pool存储系统pool内的SAS迁移后,可能会导致AS内部出现空洞,则当所述SAS内按照AS已经不能分配空间给所述卷时,再选择AS内空洞的CK来分配空间给所述卷。
本实施例的卷的空间分配装置,通过计算卷在资源池中每个存储层的空间分配比例,将存储层内的空间按照AS分配给对应的卷,并按照CK建立所述卷到所述资源池内的地址映射表。实现了使用AS的大小进行空间分配,使用CK进行热点迁移,在保持较小的粒度迁移的同时,提高了顺序I/O访问的性能。
可选地,参照图7,图7为本发明实施例卷的空间分配装置的第三实施例的功能模块示意图,基于第二实施例提出本发明实施例中卷的空间分配装置的第三实施例。
本实施例在上述图6所示卷的空间分配装置的结构基础上,所述分配模块30还包括:
启动单元38,设置为:当所述存储层中的磁盘出现故障时,根据所述存储层中磁盘的个数和磁盘阵列参数,同时启动多个AS并行执行重建I/O的操作。
当虚拟化pool存储系统的pool内存储层中的某个磁盘出现故障时,所述虚拟化pool存储系统需要重建I/O,重建的I/O都是顺序的I/O。当所述虚拟化pool存储系统在重建I/O的时候,要要保证充分利用所述存储层内所有磁盘的性能,因此需要所述pool内存储层中多个RAID group中的AS能够并发进行。并发的AS数取决于所述pool内存储层中磁盘的数量以及所述磁盘中RAID参数。如当所述pool内存储层中磁盘的数量以及所述磁盘中RAID参数决定重建I/O时并发的AS数为4个,则所述磁盘重建的I/O并发数为4,即在每个AS内部顺序下发重建I/O,类似于多路的顺序流。在一个AS的内部,也会根据主机I/O的繁忙程度来限制重建I/O的并发数。
本实施例通过当资源池中存储层的磁盘出现故障时,同时启动多个AS并行执行重建I/O的操作,提高了磁盘故障时I/O的重建性能。
可选地,参照图8,图8为本发明实施例卷的空间分配装置的第四实施例的功能模块示意图,基于第一实施例提出本发明实施例中卷的空间分配装置的第四实施例。
本实施例在图5所示卷的空间分配装置的结构基础上,所述卷的空间分配装置还包括:
判断模块40,设置为:判断所述资源池中是否存在固态硬盘;
若所述判断模块40判断出资源池中存在固态硬盘,则所述分配模块30,还设置为:将固态硬盘对应存储层中的卷划分成CK的大小,根据所述CK的大小在固态硬盘中分配对应的空间给所述卷,根据CK建立所述卷到所述资源池的地址映射表。
虚拟化pool存储系统判断其pool内的存储层是否存在SSD,当所述pool内的存储层存在SSD时,在对所述SSD中的RAID group空间进行分配时,可以以CK为粒度进行,其它不存在SSD的存储层以AS为粒度进行空间分配。当所述虚拟化pool存储系统将卷上的空间划分成CK的大小后,从所述SSD分配CK大小的空间给所述卷。若所述SSD中RAID group的CK大小的空间分配完成之后,所述虚拟化pool存储系统新建所述SSD中的RAID group,或者从所述pool内其它存储层中分配新的物理空间给所述SSD的RAID group进行扩容。当新建所述SSD的RAID group或者对所述SSD的RAID group扩容后,所述虚拟化pool存储系统将所述pool内的SSD中RAID group的CK大小的空间分配给所述卷。当所述SSD层的RAID group新建或者扩容失败时,所述虚拟化pool存储系统根据其用户设置的分配策略选择从所述pool内其它存储层中分配空间给所述SSD的RAID group,或者提示所述用户所述SSD的RAID group中的空间分配失败,即创建卷失败。
本实施例通过将SSD层磁盘阵列组中的空间按照CK分配给对应的卷。实现了当虚拟化pool存储系统的pool内存在SSD时,保持较小的粒度迁移的同时,提高了顺序I/O访问的性能。
本领域普通技术人员可以理解上述实施例的全部或部分步骤可以使用计算机程序流程来实现,所述计算机程序可以存储于一计算机可读存储介质中,所述计算机程序在相应的硬件平台上(如系统、设备、装置、器件等)执行, 在执行时,包括方法实施例的步骤之一或其组合。
可选地,上述实施例的全部或部分步骤也可以使用集成电路来实现,这些步骤可以被分别制作成一个个集成电路模块,或者将它们中的多个模块或步骤制作成单个集成电路模块来实现。
上述实施例中的装置/功能模块/功能单元可以采用通用的计算装置来实现,它们可以集中在单个的计算装置上,也可以分布在多个计算装置所组成的网络上。
上述实施例中的装置/功能模块/功能单元以软件功能模块的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储介质中。上述提到的计算机可读取存储介质可以是只读存储器,磁盘或光盘等。
工业实用性
本发明实施例通过计算卷在资源池中占用每个存储层的空间大小,在每个存储层中分配对应的空间给所述卷,使所述卷能够利用资源池内多个物理磁盘的性能,通过分配较大的连续空间AS来实现了I/O在卷上的连续访问能够有效的转换成在存储层磁盘上的连续访问,减少磁头转动对磁盘的性能的影响,提高顺序访问I/O的性能,同时通过设置较小的映射粒度CK,将所述AS切成多个CK来建立地址映射表,进而兼顾热点迁移的效果。

Claims (12)

  1. 一种卷的空间分配方法,包括:
    获取待创建的卷的空间大小;
    根据所述卷的空间大小和预设的分配策略,计算所述卷占用资源池中每个存储层的空间大小;
    根据计算得到的所述卷占用每个存储层的空间大小,在每个存储层中分配对应的空间给所述卷。
  2. 根据权利要求1所述卷的空间分配方法,其中,所述根据计算得到的所述卷占用每个存储层的空间大小,在每个存储层中分配对应的空间给所述卷,包括:
    将所述卷划分成分配粒度AS的大小;
    根据所述AS的大小在每个存储层中分配对应的空间给所述卷;
    根据地址映射粒度CK建立所述卷到所述资源池的地址映射表,所述AS是所述CK的整数倍。
  3. 根据权利要求2所述的卷的空间分配方法,其中,所述根据所述AS的大小在每个存储层中分配对应的空间给所述卷之后,还包括:
    当其中一个存储层的空间分配完之后,重新建立所述存储层,或者分配新的空间给所述存储层;
    当重新建立所述存储层或者分配新的空间给所述存储层失败时,检测所述存储层的AS内是否有未分配的CK;
    若所述存储层的AS内有未分配的CK,根据所述CK的大小在每个存储层中分配对应的空间给所述卷。
  4. 根据权利要求2所述的卷的空间分配方法,其中,所述根据CK建立所述卷到所述资源池内的地址映射表之后,还包括:
    当侦测到热点迁移的指令时,以CK作为热点迁移的粒度对资源池内的资源进行迁移。
  5. 根据权利要求2所述的卷的空间分配方法,其中,所述根据CK建立 所述卷到所述资源池内的地址映射表之后,还包括:
    当所述存储层中的磁盘出现故障时,根据所述存储层中磁盘的个数和磁盘阵列参数,同时启动多个AS并行执行重建输入输出端口I/O的操作。
  6. 根据权利要求1至5任一项所述的卷的空间分配方法,其中,所述根据所述卷的空间大小和预设的分配策略,计算所述卷占用资源池中每个存储层的空间大小之后,还包括:
    判断所述资源池中是否存在固态硬盘;
    若所述资源池中存在固态硬盘,所述根据计算得到的所述卷占用每个存储层的空间大小,在每个存储层中分配对应的空间给所述卷,包括:
    将所述固态硬盘对应存储层中的卷划分成CK的大小,根据所述CK的大小在固态硬盘中分配对应的空间给所述卷,根据CK建立所述卷到所述资源池的地址映射表。
  7. 一种卷的空间分配装置,包括:
    获取模块,设置为:获取待创建的卷的空间大小;
    计算模块,设置为:根据预设的分配策略和所述获取模块获取的所述卷的空间大小,计算所述卷占用资源池中每个存储层的空间大小;
    分配模块,设置为:根据所述计算模块计算得到的所述卷占用每个存储层的空间大小,在每个存储层中分配对应的空间给所述卷。
  8. 根据权利要求7所述的卷的空间分配装置,其中,所述分配模块包括:
    划分单元,设置为:将所述卷划分成分配粒度AS的大小;
    第一分配单元,设置为:根据所述划分单元划分出的AS的大小在每个存储层中分配对应的空间给所述卷;
    建立单元,设置为:根据地址映射粒度CK建立所述卷到所述资源池的地址映射表,所述AS是所述CK的整数倍。
  9. 根据权利要求8所述的卷的空间分配装置,其中,所述分配模块还包括:
    处理单元,设置为:当其中一个存储层的空间分配完之后,重新建立所 述存储层,或者分配新的空间给所述存储层;
    检测单元,设置为:当重新建立所述存储层或者分配新的空间给所述存储层失败时,检测所述存储层的AS内是否有未分配的CK;
    第二分配单元,设置为:若所述存储层的AS内有未分配的CK,根据所述CK的大小在每个存储层中分配对应的空间给所述卷。
  10. 根据权利要求8所述的卷的空间分配装置,其中,所述分配模块还包括迁移单元,设置为:当侦测到热点迁移的指令时,以CK作为热点迁移的粒度对资源池内的资源进行迁移。
  11. 根据权利要求8所述的卷的空间分配装置,其中,所述分配模块还包括启动单元,设置为:当所述存储层中的磁盘出现故障时,根据所述存储层中磁盘的个数和磁盘阵列参数,同时启动多个AS并行执行重建输入输出端口I/O的操作。
  12. 根据权利要求7至11任一项所述的卷的空间分配装置,还包括判断模块,设置为:判断所述资源池中是否存在固态硬盘;
    所述分配模块,还设置为:在所述判断模块判断出所述资源池中存在固态硬盘时,将所述固态硬盘对应存储层中的卷划分成CK的大小,根据所述CK的大小在固态硬盘中分配对应的空间给所述卷,根据CK建立所述卷到所述资源池的地址映射表。
PCT/CN2016/082351 2015-07-15 2016-05-17 卷的空间分配方法和装置 WO2017008571A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201510418973.1 2015-07-15
CN201510418973.1A CN107037975B (zh) 2015-07-15 2015-07-15 卷的空间分配方法和装置

Publications (1)

Publication Number Publication Date
WO2017008571A1 true WO2017008571A1 (zh) 2017-01-19

Family

ID=57756812

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2016/082351 WO2017008571A1 (zh) 2015-07-15 2016-05-17 卷的空间分配方法和装置

Country Status (2)

Country Link
CN (1) CN107037975B (zh)
WO (1) WO2017008571A1 (zh)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US11163476B2 (en) 2019-10-04 2021-11-02 International Business Machines Corporation Dynamic rebalancing of free space between storage pools

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113157341B (zh) * 2021-04-26 2022-12-02 上海淇馥信息技术有限公司 对象的资源环境自适应处理方法、装置和电子设备

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101997918A (zh) * 2010-11-11 2011-03-30 清华大学 异构san环境中的海量存储资源按需分配的实现方法
US20120011329A1 (en) * 2010-07-09 2012-01-12 Hitachi, Ltd. Storage apparatus and storage management method
CN102754084A (zh) * 2010-05-18 2012-10-24 株式会社日立制作所 存储装置和数据管理方法

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7428614B2 (en) * 2006-07-27 2008-09-23 Hitachi, Ltd. Management system for a virtualized storage environment
JP4727705B2 (ja) * 2008-10-31 2011-07-20 株式会社日立製作所 階層型ストレージシステム
CN101604226B (zh) * 2009-07-14 2010-12-01 浪潮电子信息产业股份有限公司 一种基于虚拟raid构建动态缓存池提高存储系统性能的方法
CN104731517A (zh) * 2013-12-19 2015-06-24 中国移动通信集团四川有限公司 一种存储池容量分配方法和装置

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102754084A (zh) * 2010-05-18 2012-10-24 株式会社日立制作所 存储装置和数据管理方法
US20120011329A1 (en) * 2010-07-09 2012-01-12 Hitachi, Ltd. Storage apparatus and storage management method
CN101997918A (zh) * 2010-11-11 2011-03-30 清华大学 异构san环境中的海量存储资源按需分配的实现方法

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US11163476B2 (en) 2019-10-04 2021-11-02 International Business Machines Corporation Dynamic rebalancing of free space between storage pools

Also Published As

Publication number Publication date
CN107037975A (zh) 2017-08-11
CN107037975B (zh) 2019-12-03

Similar Documents

Publication Publication Date Title
US11023147B2 (en) Mapping storage extents into resiliency groups
US10001947B1 (en) Systems, methods and devices for performing efficient patrol read operations in a storage system
US8850152B2 (en) Method of data migration and information storage system
US9798471B2 (en) Performance of de-clustered disk array by disk grouping based on I/O statistics
US10146447B1 (en) Mapped RAID (redundant array of independent disks) in a data storage system with drive extents allocated to individual RAID extents from individual sub-groups of storage made up of ranges of logical block addresses defined across a group of hard disk drives
US8307171B2 (en) Storage controller and storage control method for dynamically assigning partial areas of pool area as data storage areas
CN107092442B (zh) 存储系统资源分配方法及装置
US11137940B2 (en) Storage system and control method thereof
US8639876B2 (en) Extent allocation in thinly provisioned storage environment
US10852966B1 (en) System and method for creating mapped RAID group during expansion of extent pool
US20140325262A1 (en) Controlling data storage in an array of storage devices
WO2016023390A1 (zh) 虚拟机存储资源部署方法和装置
JP6569477B2 (ja) ストレージ制御装置、および制御プログラム
US20150347047A1 (en) Multilayered data storage methods and apparatus
US20140075111A1 (en) Block Level Management with Service Level Agreement
EP3983878B1 (en) Ensuring sufficient available storage capacity for data resynchronization/reconstruction in a hyper-converged infrastructure
CN105988727B (zh) 一种基于raid的存储方法和存储装置
US11899533B2 (en) Stripe reassembling method in storage system and stripe server
US20180107409A1 (en) Storage area network having fabric-attached storage drives, san agent-executing client devices, and san manager
US10496278B1 (en) Inline compression support using discrete sized containers for backing store
WO2017008571A1 (zh) 卷的空间分配方法和装置
JP6476959B2 (ja) ストレージ制御装置、ストレージシステム、および制御プログラム
WO2015078193A1 (zh) 存储空间的管理方法和存储管理装置
JP2015158711A (ja) ストレージ制御装置、仮想ストレージ装置、ストレージ制御方法、及びストレージ制御プログラム
US20220107871A1 (en) Creating and distributing spare capacity of a disk array

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 16823718

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 16823718

Country of ref document: EP

Kind code of ref document: A1