CN115639968B - Method, device, equipment and medium for allocating RAID (redundant array of independent disks) capacity space - Google Patents

Method, device, equipment and medium for allocating RAID (redundant array of independent disks) capacity space Download PDF

Info

Publication number
CN115639968B
CN115639968B CN202211431867.3A CN202211431867A CN115639968B CN 115639968 B CN115639968 B CN 115639968B CN 202211431867 A CN202211431867 A CN 202211431867A CN 115639968 B CN115639968 B CN 115639968B
Authority
CN
China
Prior art keywords
raid
volume
lba address
space
address interval
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
CN202211431867.3A
Other languages
Chinese (zh)
Other versions
CN115639968A (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.)
Suzhou Inspur Intelligent Technology Co Ltd
Original Assignee
Suzhou Inspur Intelligent Technology 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 Suzhou Inspur Intelligent Technology Co Ltd filed Critical Suzhou Inspur Intelligent Technology Co Ltd
Priority to CN202211431867.3A priority Critical patent/CN115639968B/en
Publication of CN115639968A publication Critical patent/CN115639968A/en
Application granted granted Critical
Publication of CN115639968B publication Critical patent/CN115639968B/en
Priority to PCT/CN2023/115586 priority patent/WO2024103901A1/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • 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

Landscapes

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

Abstract

The invention relates to a method, a device, equipment and a medium for allocating a volume space of a RAID (redundant array of independent disks). The method comprises the following steps: establishing the relation between different RAID levels and the LBA address space, and executing the RAID level operation in the LBA address space; acquiring a required RAID level according to business requirements, and creating an RAID volume according to the required RAID level to obtain an LBA address interval required by creating the RAID volume; judging whether the space of the RAID group meets the size of the LBA address interval required by the creation of the RAID volume; and mapping the LBA address intervals required by the creation of the RAID volume to namespace in response to the condition that the space of the RAID group meets the size of the LBA address intervals required by the creation of the RAID volume, and completing the creation of the RAID volume required by service requirements. The invention creates the proper RAID volume according to different service requirements, and improves the utility of the space of the RAID.

Description

Method, device, equipment and medium for allocating RAID (redundant array of independent disks) capacity space
Technical Field
The present invention relates to the field of storage, and in particular, to a method, an apparatus, a device, and a medium for allocating a volume space of a RAID.
Background
In the RAID (Redundant Array formed by Independent hard Disks of Independent Disks), a plurality of hard Disks are combined in a certain manner to form a new hard disk Array group, so that the data read-write capability is improved. Common hard disk redundant arrays have different levels, such as RAID0, RAID1, RAID5, and RAID6, where RAID0 level is a redundant whole column of hard disks, and improves read-write performance by dispersing continuous data to multiple hard disks, and has no redundancy capability itself; in the RAID1 level, two hard disks form a RAID hard disk array, the capacity of the RAID hard disk array is only equal to that of one hard disk, and the other hard disk is only used as a data mirror image; the RAID5 level is that a redundant disk is added to store the exclusive or data of other disks, so that the whole hard disk group can have certain redundancy capability; the RAID6 level is that the whole hard disk group has higher redundancy capability by adding two redundant disks and storing exclusive OR data of other disks.
In the prior art, a method for creating a volume based on a RAID card is as follows: selecting several hard disks to create an RAID group; a volume is created by choosing an address in a RAID group and namespace mapping. This approach only allows volumes of the same RAID level to be created on a set of hard disks for which a RAID level has been determined. For some scenes with more services and limited hard disk quantity, the limit cannot create a proper RAID volume according to the requirements of different service data. The user can only make some compromises between the reading performance, the writing performance, the fault tolerance and the usable space, and the user service is influenced.
Disclosure of Invention
In view of this, the present invention provides a method, an apparatus, a device and a medium for allocating a capacity space of a RAID. The method for allocating the RAID capacity space only binds the RAID level with the volume, is suitable for the volume space allocation management on the RAID card, controls the RAID level of the storage space through smaller granularity, and refers the traditional RAID level from the hard disk group to the volume level for confirmation. Users can create volumes of various RAID levels in the same RAID group as required to adapt to the service requirement, thereby greatly improving the flexibility of the RAID levels and the utility of the hard disk space.
In view of the above objects, an aspect of the embodiments of the present invention provides a method for allocating a capacity space of a RAID, the method including the steps of: establishing the relation between different RAID levels and an LBA address space, and executing the RAID level operation in the LBA address space; acquiring a required RAID level according to service requirements, and creating a RAID volume according to the required RAID level to obtain an LBA address interval required by creating the RAID volume; judging whether the space of the RAID group meets the size of the LBA address interval required by the creation of the RAID volume; and in response to that the space of the RAID group meets the size of the LBA address interval required by the creation of the RAID volume, mapping the LBA address interval required by the creation of the RAID volume to namespace, and completing the creation of the RAID volume required by the service requirement.
In some embodiments, the method further comprises: and in response to that the space of the RAID group does not meet the size of the LBA address interval, not creating a corresponding RAID volume according to the required RAID level.
In some embodiments, the obtaining a required RAID level according to a service requirement, and creating a RAID volume according to the required RAID level, and obtaining an LBA address interval required to create the RAID volume includes: and acquiring the LAB address interval corresponding to the required RAID level according to the relation between the different RAID levels and the LBA address space.
In some embodiments, the obtaining a required RAID level according to a service requirement, and creating a RAID volume according to the required RAID level, and obtaining an LBA address interval required to create the RAID volume further includes: and acquiring the LBA address interval required by the creation of the RAID volume in the LAB address interval corresponding to the required RAID level.
In some embodiments, the obtaining LBA address intervals required to create the RAID volume at the LAB address intervals corresponding to the required RAID level includes: and calculating the LBA address interval required by the creation of the RAID volume according to the number and the size of the RAID required by the required RAID level.
In some embodiments, the determining whether the space of the RAID group satisfies the size of the LBA address interval required to create the RAID volume includes: and judging whether the space of the RAID group meets the size of the LBA address interval required by the creation of the RAID volume or not according to the number of the RAIDs in the RAID group.
In some embodiments, the associating the different RAID levels with the LBA address space, the performing the RAID level operations in the LBA address space comprising: and performing stripe consistency detection and formatting on the LBA address space to obtain the RAID level operation.
In another aspect of the embodiments of the present invention, an apparatus for allocating capacity space of a RAID is further provided, where the apparatus includes the following modules: the first module is configured to establish the relation between different RAID levels and the LBA address space, and execute RAID level operation in the LBA address space; the second module is configured to acquire a required RAID level according to a service requirement, and create a RAID volume according to the required RAID level to acquire an LBA address interval required for creating the RAID volume; a third module configured to determine whether a space of a RAID group satisfies a size of an LBA address interval required to create the RAID volume; and the fourth module is configured to respond that the space of the RAID group satisfies the size of the LBA address interval required to create the RAID volume, map the LBA address interval required to create the RAID volume to namespace, and complete creation of the RAID volume required by the service demand.
In some embodiments, the apparatus further comprises: and a fifth module, configured to respond that the space of the RAID group does not satisfy the size of the LBA address interval, and not create a corresponding RAID volume according to the required RAID level.
In some embodiments, the second module is further configured to: and acquiring the LAB address interval corresponding to the required RAID level according to the relation between the different RAID levels and the LBA address space.
In some embodiments, the second module is further configured to: and acquiring the LBA address interval required by the creation of the RAID volume in the LAB address interval corresponding to the required RAID level.
In some embodiments, the second module is further configured to: and calculating the LBA address interval required by the creation of the RAID volume according to the number and the size of the RAID required by the required RAID level.
In some embodiments, the third module is further configured to: and judging whether the space of the RAID group meets the size of the LBA address interval required by the creation of the RAID volume or not according to the number of the RAIDs in the RAID group.
In another aspect of the embodiments of the present invention, there is also provided a computer device, including at least one processor; and a memory storing computer instructions executable on the processor, the instructions when executed by the processor implementing the steps of any of the methods described above.
In another aspect of the embodiments of the present invention, a computer-readable storage medium is further provided, and the computer-readable storage medium stores a computer program which, when executed by a processor, implements any of the above method steps.
The invention has at least the following beneficial effects: the invention provides a method, a device, equipment and a medium for allocating a volume space of a RAID (redundant array of independent disks). The method for allocating the volume space of the RAID is suitable for allocation management of volume space on the RAID, and the RAID level of the storage space is controlled by adopting smaller granularity, so that some operations on the RAID group are transferred to the corresponding LBA address interval to be executed, such as stripe consistency detection, formatting and the like. The management at the hard disk group level no longer has RAID level attributes, which only exist in the corresponding LBA address interval. When a specific volume is created, the LBA address intervals required for volumes of different classes need to be calculated according to the RAID level. For the use scenes that the service scenes are more and the hard disks are limited, the flexibility of creating volumes on the RAID card by a user can be improved, the proper RAID volumes are created according to different service requirements, the utility of the space of the RAID is improved, the performance of the whole service is improved, and the whole productivity is improved.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the embodiments or the prior art descriptions will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present invention, and other embodiments can be obtained by those skilled in the art without creative efforts.
FIG. 1 is a schematic diagram of an embodiment of creating RAID volumes of the same RAID level in a RAID group according to the prior art;
FIG. 2 is a schematic diagram illustrating an embodiment of a method for allocating a volume space of a RAID according to the present invention;
FIG. 3 is a schematic diagram illustrating another embodiment of a method for allocating a volume space of a RAID according to the present invention;
FIG. 4 is a schematic diagram of an embodiment of creating RAID volumes of different RAID levels in a RAID group according to the present invention;
FIG. 5 is a schematic diagram illustrating another embodiment of a method for allocating a volume space of a RAID according to the present invention;
FIG. 6 is a schematic diagram illustrating an embodiment of an apparatus for allocating capacity space of a RAID according to the present invention;
FIG. 7 is a schematic diagram illustrating another embodiment of an apparatus for allocating capacity space of a RAID according to the present invention;
FIG. 8 is a schematic diagram of one embodiment of a computer device;
fig. 9 is a schematic diagram of an embodiment of a computer-readable storage medium provided by the present invention.
Detailed Description
Embodiments of the present invention are described below. However, it is to be understood that the disclosed embodiments are merely examples and that other embodiments may take various and alternative forms.
In addition, it should be noted that all expressions using "first" and "second" in the embodiments of the present invention are used for distinguishing two entities with the same name but different names or different parameters, and it should be noted that "first" and "second" are only used for convenience of expression and should not be construed as a limitation to the embodiments of the present invention, and they are not described in any further embodiments. The terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus.
One or more embodiments of the present application will be described below with reference to the accompanying drawings.
Fig. 1 is a schematic diagram illustrating an embodiment of creating a RAID volume of the same RAID level in one RAID group in the prior art, as shown in fig. 1, in the prior art, the basic manner of creating a RAID volume based on a RAID card is as follows: selecting several hard disks to create an RAID group; a volume is created by choosing an address in a RAID group and namespace mapping. Fig. 1 shows a RAID5 hard disk group consisting of 4 hard disks, and the space thereof is divided into 3 address segments RAID5_0, RAID5_1, and RAID5_2. The mapped volume may be used as 3 RAID5 level volumes. The prior art method only allows to create volumes of the same RAID level on a group of hard disks with determined RAID level, determines RAID level on hard disk granularity, divides storage space into strips in sequence on the RAID group by forming the hard disks into RAID groups, and finally forms volumes mapped to the outside by strips with continuous addresses. For some scenes with more services and limited hard disk quantity, the limit cannot create a proper RAID volume according to the requirements of different service data. The user can only make some compromises between the reading performance, the writing performance, the fault tolerance and the usable space, and the user service is influenced.
In view of the above objects, a first aspect of the embodiments of the present invention provides an embodiment of a method for allocating a capacity space of a RAID. Fig. 2 is a schematic diagram illustrating an embodiment of a method for allocating capacity space of a RAID according to the present invention. As shown in fig. 2, a method for allocating a capacity space of a RAID according to an embodiment of the present invention includes the following steps:
s1, establishing different relationships between RAID levels and LBA address spaces, and executing RAID level operations in the LBA address spaces;
s2, acquiring a required RAID level according to service requirements, and creating a RAID volume according to the required RAID level to obtain an LBA address interval required for creating the RAID volume;
s3, judging whether the space of the RAID group meets the size of the LBA address interval required by the creation of the RAID volume;
and S4, responding to the condition that the space of the RAID group meets the size of the LBA address interval required by the creation of the RAID volume, mapping the LBA address interval required by the creation of the RAID volume to namespace, and completing the creation of the RAID volume required by the service requirement.
According to several embodiments of the invention, the method further comprises: in response to the space of the RAID group not satisfying the size of the LBA address interval, the corresponding RAID volume is not created according to the required RAID level.
According to some embodiments of the present invention, acquiring a required RAID level according to a service requirement, and creating a RAID volume according to the required RAID level, acquiring an LBA address interval required to create the RAID volume includes: and acquiring an LAB address interval corresponding to the required RAID level according to the relation between different RAID levels and the LBA address space.
According to several embodiments of the present invention, acquiring a required RAID level according to a service requirement, and creating a RAID volume according to the required RAID level, and acquiring an LBA address interval required for creating the RAID volume further includes: and acquiring the LBA address interval required by creating the RAID volume in the LAB address interval corresponding to the required RAID level.
According to several embodiments of the invention, obtaining LBA address intervals required to create a RAID volume in LAB address intervals corresponding to a required RAID level includes: the LBA address interval required to create the RAID volume is calculated according to the number and size of RAIDs required for the required RAID level.
According to several embodiments of the present invention, determining whether the space of the RAID group satisfies the size of the LBA address interval required to create the RAID volume includes: and judging whether the space of the RAID group meets the size of the LBA address interval required by the creation of the RAID volume or not according to the RAID number in the RAID group.
According to several embodiments of the present invention, establishing different RAID levels associated with the LBA address space, performing RAID level operations in the LBA address space includes: the operations at RAID level including stripe consistency detection, formatting are performed in LBA address space.
The method for allocating the volume space of the RAID is suitable for allocation management of volume space on the RAID, and the RAID level of the storage space is controlled by adopting smaller granularity, so that some operations originally on the RAID group are transferred to the corresponding LBA address interval to be executed, such as stripe consistency detection, formatting and the like. The management at the hard disk group level no longer has RAID level attributes, which only exist in the corresponding LBA address interval. When a specific volume is created, the LBA address intervals required for volumes of different classes need to be calculated according to the RAID level. For the service scenes that the number of the service scenes is large and the hard disks are limited, the flexibility of creating the volume on the RAID card by a user can be improved, the proper RAID volume is created according to different service requirements, the space utility of the RAID is improved, the performance of the whole service is improved, and the whole productivity is improved.
In a first aspect of the embodiments of the present invention, another embodiment of a method for allocating a capacity space of a RAID is provided. Fig. 3 is a schematic diagram illustrating another embodiment of the allocation method for the capacity space of the RAID according to the present invention. As shown in fig. 3, a method for allocating capacity space of RAID according to an embodiment of the present invention further includes the following steps:
s1, establishing the relation between different RAID levels and an LBA address space, and executing RAID level operation in the LBA address space;
s2, acquiring a required RAID level according to service requirements, and creating a RAID volume according to the required RAID level to obtain an LBA address interval required for creating the RAID volume;
s3, judging whether the space of the RAID group meets the size of the LBA address interval required by the creation of the RAID volume;
and S4, responding to the condition that the space of the RAID group meets the size of the LBA address interval required by the creation of the RAID volume, mapping the LBA address interval required by the creation of the RAID volume to namespace, and completing the creation of the RAID volume required by the service requirement.
The method for allocating the RAID capacity space only binds the RAID level with the volume, is suitable for volume space allocation management on the RAID card, controls the RAID level of the storage space through smaller granularity, and confirms the traditional RAID level by lifting the hard disk group to the volume level. Users can create volumes with various RAID levels in the same RAID group as required to adapt to the requirements of services, thereby greatly improving the flexibility of the RAID levels and the utility of the hard disk space.
Based on the first aspect of the embodiment of the present invention, in an embodiment of a method for allocating RAID capacity spaces, fig. 4 shows a schematic diagram of an embodiment of creating RAID volumes of different RAID levels in a RAID group, which is provided by the present invention, as shown in fig. 4, fig. 4 shows a RAID group composed of 4 hard disks, in the RAID group, the RAID level is not directly specified according to a prior art manner, but when a specific RAID volume is created, only the RAID level of a section of address space corresponding to the specific RAID volume is specified, a plurality of types of RAID volumes are included in the same RAID group, and the RAID group in this embodiment includes RAID5_0 in RAID5 level, RAID6_0 in RAID6 level, RAID1_0 in RAID1 level, and RAID0_0 in RAID0 level. The areas of different colors represent LBA address intervals of different RAID levels, each address interval is mapped to one namespace, and externally represented as one RAID volume. The address interval corresponding to the RAID volume is composed of a space of each hard disk in the hard disk group, so the mapping relationship from the RAID volume to the hard disk can be expressed as the mapping from the upper layer namespace to the plurality of hard disks namespaces.
In this embodiment, the attributes at RAID levels RAID0, RAID1, RAID5, and RAID6 are migrated to the LBA address space, and the operations originally performed in the RAID group, such as detection of stripe consistency, formatting, and the like, are migrated to the corresponding LBA address interval, so that the RAID group no longer has the attributes at RAID levels RAID0, RAID1, RAID5, and RAID6, and only exists in the corresponding LBA address space. And obtaining the volume to be created corresponding to the user according to the service requirement of the user and the RAID level corresponding to the volume to be created. In this embodiment, the attributes of RAID0, RAID1, RAID5, and RAID6 levels at the RAID level are migrated to the LBA address space, that is, a relationship between the RAID level and the LBA address space is established, instead of creating a RAID volume on a group of hard disks at the same RAID level, a relationship between the RAID level and the LBA address space is established, different LBA address intervals are associated with different RAID levels and correspond to the LBA address intervals, and a continuous LBA address interval required by the volume to be created is obtained according to the RAID level of the volume to be created. In the RAID group, obtaining the continuous LBA address space required by creating the RAID volume to be created according to the quantity and the size of the hard disks required by the RAID level corresponding to the RAID volume to be created, judging whether the time space size and the hard disk quantity in the RAID group meet the continuous LBA address space required by creating the RAID volume, judging whether the quantity of the RAID hard disks meets the minimum quantity requirement of creating the RAID volume, if the minimum quantity requirement of creating the RAID volume is met, mapping the continuous address interval to the namespace LBA to complete the creation of the RAID volume to be created, and if the minimum quantity requirement of creating the RAID volume is not met, the RAID volume of the RAID level cannot be created.
In the prior art, RAID levels are determined on hard disk granularity, hard disks are firstly formed into RAID groups, then storage spaces are sequentially divided into strips on the RAID groups, and finally the strips with continuous addresses form volumes which are mapped to the outside one by one. The method for allocating the capacity space of the RAID, which is provided by the invention, is used for embodying the dividing granularity of the RAID level to a section of address in a hard disk, so that the flexibility of creating the RAID volume can be greatly improved. Compared with the prior art, the method disclosed by the invention can be used for transferring some operations originally on the RAID group to the corresponding LBA address interval for execution, such as strip consistency detection, formatting and the like. The management at the hard disk group level no longer has RAID-level attributes, which only exist in the corresponding LBA address interval. When a specific volume is created, the LBA address intervals required for volumes of different classes need to be calculated according to the RAID level.
In a first aspect of the embodiments of the present invention, an embodiment of a method for allocating a capacity space of a RAID is provided. Fig. 5 is a schematic diagram illustrating another embodiment of the allocation method for the capacity space of the RAID according to the present invention. As shown in fig. 5, first, a hard disk group is selected according to a service requirement of a user, and is used to create a RAID volume corresponding to the service requirement of the user, an attribute at a RAID level is migrated into an LBA address space, and an operation originally performed in the RAID group, such as detection of stripe consistency, formatting, and the like, is migrated into a corresponding LBA address interval, so that the RAID group no longer has the attribute at the RAID level, and only exists in the corresponding LBA address space, and a volume to be created corresponding to the RAID group and an RAID level corresponding to the volume to be created are obtained according to the service requirement of the user. Establishing the relation between the RAID level and the LBA address space instead of establishing the RAID volume on the basis of a group of hard disks of the same RAID level, establishing the relation between the RAID level and the LBA address space, having different relation LBA address intervals corresponding to different RAID levels, and obtaining the required continuous LBA address interval according to the RAID level of the volume to be established. The size of the continuous LBA address actually required by the RAID level of the RAID volume created as needed may be determined according to the number and size of the hard disks, that is, the number and size of the required hard disks may not exceed the actual number of hard disks of the hard disk group, and how many hard disks are required may be specifically specified like RAID5, RAID6, and the like; judging the size of the actually required LBA address of the RAID level of the volume and the size of the actual space of the hard disk group, if the size of the space of the hard disk group meets the size of the actually required LBA address of the RAID level of the volume, recording the range of the LBA address of the volume, and carrying out namespace mapping to complete the creation of the volume; if the size of the temporal space of the hard disk group does not meet the size of the LBA addresses actually required by the RAID level of the volume, then the volume of the corresponding RAID level cannot be created.
According to the method for allocating the volume space of the RAID, provided by the invention, the dividing granularity of the RAID level is embodied to a section of address in the hard disk, so that the flexibility of creating the RAID volume can be greatly improved. Compared with the prior art, the method disclosed by the invention can transfer some operations originally on the RAID group to a section of address for execution, such as stripe consistency detection, formatting and the like. The management at the hard disk group level no longer has RAID level attributes, which only exist in the corresponding LBA address interval. When a specific volume is created, the LBA address intervals required for volumes of different classes need to be calculated according to the RAID level. The LBA address intervals required for different classes of volumes need only be calculated according to RAID level when a particular volume is created. Whether a group of disks can support the creation of a RAID type volume depends only on whether the number of disks in the group of disks meets the minimum disk requirements for creating the RAID level volume. The method for allocating the volume space of the RAID is suitable for allocating and managing the volume space on the RAID card, and improves the flexibility of creating the volume on the RAID card by a user through controlling the RAID level of the storage space with smaller granularity. Typically, a group of disks capable of creating a RAID6 level volume is also capable of creating a RAID5, RAID1, RAID0 level volume. In practical application, for a use scene with more service scenes and limited hard disks, a user can create volumes of the most suitable class without limit, so that the performance of the whole service is improved, and the whole productivity is improved.
In a second aspect of the embodiments of the present invention, an apparatus for allocating capacity space to RAID is provided. Fig. 6 is a schematic diagram illustrating an embodiment of an apparatus for allocating capacity space to RAID according to the present invention. As shown in fig. 6, the apparatus for allocating capacity space to RAID according to the present invention includes: a first module 011 configured to establish a relationship between different RAID levels and LBA address space, and perform a RAID level operation in the LBA address space; a second module 012, configured to obtain a required RAID level according to a service requirement, and create a RAID volume according to the required RAID level, to obtain an LBA address interval required to create the RAID volume; a third module 013, configured to determine whether a space of a RAID group satisfies a size of an LBA address interval required to create the RAID volume; a fourth module 014, configured to map the LBA address interval required for creating the RAID volume to namespace in response to the space of the RAID group satisfying the size of the LBA address interval required for creating the RAID volume, and complete creation of the RAID volume required for the service requirement.
In a second aspect of the embodiments of the present invention, an apparatus for allocating capacity space of a RAID is provided. Fig. 7 is a schematic diagram illustrating an embodiment of an apparatus for allocating capacity space to RAID according to the present invention. As shown in fig. 7, the allocation apparatus for RAID capacity space according to the present invention includes: a first module 011 configured to establish a relationship between different RAID levels and an LBA address space, and perform an operation at a RAID level in the LBA address space; a second module 012, configured to obtain a required RAID level according to a service requirement, and create a RAID volume according to the required RAID level, to obtain an LBA address interval required to create the RAID volume; a third module 013, configured to determine whether a space of a RAID group satisfies a size of an LBA address interval required to create the RAID volume; a fourth module 014, configured to map the LBA address interval required for creating the RAID volume to namespace in response to the space of the RAID group satisfying the size of the LBA address interval required for creating the RAID volume, and complete creation of the RAID volume required for the service requirement; a fifth module 015, configured to respond that the space of the RAID group does not satisfy the size of the LBA address interval, and not create a corresponding RAID volume according to the required RAID level.
In some embodiments, the second module 012 is further configured to: and acquiring the LAB address interval corresponding to the required RAID level according to the relation between the different RAID levels and the LBA address space.
In some embodiments, the second module 012 is further configured to: and acquiring the LBA address interval required for creating the RAID volume in the LAB address interval corresponding to the required RAID level.
In some embodiments, the second module 012 is further configured to: and calculating the LBA address interval required by the creation of the RAID volume according to the number and the size of the RAID required by the required RAID level.
In some embodiments, the third module 013 is further configured to: and judging whether the space of the RAID group meets the size of the LBA address interval required by the creation of the RAID volume or not according to the number of the RAIDs in the RAID group.
In view of the above object, a third aspect of the embodiments of the present invention provides a computer device, and fig. 8 is a schematic diagram illustrating an embodiment of a computer device provided by the present invention. As shown in fig. 8, an embodiment of a computer device provided by the present invention includes the following modules: at least one processor 021; and a memory 022, the memory 022 storing computer instructions 023 executable on the processor 021, the computer instructions 023, when executed by the processor 021, implementing the steps of the method described above.
The invention also provides a computer readable storage medium. FIG. 9 is a schematic diagram illustrating an embodiment of a computer-readable storage medium provided by the present invention. As shown in fig. 9, the computer readable storage medium 031 stores a computer program 032 which, when executed by a processor, performs the method as described above. In particular, the method executed by the computer program 032 includes the steps of: establishing the relation between different RAID levels and LBA address spaces, and executing RAID level operation in the LBA address spaces; acquiring a required RAID level according to business requirements, and creating a RAID volume according to the required RAID level to obtain an LBA address interval required by the creation of the RAID volume; judging whether the space of the RAID group meets the size of the LBA address interval required by the creation of the RAID volume; and in response to that the space of the RAID group meets the size of the LBA address interval required for creating the RAID volume, mapping the LBA address interval required for creating the RAID volume to namespace, and completing the creation of the RAID volume required by the service requirement.
In some embodiments, the method further comprises: and in response to that the space of the RAID group does not meet the size of the LBA address interval, not creating a corresponding RAID volume according to the required RAID level.
In some embodiments, the obtaining a required RAID level according to a service requirement, and creating a RAID volume according to the required RAID level, and obtaining an LBA address interval required to create the RAID volume includes: and acquiring the LAB address interval corresponding to the required RAID level according to the relation between the different RAID levels and the LBA address space.
In some embodiments, the obtaining a required RAID level according to a service requirement, and creating a RAID volume according to the required RAID level, and obtaining an LBA address interval required to create the RAID volume further includes: and acquiring the LBA address interval required by the creation of the RAID volume in the LAB address interval corresponding to the required RAID level.
In some embodiments, the obtaining LBA address intervals required to create the RAID volume at the LAB address intervals corresponding to the required RAID level includes: and calculating the LBA address interval required by the creation of the RAID volume according to the number and the size of the RAID required by the required RAID level.
In some embodiments, the determining whether the space of the RAID group satisfies the size of the LBA address interval required to create the RAID volume includes: and judging whether the space of the RAID group meets the size of the LBA address interval required by the creation of the RAID volume or not according to the number of the RAIDs in the RAID group.
In some embodiments, the associating the different RAID levels with the LBA address space, the performing the RAID level operations in the LBA address space comprising: and performing stripe consistency detection and formatting on the LBA address space.
Finally, it should be noted that, as one of ordinary skill in the art can appreciate that all or part of the processes of the methods of the above embodiments can be implemented by a computer program to instruct related hardware, and the program of the method for setting system parameters can be stored in a computer readable storage medium, and when executed, the program can include the processes of the embodiments of the methods as described above. The storage medium of the program may be a magnetic disk, an optical disk, a Read Only Memory (ROM), a Random Access Memory (RAM), or the like. The embodiments of the computer program may achieve the same or similar effects as any of the above-described method embodiments.
Furthermore, the methods disclosed according to embodiments of the present invention may also be implemented as a computer program executed by a processor, which may be stored in a computer-readable storage medium. Which when executed by a processor performs the above-described functions defined in the methods disclosed in embodiments of the invention.
Further, the above method steps and system elements may also be implemented using a controller and a computer readable storage medium for storing a computer program for causing the controller to implement the functions of the above steps or elements.
Those of skill would further appreciate that the various illustrative logical blocks, modules, circuits, and algorithm steps described in connection with the disclosure herein may be implemented as electronic hardware, computer software, or combinations of both. To clearly illustrate this interchangeability of hardware and software, various illustrative components, blocks, modules, circuits, and steps have been described above generally in terms of their functionality. Whether such functionality is implemented as software or hardware depends upon the particular application and design constraints imposed on the overall system. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the disclosed embodiments of the present invention.
In one or more exemplary designs, the functions may be implemented in hardware, software, firmware, or any combination thereof. If implemented in software, the functions may be stored on or transmitted over as one or more instructions or code on a computer-readable medium. Computer-readable media includes both computer storage media and communication media including any medium that facilitates transfer of a computer program from one place to another. A storage media may be any available media that can be accessed by a general purpose or special purpose computer. By way of example, and not limitation, such computer-readable media can comprise RAM, ROM, EEPROM, CD-ROM or other optical disk storage, magnetic disk storage or other magnetic storage devices, or any other medium that can be used to carry or store desired program code in the form of instructions or data structures and that can be accessed by a general-purpose or special-purpose computer, or a general-purpose or special-purpose processor. Also, any connection is properly termed a computer-readable medium. For example, if the software is transmitted from a website, server, or other remote source using a coaxial cable, fiber optic cable, twisted pair, digital Subscriber Line (DSL), or wireless technologies such as infrared, radio, and microwave, then the coaxial cable, fiber optic cable, twisted pair, D0L, or wireless technologies such as infrared, radio, and microwave are included in the definition of medium. Disk and disc, as used herein, includes Compact Disc (CD), laser disc, optical disc, digital Versatile Disc (DVD), floppy disk, blu-ray disc where disks usually reproduce data magnetically, while discs reproduce data optically with lasers. Combinations of the above should also be included within the scope of computer-readable media.
The foregoing is an exemplary embodiment of the present disclosure, but it should be noted that various changes and modifications could be made herein without departing from the scope of the present disclosure as defined by the appended claims. The functions, steps and/or actions of the method claims in accordance with the disclosed embodiments described herein need not be performed in any particular order. Furthermore, although elements of the disclosed embodiments of the invention may be described or claimed in the singular, the plural is contemplated unless limitation to the singular is explicitly stated.
It should be understood that, as used herein, the singular forms "a", "an" and "the" are intended to include the plural forms as well, unless the context clearly supports the exception. It should also be understood that "and/or" as used herein is meant to include any and all possible combinations of one or more of the associated listed items.
The numbers of the embodiments disclosed in the embodiments of the present invention are merely for description, and do not represent the merits of the embodiments.
It will be understood by those skilled in the art that all or part of the steps for implementing the above embodiments may be implemented by hardware, or may be implemented by a program instructing relevant hardware, and the program may be stored in a computer-readable storage medium, and the above-mentioned storage medium may be a read-only memory, a magnetic disk or an optical disk, etc.
Those of ordinary skill in the art will understand that: the discussion of any embodiment above is meant to be exemplary only, and is not intended to intimate that the scope of the disclosure, including the claims, of embodiments of the invention is limited to these examples; within the idea of an embodiment of the invention, also technical features in the above embodiment or in different embodiments may be combined and there are many other variations of the different aspects of the embodiments of the invention as described above, which are not provided in detail for the sake of brevity. Therefore, any omissions, modifications, substitutions, improvements, and the like that may be made without departing from the spirit and principles of the embodiments of the present invention are intended to be included within the scope of the embodiments of the present invention.

Claims (15)

1. A method for allocating capacity space of a RAID, comprising:
establishing the relation between different RAID levels and an LBA address space, and executing the RAID level operation in the LBA address space;
acquiring a required RAID level according to business requirements, and creating a RAID volume according to the required RAID level to obtain an LBA address interval required by the creation of the RAID volume;
judging whether the space of the RAID group meets the size of the LBA address interval required by the creation of the RAID volume;
and in response to that the space of the RAID group meets the size of the LBA address interval required for creating the RAID volume, mapping the LBA address interval required for creating the RAID volume to namespace, and completing the creation of the RAID volume required by the service requirement.
2. The method of claim 1, further comprising:
and in response to that the space of the RAID group does not meet the size of the LBA address interval, not creating a corresponding RAID volume according to the required RAID level.
3. The method of claim 1, wherein the obtaining a required RAID level according to a business requirement, and creating a RAID volume according to the required RAID level, and obtaining an LBA address interval required to create the RAID volume includes:
and acquiring the LAB address interval corresponding to the required RAID level according to the relation between the different RAID levels and the LBA address space.
4. The method according to claim 3, wherein the obtaining a required RAID level according to a business requirement, and creating a RAID volume according to the required RAID level, and obtaining an LBA address interval required to create the RAID volume further comprises:
and acquiring the LBA address interval required for creating the RAID volume in the LAB address interval corresponding to the required RAID level.
5. The method of claim 4, wherein obtaining the LBA address interval required to create the RAID volume in the LAB address interval corresponding to the required RAID level comprises:
and calculating the LBA address interval required by the creation of the RAID volume according to the number and the size of the RAID required by the required RAID level.
6. The method of claim 5, wherein determining whether the space of the RAID group satisfies the size of the LBA address interval required to create the RAID volume comprises:
and judging whether the space of the RAID group meets the size of the LBA address interval required by the creation of the RAID volume or not according to the number of the RAIDs in the RAID group.
7. The method of claim 1, wherein associating different RAID levels with LBA address space in which performing RAID level operations comprises:
and performing stripe consistency detection and formatting on the LBA address space.
8. An apparatus for allocating capacity space of a RAID, comprising:
the first module is configured to establish the relation between different RAID levels and the LBA address space, and execute RAID level operation in the LBA address space;
the second module is configured to acquire a required RAID level according to a service requirement, and create a RAID volume according to the required RAID level to acquire an LBA address interval required for creating the RAID volume;
the third module is configured to determine whether the space of the RAID group satisfies the size of the LBA address interval required to create the RAID volume;
and the fourth module is configured to respond that the space of the RAID group meets the size of the LBA address interval required for creating the RAID volume, map the LBA address interval required for creating the RAID volume to namespace, and complete the creation of the RAID volume required by the service requirement.
9. The apparatus of claim 8, further comprising:
and a fifth module, configured to respond that the space of the RAID group does not satisfy the size of the LBA address interval, and not create a corresponding RAID volume according to the required RAID level.
10. The apparatus of claim 8, wherein the second module is further configured to: and acquiring the LAB address interval corresponding to the required RAID level according to the relation between the different RAID levels and the LBA address space.
11. The apparatus of claim 10, wherein the second module is further configured for:
and acquiring the LBA address interval required by the creation of the RAID volume in the LAB address interval corresponding to the required RAID level.
12. The apparatus of claim 11, wherein the second module is further configured to:
and calculating the LBA address interval required for creating the RAID volume according to the number and the size of the RAID required by the required RAID level.
13. The apparatus of claim 12, wherein the third module is further configured for:
and judging whether the space of the RAID group meets the size of the LBA address interval required by the creation of the RAID volume or not according to the number of the RAIDs in the RAID group.
14. A computer device, comprising:
at least one processor; and
a memory storing computer instructions executable on the processor, the instructions when executed by the processor implementing the steps of the method of any one of claims 1 to 7.
15. A computer-readable storage medium, in which a computer program is stored which, when being executed by a processor, carries out the steps of the method according to any one of claims 1 to 7.
CN202211431867.3A 2022-11-16 2022-11-16 Method, device, equipment and medium for allocating RAID (redundant array of independent disks) capacity space Active CN115639968B (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN202211431867.3A CN115639968B (en) 2022-11-16 2022-11-16 Method, device, equipment and medium for allocating RAID (redundant array of independent disks) capacity space
PCT/CN2023/115586 WO2024103901A1 (en) 2022-11-16 2023-08-29 Method and apparatus for allocating capacity space of raid, device and medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202211431867.3A CN115639968B (en) 2022-11-16 2022-11-16 Method, device, equipment and medium for allocating RAID (redundant array of independent disks) capacity space

Publications (2)

Publication Number Publication Date
CN115639968A CN115639968A (en) 2023-01-24
CN115639968B true CN115639968B (en) 2023-02-28

Family

ID=84949687

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202211431867.3A Active CN115639968B (en) 2022-11-16 2022-11-16 Method, device, equipment and medium for allocating RAID (redundant array of independent disks) capacity space

Country Status (2)

Country Link
CN (1) CN115639968B (en)
WO (1) WO2024103901A1 (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115639968B (en) * 2022-11-16 2023-02-28 苏州浪潮智能科技有限公司 Method, device, equipment and medium for allocating RAID (redundant array of independent disks) capacity space

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109324762A (en) * 2018-10-11 2019-02-12 郑州云海信息技术有限公司 A kind of construction method of storage system, device, equipment and storage medium
CN110933048A (en) * 2019-11-14 2020-03-27 北京卓讯科信技术有限公司 Method and equipment for identifying abnormal application operation based on message
CN114064662A (en) * 2022-01-13 2022-02-18 北京中交兴路信息科技有限公司 Method, device, electronic equipment and medium for querying data

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6098119A (en) * 1998-01-21 2000-08-01 Mylex Corporation Apparatus and method that automatically scans for and configures previously non-configured disk drives in accordance with a particular raid level based on the needed raid level
CN101510145B (en) * 2009-03-27 2010-08-25 杭州华三通信技术有限公司 Storage system management method and apparatus
CN108733309B (en) * 2017-04-17 2021-06-11 伊姆西Ip控股有限责任公司 Storage management method, apparatus and computer readable medium
CN114415968B (en) * 2022-01-26 2023-04-07 南京晓庄学院 Storage system and data writing method thereof
CN115639968B (en) * 2022-11-16 2023-02-28 苏州浪潮智能科技有限公司 Method, device, equipment and medium for allocating RAID (redundant array of independent disks) capacity space

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109324762A (en) * 2018-10-11 2019-02-12 郑州云海信息技术有限公司 A kind of construction method of storage system, device, equipment and storage medium
CN110933048A (en) * 2019-11-14 2020-03-27 北京卓讯科信技术有限公司 Method and equipment for identifying abnormal application operation based on message
CN114064662A (en) * 2022-01-13 2022-02-18 北京中交兴路信息科技有限公司 Method, device, electronic equipment and medium for querying data

Also Published As

Publication number Publication date
CN115639968A (en) 2023-01-24
WO2024103901A1 (en) 2024-05-23

Similar Documents

Publication Publication Date Title
CN102937882B (en) To effective access with the memory device using bitmap
CN102929786B (en) The volatile memory of non-volatile memory device set represents
US7594075B2 (en) Metadata for a grid based data storage system
JP4733461B2 (en) Computer system, management computer, and logical storage area management method
US20030065617A1 (en) Method of billing for utilization of a data storage array, and an array controller therefor
US7587553B2 (en) Storage controller, and logical volume formation method for the storage controller
US8095752B2 (en) Storage access device issuing I/O requests, in an associated logical unit environment
US8037273B2 (en) Storage system logical storage area allocating method and computer system
CN102096557B (en) Capacity expansion method, device and system for independent redundant array of inexpensive disc (RAID)
CN110096227B (en) Data storage method, data processing device, electronic equipment and computer readable medium
CN101976181A (en) Management method and device of storage resources
US8032784B2 (en) Duplication combination management program, duplication combination management apparatus, and duplication combination management method
CN104408091A (en) Data storage method and system for distributed file system
JP2001067187A (en) Storage sub-system and its control method
CN101827121A (en) Method, service end and system for creating files in RAID (Redundant Array of Independent Disk)
CN111857572B (en) Data writing method, device and equipment of TLC solid state disk and storage medium
US11385823B2 (en) Method, electronic device and computer program product for rebuilding disk array
US20200348857A1 (en) Method, apparatus and computer program product for managing disk array
CN115639968B (en) Method, device, equipment and medium for allocating RAID (redundant array of independent disks) capacity space
US20160259598A1 (en) Control apparatus, control method, and control program
CN115599313B (en) Disk array capacity expansion method, system, storage medium and equipment
US20070233952A1 (en) System environment setting support program, system environment setting support method, and system environment setting support apparatus
CN110007858B (en) Storage space allocation method and device
CN110147203A (en) A kind of file management method, device, electronic equipment and storage medium
CN109669621A (en) A kind of file management method, file management system, electronic equipment and storage medium

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