A storage resource configuration method and device
By dividing hardware storage resources into multiple storage capacities and determining initial availability levels in the blockchain storage system, and optimizing storage resource configuration using DN-RAID technology, the contradiction between data reliability and storage resource utilization is resolved, achieving efficient storage resource utilization.
Patent Information
- Application Number
- CN201811271610.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2018-10-29
- Publication Date
- 2026-01-23
- Estimated Expiration
- 2038-10-29
AI Technical Summary
How to improve the utilization rate of blockchain storage resources while ensuring data reliability, especially when storage resource costs are rising and demand is increasing?
After acquiring hardware storage resources, the hardware storage resources are divided according to preset rules to obtain virtual storage resources with various storage capacities and determine their initial availability level. Then, using DN-RAID technology, virtual storage resources that meet the disk creation request are selected to create a distributed independent disk redundancy array, thereby optimizing the storage resource configuration.
While ensuring data reliability, it improves the utilization rate of storage resources, solves the utilization problem when storage resource costs and demand increase, and provides a highly reliable and high-performance storage solution.
Smart Images

Figure CN109634518B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] Embodiments of the present application relate to the field of cloud storage, and in particular to a storage resource configuration method and device. BACKGROUND
[0002] Blockchain is a new application mode of computer technologies such as distributed data storage, peer-to-peer transmission, consensus mechanism, and encryption algorithm. In recent years, blockchain technology has been increasingly applied in various industries. For example, cloud storage is built on the basis of blockchain. Specifically, by issuing equivalent virtual currencies, a large number of personal computer (PC) users are attracted to contribute idle storage resources and network bandwidth, and a network distributed storage resource pool is built.
[0003] Since the nodes in the distributed storage network based on blockchain are all non-dedicated servers and non-dedicated storage devices, the reliability of a single node is very poor. In order to improve the reliability of the distributed storage network, the prior art adopts the following ways: 1. Through a downtime penalty measure (for example, when the storage resources and network bandwidth contributed by a PC user are unavailable, the virtual currency income thereof is deducted), the node offline caused by active shutdown and service stop is reduced; 2. Through a multi-copy storage mode, the availability of data is ensured.
[0004] Currently, an operating company can obtain a large amount of storage resources provided by PC users by issuing virtual currencies, and the cost of storage resources is very low, and the users using the blockchain storage resources are still relatively few. Therefore, the multi-copy storage mode can meet the data reliability requirements in a period of time. However, storage resources are limited, and as the number of users using storage resources increases, the cost of storage resources will also increase accordingly, so the multi-copy storage mode will not be able to meet the data reliability needs of future development. Therefore, when the cost of storage resources rises and the demand for storage resources increases, how to improve the utilization rate of storage resources while ensuring data reliability is a problem to be solved. SUMMARY
[0005] Embodiments of the present application provide a storage resource configuration method and device, which solve the problem of how to improve the utilization rate of storage resources while ensuring data reliability.
[0006] To achieve the above object, the embodiments of the present application adopt the following technical solutions:
[0007] In a first aspect, an embodiment of the present application provides a storage resource configuration method. The method can be applied to a storage resource configuration device, or the method can be applied to a communication device that can support the storage resource configuration device to implement the method, for example, the communication device includes a chip system. The method includes: after obtaining a hardware storage resource, first dividing the hardware storage resource according to a preset rule to obtain virtual storage resources of n storage capacities, and determining initial available levels of the virtual storage resources of the n storage capacities, wherein the number of virtual storage resources of the i-th storage capacity in the virtual storage resources of the n storage capacities is x i , i is an integer, i takes 1 to n, n is an integer greater than or equal to 1, and the number of the virtual storage resources of the n storage capacities can be the same or different; then, according to disk establishment request information, a j-th virtual storage resource available level, and a distributed network redundant array of independent disks (DN-RAID) technology, virtual storage resources meeting the disk establishment request information are determined from the virtual storage resources of the n storage capacities to create a DN-RAID, the disk establishment request information includes available level request information and storage capacity request information, and the j-th virtual storage resource available level is an available level corresponding to the virtual storage resource of the storage capacity indicated by the storage capacity request information. The storage resource configuration method provided by the present application divides the hardware storage resource according to the preset rule to obtain virtual storage resources of multiple storage capacities, and initializes the available levels of the virtual storage resources, so as to select virtual storage resources meeting the available level request information and the storage capacity request information from the virtual storage resources of the multiple storage capacities when the DN-RAID is constructed. Thus, the utilization rate of the storage resource is improved on the premise of ensuring data reliability.
[0008] In combination with the first aspect, in a possible implementation manner, dividing the hardware storage resource according to the preset rule to obtain the virtual storage resources of the n storage capacities includes: dividing the hardware storage resource according to a maximum storage unit capacity value, a minimum storage unit capacity value, and a storage unit capacity ratio value to obtain the virtual storage resources of the n storage capacities, wherein the relationship among the maximum storage unit capacity value, the minimum storage unit capacity value, and the storage unit capacity ratio value is Y = Z m *X, wherein Y represents the maximum storage unit capacity value, X represents the minimum storage unit capacity value, Z represents the storage unit capacity ratio value, and m is an integer greater than or equal to 0.
[0009] For example, the maximum storage unit capacity value is 1024 GB, the minimum storage unit capacity value is 4 GB, and the storage unit capacity ratio value is 4.
[0010] With reference to the first aspect or possible implementation manners thereof, in a possible implementation manner, after determining the initial available level of the virtual storage resource of the i-th storage capacity, the method further comprises: determining an available duration ratio of the virtual storage resource of the i-th storage capacity according to the available duration of the virtual storage resource of the i-th storage capacity and a preset duration; and updating the available level of the virtual storage resource of the i-th storage capacity according to the available duration ratio of the virtual storage resource of the i-th storage capacity and a preset available level.
[0011] With reference to the possible implementation manners above, in a possible implementation manner, the determining the virtual storage resource creating the DN-RAID from the virtual storage resources of the n storage capacities according to the disk establishment request information, the j-th virtual storage resource available level and the DN-RAID technology comprises: determining the number of virtual storage resources corresponding to the storage capacity request information according to the available level request information and the j-th virtual storage resource available level, the j-th virtual storage resource available level being the initial available level or the updated available level of the virtual storage resource of the storage capacity indicated by the storage capacity request information; and creating the DN-RAID according to the number of virtual storage resources.
[0012] In a second aspect, an embodiment of the present application provides a storage resource configuration apparatus for implementing the method described in the first aspect. The storage resource configuration apparatus can be a terminal device or a communication apparatus supporting the terminal device to implement the method described in the first aspect, for example, the communication apparatus includes a chip system. For example, the storage resource configuration apparatus includes a processing unit. The processing unit is configured to divide hardware storage resources according to a preset rule to obtain n virtual storage resources of storage capacities, the number of virtual storage resources of the i-th storage capacity in the n virtual storage resources of storage capacities being x i, i is an integer, i is 1 to n, n is an integer greater than or equal to 1; the processing unit is further configured to determine the initial available level of the virtual storage resource of the i-th storage capacity; the processing unit is further configured to determine the DN-RAID created from the virtual storage resource of the n storage capacities according to the disk establishment request information, the j-th virtual storage resource available level and the distributed network attached storage redundant array of independent disks DN-RAID technology, the disk establishment request information includes the available level request information and the storage capacity request information, and the j-th virtual storage resource available level is the available level corresponding to the virtual storage resource of the storage capacity indicated by the storage capacity request information. The storage resource configuration device provided in the embodiment of the application divides the hardware storage resource according to the preset rule, obtains the virtual storage resource of the n storage capacities, and initializes the available level of the virtual storage resource, so as to select the virtual storage resource meeting the available level request information and the storage capacity request information from the virtual storage resource of the n storage capacities when the DN-RAID is constructed. Therefore, the utilization rate of the storage resource is improved on the premise of ensuring data reliability.
[0013] With reference to the second aspect, in a possible implementation, the processing unit is configured to: divide the hardware storage resource according to the maximum storage unit capacity value, the minimum storage unit capacity value and the storage unit capacity ratio value to obtain the virtual storage resource of the n storage capacities, wherein the relationship among the maximum storage unit capacity value, the minimum storage unit capacity value and the storage unit capacity ratio value is Y = Z m *X, wherein Y represents the maximum storage unit capacity value, X represents the minimum storage unit capacity value, Z represents the storage unit capacity ratio value, and m is an integer greater than or equal to 0.
[0014] For example, the maximum storage unit capacity value is 1024 GB, the minimum storage unit capacity value is 4 GB, and the storage unit capacity ratio value is 4.
[0015] With reference to the second aspect or the possible implementation, in another possible implementation, the processing unit is further configured to: determine the available duration ratio value of the virtual storage resource of the i-th storage capacity according to the available duration of the virtual storage resource of the i-th storage capacity and the preset duration; and update the available level of the virtual storage resource of the i-th storage capacity according to the available duration ratio value of the virtual storage resource of the i-th storage capacity and the preset available level.
[0016] In combination with the possible implementation manners above, in another possible implementation manner, the processing unit is configured to: determine the number of virtual storage resources corresponding to the storage capacity request information according to the available level request information and the jth virtual storage resource available level, the jth virtual storage resource available level being the initial available level or the updated available level of the virtual storage resource corresponding to the storage capacity indicated by the storage capacity request information; and create the DN-RAID according to the number of virtual storage resources.
[0017] It should be noted that the functional modules of the second aspect can be implemented by hardware, or by hardware executing corresponding software. The hardware or software includes one or more modules corresponding to the functions described above. For example, the transceiver is configured to complete the functions of the receiving unit and the sending unit, the processor is configured to complete the functions of the processing unit, and the memory is configured to store the program instructions of the method of the embodiments of the present application. The processor, the transceiver, and the memory are connected by a bus and complete communication with each other. Specifically, reference can be made to the functions of the behaviors of the storage resource configuration apparatus in the method of the first aspect.
[0018] In a third aspect, the embodiments of the present application further provide a storage resource configuration apparatus for implementing the method described in the first aspect. The storage resource configuration apparatus is a terminal device or a communication apparatus supporting the terminal device to implement the method described in the first aspect, for example, the communication apparatus includes a chip system. For example, the storage resource configuration apparatus includes a processor configured to implement the functions of the method described in the first aspect. The communication apparatus can further include a memory configured to store program instructions and data. The memory is coupled to the processor, and the processor can invoke and execute the program instructions stored in the memory to implement the functions in the method described in the first aspect. The storage resource configuration apparatus can further include a communication interface configured to enable the communication apparatus to communicate with other devices. Exemplarily, if the storage resource configuration apparatus is a terminal device, the other device is a network device.
[0019] In a possible device, the storage resource configuration apparatus includes: a communication interface configured to enable the storage resource configuration apparatus to communicate with other devices. Exemplarily, the communication interface can be a transceiver. A memory configured to store program instructions. A processor configured to, after obtaining the hardware storage resources, first divide the hardware storage resources according to a preset rule to obtain n kinds of virtual storage resources with different storage capacities, and determine the initial available levels of the n kinds of virtual storage resources with different storage capacities, wherein the number of the ith virtual storage resource with different storage capacity in the n kinds of virtual storage resources with different storage capacities is x i, i is an integer, i is 1 to n, n is an integer greater than or equal to 1, the number of n kinds of virtual storage resources with storage capacity can be the same or different; then, according to the disk establishment request information, the jth virtual storage resource available level and the DN-RAID technology, the virtual storage resource meeting the disk establishment request information is determined from the n kinds of virtual storage resources with storage capacity, and the disk establishment request information includes the available level request information and the storage capacity request information. The jth virtual storage resource available level is the available level corresponding to the virtual storage resource with the storage capacity indicated by the storage capacity request information.
[0020] Optionally, the specific method is the same as the corresponding description in the first aspect, which will not be repeated here.
[0021] In a fourth aspect, the embodiments of the present application further provide a computer readable storage medium, comprising: computer software instructions; when the computer software instructions run in the storage resource configuration device, the storage resource configuration device executes the method in the first aspect.
[0022] In a fifth aspect, the embodiments of the present application further provide a computer program product comprising instructions, when the computer program product runs in the storage resource configuration device, the storage resource configuration device executes the method in the first aspect.
[0023] In a sixth aspect, the embodiments of the present application provide a chip system, which comprises a processor and can further comprise a memory for realizing the function of the storage resource configuration device in the above method. The chip system can be composed of a chip, or can comprise a chip and other discrete devices.
[0024] In addition, the technical effects brought by the design of any of the above aspects can be referred to the technical effects brought by the different design ways in the first aspect, which will not be repeated here.
[0025] In the embodiments of the present application, the names of the storage resource configuration device, the terminal device and the communication device do not constitute a limitation to the devices themselves. In actual implementation, these devices can appear with other names. As long as the functions of the devices are similar to those in the embodiments of the present application, they belong to the scope of the claims of the present application and equivalent technologies. BRIEF DESCRIPTION OF DRAWINGS
[0026] Figure 1 A simplified example diagram of a blockchain network is provided for the prior art;
[0027] Figure 2 A simplified example diagram of a blockchain cloud storage network is provided for the prior art;
[0028] Figure 3 A logical example diagram of a blockchain cloud storage network is provided for the embodiments of the present application;
[0029] Figure 4 A flowchart of a storage resource configuration method provided for an embodiment of the present application is shown in FIG. 1.
[0030] Figure 5 A flowchart of another storage resource configuration method provided for an embodiment of the present application is shown in FIG. 2.
[0031] Figure 6 An example composition diagram of a storage resource configuration device provided for an embodiment of the present application is shown in FIG. 3.
[0032] Figure 7 An example composition diagram of another storage resource configuration device provided for an embodiment of the present application is shown in FIG. 4. DETAILED DESCRIPTION
[0033] For the sake of clear and concise description of the following embodiments, a brief introduction of the related art is given first:
[0034] A storage system based on blockchain technology is a decentralized distributed storage system that does not require a third-party central authority. The data after decomposition can be encrypted using a personal key and then dispersed throughout the network. The data can be extracted at any time when the user uses it, and the data reorganization process can also be seamlessly implemented. When the data is attacked by hackers, the hacker also needs to crack the secret key of each file. When the hacker tries to tamper with the data, the user can also retrieve the file and destroy the data at any time. Therefore, the application of blockchain technology is very helpful to the development of the cloud storage industry.
[0035] Figure 1 A simplified example diagram of a blockchain network provided for the prior art is shown in FIG. 1. The blockchain network includes a network 101 and a plurality of workstations 102. The network 101 can refer to the Internet, an operator network, a private network, etc. The network 101 includes network devices such as routers and switches. The workstation 102 can be a personal computer (PC), or a dedicated workstation or server. The network 101 can be a bridge between the workstations 102, and the workstations 102 exchange information through the network 101.
[0036] Blockchain cloud storage is based on a blockchain network, and each node provides storage and computing resources to the network to build a storage resource network. Figure 2 A simplified example diagram of a blockchain cloud storage network provided for the prior art is shown in FIG. 2. The network includes storage nodes 201, computing nodes 202, and computing and storage nodes 203.
[0037] In order to solve the problem of how to improve the utilization of storage resources while ensuring data reliability when the cost of storage resources rises and the demand for storage resources increases, the embodiment of the present application provides a storage resource configuration method, and the basic principle is: after obtaining the hardware storage resources, the hardware storage resources are divided according to the preset rules to obtain virtual storage resources of n storage capacities, and the initial available level of the virtual storage resource of the i-th storage capacity is determined, wherein the number of the virtual storage resource of the i-th storage capacity in the virtual storage resources of n storage capacities is x i , i is an integer, i takes 1 to n, n is an integer greater than or equal to 1, and the number of the virtual storage resources of n storage capacities can be the same or different; then, the virtual storage resource meeting the disk establishment request information is determined from the virtual storage resources of n storage capacities according to the disk establishment request information, the available level of the j-th virtual storage resource and the DN-RAID technology, the disk establishment request information includes available level request information and storage capacity request information, and the available level of the j-th virtual storage resource is the available level corresponding to the virtual storage resource of the storage capacity indicated by the storage capacity request information. The storage resource configuration method provided by the embodiment of the present application divides the hardware storage resources according to the preset rules to obtain virtual storage resources of multiple storage capacities, and initializes the available level of the virtual storage resource, so as to select the virtual storage resource meeting the available level request information and the storage capacity request information from the virtual storage resources of multiple storage capacities when constructing the DN-RAID. Thus, the utilization of the storage resources is improved while ensuring the data reliability.
[0038] The implementation of the embodiment of the present application will be described in detail below with reference to the accompanying drawings.
[0039] Figure 3A logical example diagram of a blockchain cloud storage network is provided for the embodiments of the present application. The blockchain cloud storage network includes a physical topology layer 301, a resource topology layer 302, a resource management layer 303, and a user layer 304. The physical topology layer 301 includes physical devices that provide hardware storage resources and hardware computing resources, and the physical devices can be a PC. The resource topology layer 302 includes hardware storage resources and hardware computing resources. In the resource topology layer 302, the hardware resources can be divided according to their functions, i.e., resources providing computing functions are divided into hardware computing resources, and resources providing storage functions are divided into hardware storage resources. The resource management layer 303 is used for logical management of the hardware storage resources and the hardware computing resources. The application scenario of the present application is in the field of blockchain cloud storage, i.e., in a blockchain cloud storage network, according to the preset rules provided by the embodiments of the present application, the hardware storage resources are divided to obtain virtual storage resources of n storage capacities, and the initial available levels of each virtual storage resource are determined, so that users can select virtual storage resources that meet the available level request information and the storage capacity request information from the virtual storage resources of multiple storage capacities, and build a distributed storage network based on blockchain. Thus, the utilization rate of storage resources is improved while ensuring data reliability. The user layer 304 includes the physical form of virtual storage resources, which can be a database or a PC.
[0040] Figure 4 A flowchart of a storage resource configuration method is provided for the embodiments of the present application, as shown in Figure 4 The method can include:
[0041] S401, according to the preset rules, the hardware storage resources are divided to obtain virtual storage resources of n storage capacities.
[0042] It can be understood that each virtual storage resource can be regarded as a unit disk. The unit disk is a hardware storage resource provided by a storage node, which is divided into one or more storage units according to the preset rules, and each storage unit is a unit disk. The storage capacities of the plurality of storage units can be completely the same. Of course, the storage capacities of the plurality of storage units can also be completely different, i.e., the storage capacities of each storage unit are different. The storage capacities of the plurality of storage units can also not be completely the same, i.e., the storage capacities of at least two storage units in the plurality of storage units are the same.
[0043] According to preset rules, hardware storage resources can be divided into n virtual storage resources with different storage capacities, where n is an integer greater than or equal to 1. For example, when n = 1, it means that the hardware storage resources are divided according to the preset rules, resulting in one type of virtual storage resource with different storage capacities. When n is greater than or equal to 2, it means that the hardware storage resources are divided according to the preset rules, resulting in two or more types of virtual storage resources with different storage capacities. The number of virtual storage resources with different storage capacities of n can be the same or different. The number of virtual storage resources of the i-th type among the n types of virtual storage resources is x. i Let i be an integer, ranging from 1 to n. That is, the number of the first type of virtual storage resource is x1, the number of the second type of virtual storage resource is x2, and so on, up to the number of the nth type of virtual storage resource being x. n .
[0044] For example, hardware storage resources can be partitioned based on the maximum capacity of a storage unit, the minimum capacity of a storage unit, and the ratio of storage unit capacities to obtain virtual storage resources with n different storage capacities. The relationship between the maximum capacity of a storage unit, the minimum capacity of a storage unit, and the ratio of storage unit capacities is: Y = Z. m *X, where Y represents the maximum capacity of a storage unit, X represents the minimum capacity of a storage unit, Z represents the ratio of storage unit capacities, and m is an integer greater than or equal to 0. The total storage capacity of the partitioned hardware storage resources can be expressed by the formula: Where, x i x represents the number of virtual storage resources of the i-th storage capacity. i x needs to be satisfied i <Z. u i u represents the storage capacity of the i-th type of virtual storage resource. i =Z i *X. Q represents the total storage capacity of the partitioned hardware storage resources, i.e., the hardware storage resources include x. i Block size is u i For virtual storage resources Q, Q needs to satisfy Q≤P<Q+u i P represents the storage capacity of the hardware storage resources.
[0045] Assuming the minimum storage unit capacity is 4GB, the storage unit capacity ratio is 4, and the maximum storage unit capacity is 1024GB, according to Y=Z m *X can divide hardware storage resources into virtual storage resources of 5 different storage capacities. When m=0, Y=Z m *X=1*4=4, meaning the storage capacity of the first type of virtual storage resource is 4GB; when m=1, Y=Z m *X = 4 * 4 = 16, meaning the storage capacity of the second type of virtual storage resource is 16GB; when m = 2, Y = Z m*X = 16 * 4 = 64, i.e. the storage capacity of the third kind of virtual storage resource is 64 GB; when m = 3, Y = Z m *X = 64 * 4 = 256, i.e. the storage capacity of the fourth kind of virtual storage resource is 256 GB; when m = 4, Y = Z m *X = 256 * 4 = 1024, i.e. the storage capacity of the first kind of virtual storage resource is 1024 GB.
[0046] It is assumed that the division result of the hardware storage resource can be represented as [x1, x2, x3, x4, x5]. For example, for a hardware storage resource with a storage capacity of 100 GB, it can be divided into 1 4 GB virtual storage resource, 2 16 GB virtual storage resources, and 1 64 GB virtual storage resource, and the division result can be represented as [1, 2, 1, 0, 0]. For a hardware storage resource with a storage capacity of 200 GB, it can be divided into 2 4 GB virtual storage resources and 3 64 GB virtual storage resources, and the division result can be represented as [2, 0, 3, 0, 0]. For a hardware storage resource with a storage capacity of 300 GB, it can be divided into 3 4 GB virtual storage resources, 2 16 GB virtual storage resources, and 1 256 GB virtual storage resource, and the division result can be represented as [3, 2, 0, 1, 0]. For a hardware storage resource with a storage capacity of 400 GB, it can be divided into 1 16 GB virtual storage resource, 2 64 GB virtual storage resources, and 1 256 GB virtual storage resource, and the division result can be represented as [0, 1, 2, 1, 0]. For a hardware storage resource with a storage capacity of 600 GB, it can be divided into 1 16 GB virtual storage resource, 1 64 GB virtual storage resource, and 2 256 GB virtual storage resources, and the division result can be represented as [0, 1, 1, 2, 0]. For a hardware storage resource with a storage capacity of 700 GB, it can be divided into 3 4 GB virtual storage resources, 3 16 GB virtual storage resources, 2 64 GB virtual storage resources, and 2 256 GB virtual storage resources, and the division result can be represented as [3, 3, 2, 2, 0]. For a hardware storage resource with a storage capacity of 1 TB (1024 GB), it can be divided into 1 1024 GB virtual storage resource, and the division result can be represented as [0, 0, 0, 0, 1]. For a hardware storage resource with a storage capacity of 2 TB (2048 GB), it can be divided into 2 1024 GB virtual storage resources, and the division result can be represented as [0, 0, 0, 0, 2]. The storage resource pool of the blockchain-based distributed storage network obtained after the division of the hardware storage resources with the above respective storage capacities includes 9 4 GB virtual storage resources, 9 16 GB virtual storage resources, 9 64 GB virtual storage resources, 6 256 GB virtual storage resources, and 3 1 TB virtual storage resources.
[0047] S402, determining an initial available level of the i-th virtual storage resource of the storage capacity.
[0048] The available level can refer to a level of the availability of the virtual storage resource. The availability can refer to a ratio of a normal use duration of the virtual storage resource within a preset duration to the preset duration. The preset duration can be one month or half a year, etc.
[0049] The preset available level can include -4, -3, -2, -1, 0, 1, 2, 3, 4, 5, and 6. The availability of -4 is lower than 30%. The availability of -3 satisfies [30%, 50%). The availability of -2 satisfies [50%, 70%). The availability of -1 satisfies [70%, 80%). The availability of 0 satisfies [80%, 90%). The availability of 1 satisfies [90%, 99%). The availability of 2 satisfies [99%, 99.9%). The availability of 3 satisfies [99.9%, 99.99%). The availability of 4 satisfies [99.99%, 99.999%). The availability of 5 satisfies [99.999%, 99.9999%). The availability of 6 is greater than or equal to 99.9999%.
[0050] After the virtual storage resources of n storage capacities are divided according to the preset rule, the available levels of the virtual storage resources of n storage capacities are initialized. For any virtual storage resource of n storage capacities, the initialization can be performed according to the following manner. When initializing the i-th virtual storage resource, a relatively low initial available level can be set for the i-th virtual storage resource, for example, the initial available level of the i-th virtual storage resource can be -3. Alternatively, when setting the initial available level for the i-th virtual storage resource, the available level information of the virtual storage resource provided by a user can also be referred to.
[0051] S403, determining a DN-RAID that meets the disk establishment request information from the virtual storage resources of n storage capacities according to the disk establishment request information, the j-th virtual storage resource available level, and the DN-RAID technology.
[0052] The disk establishment request information includes available level request information and storage capacity request information. The j-th virtual storage resource available level is the available level corresponding to the virtual storage resource of the storage capacity indicated by the storage capacity request information. For example, the j-th virtual storage resource available level is the initial available level corresponding to the virtual storage resource of the storage capacity indicated by the storage capacity request information.
[0053] The number of virtual storage resources corresponding to the storage capacity request information can be determined according to the available level of the virtual storage resource corresponding to the storage capacity indicated by the available level request information and the storage capacity request information, and then the DN-RAID is created according to the number of virtual storage resources. It should be noted that when the unit disk is selected according to the storage capacity indicated by the storage capacity request information, the unit disk can be intelligently selected according to the unit disk topology information. For example, the unit disks distributed on different storage nodes in the blockchain cloud storage network are selected according to the unit disk topology information, and the DN-RAID is created, so as to further improve the reliability of the DN-RAID, and avoid affecting the reliability of the DN-RAID by selecting the unit disks on the same storage node. In addition, the DN-RAID level can be intelligently selected according to the available level request information, and the DN-RAID is constructed. For example, the unit disks are grouped into a disk array through the DN-RAID technology, the performance can be improved through data striping, and the reliability can be improved through data mirroring. The disk formed by grouping the unit disks through the DN-RAID has high availability and high performance, for example, a high-availability network disk (HAND). The DN-RAID level includes six levels, such as DN-RAID0 level, DN-RAID1 level, DN-RAID2 level, DN-RAID3 level, DN-RAID4 level and DN-RAID5 level.
[0054] An example is taken to illustrate the process of establishing the DN-RAID, taking a 4-level available disk with a capacity of 256GB as an example (the performance improvement through striping is not considered here). The DN-RAID1 is created, and all the 256GB unit disks are selected. The initial availability level of the 256GB unit disk is-2 level, and the minimum availability corresponding to the-2 level is 50%. Therefore, the availability of the DN-RAID1 formed by K disks is A = 1-(1-50%) K The array with a 4-level availability needs to be created, and the minimum availability corresponding to the 4 level is 99.99%. Therefore, A ≥ 99.99%, and the value of A is substituted into A = 1-(1-50%) K The calculation result is K ≥ 7, so at least 7 pieces of 256GB unit disks should be selected to form the DN-RAID1. That is, the DN-RAID1 formed by at least 7 pieces of 256GB unit disks can provide an available disk with a 4-level availability and a capacity of 256GB.
[0055] Further, after determining the initial availability level of the virtual storage resource of the i-th storage capacity, the availability level of the virtual storage resource of the i-th storage capacity can be updated according to the available duration of the virtual storage resource of the i-th storage capacity. As shown in Figure 5 The embodiment of the present application can further include the following steps.
[0056] S501, determining the available duration ratio of the virtual storage resource of the i-th storage capacity according to the available duration of the virtual storage resource of the i-th storage capacity and the preset duration.
[0057] The preset duration can be one month, that is, the virtual storage resource of the i-th storage capacity can be evaluated every month to update the available level of the virtual storage resource of the i-th storage capacity. The evaluation formula can be: wherein H(t) represents the available duration ratio of the virtual storage resource of the i-th storage capacity in the t-th month, s t represents the available duration of the virtual storage resource of the i-th storage capacity in the t-th month, and l t represents the duration of the t-th month.
[0058] S502, updating the available level of the i-th virtual storage resource according to the available duration ratio of the virtual storage resource of the i-th storage capacity and the preset available level.
[0059] The available duration ratio of the virtual storage resource of the i-th storage capacity is compared with the availability range corresponding to the preset available level, and the available level corresponding to the availability range including the available duration ratio of the virtual storage resource of the i-th storage capacity is determined as the updated available level of the virtual storage resource of the i-th storage capacity.
[0060] It should be noted that the order of the steps of the storage resource configuration method provided by the embodiments of the present application can be adjusted appropriately, and the steps can also be increased or decreased accordingly according to the circumstances. For example, the order of S501 to S502 and S403 can be interchanged, that is, S501 to S502 can be executed before S403. After updating the available level of the virtual storage resource of the i-th storage capacity according to the available duration ratio of the virtual storage resource of the i-th storage capacity and the preset available level, the virtual storage resource meeting the disk establishment request information is determined from the n virtual storage resources according to the disk establishment request information, the j-th virtual storage resource available level and the DN-RAID technology to create a DN-RAID, and the j-th virtual storage resource available level can be the updated available level corresponding to the virtual storage resource of the storage capacity indicated by the storage capacity request information. Any person skilled in the art within the technical scope disclosed by the present application can easily think of various methods, which shall be covered within the protection scope of the present application, and therefore will not be described here.
[0061] The storage resource configuration method provided in the embodiments of the present application divides the hardware storage resources according to a preset rule, obtains virtual storage resources of multiple storage capacities, and initializes the available levels of the virtual storage resources, so as to select the virtual storage resources meeting the available level request information and the storage capacity request information from the virtual storage resources of multiple storage capacities when constructing a DN-RAID. In this way, the blockchain storage resources with high reliability and high performance are provided at the lowest cost, the utilization rate of the storage resources is effectively improved, and the contradiction between reliability and cost is solved.
[0062] The above mainly introduces the scheme provided in the embodiments of the present application from the perspective of interaction between network elements. It can be understood that each network element, for example, the storage resource configuration apparatus, contains a hardware structure and / or a software module for executing each function. Those skilled in the art should easily realize that, in combination with the algorithm steps of each example described in the embodiments disclosed in the present application, the present application can be realized in the form of hardware or a combination of hardware and computer software. Whether a certain function is executed in the form of hardware or computer software driving hardware depends on the specific application and design constraints of the technical scheme. Professional technicians can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of the present application.
[0063] The embodiments of the present application can divide the storage resource configuration apparatus into functional modules according to the above method examples. For example, each functional module can be divided according to each function, or two or more functions can be integrated into one processing module. The above integrated module can be realized in the form of hardware or software functional module. It should be noted that the division of modules in the embodiments of the present application is illustrative, and is only a logical function division. Actual implementation can have another division manner.
[0064] In the case of dividing each functional module according to each function, Figure 6 A possible composition schematic diagram of the storage resource configuration apparatus involved in the above and embodiments is shown, as shown in the figure, the storage resource configuration apparatus can include a processing unit 601. Figure 6
[0065] The processing unit 601 is configured to support the storage resource configuration apparatus to execute S401-S403 in the storage resource method shown in the figure, Figure 4 S401-S403 in the storage resource method shown in the figure, Figure 5 S401-S403 and S501-S502 in the storage resource method shown in the figure.
[0066] In the embodiments of the present application, further, as shown in the figure, Figure 6 As shown, the storage resource configuration device may further include: storage unit 602.
[0067] Storage unit 602 is used to store data.
[0068] It should be noted that all relevant content of each step involved in the above method embodiments can be referenced from the functional description of the corresponding functional module, and will not be repeated here.
[0069] The storage resource configuration apparatus provided in this application embodiment is used to execute the above-described storage resource method, and therefore can achieve the same effect as the above-described storage resource method.
[0070] like Figure 7 The diagram shows a storage resource configuration device 70 provided in an embodiment of this application, used to implement the functions of the storage resource configuration device 70 in the above-described method. The storage resource configuration device 70 can be a network device or a device within a network device. Specifically, the storage resource configuration device 70 can be a chip system. In this embodiment, the chip system can be composed of chips or may include chips and other discrete devices. Alternatively, the storage resource configuration device 70 can be a terminal device or a device within a terminal device. Again, the storage resource configuration device 70 can be a chip system. In this embodiment, the chip system can be composed of chips or may include chips and other discrete devices.
[0071] The storage resource configuration device 70 includes at least one processor 701, used to implement the functions of the storage resource configuration device 70 in the method provided in this application embodiment. Exemplarily, the processor 701 can be used to, after acquiring hardware storage resources, first divide the hardware storage resources according to preset rules to obtain n types of virtual storage resources with different storage capacities, and determine the initial availability level of the i-th type of virtual storage resource, wherein the number of virtual storage resources with the i-th type of storage capacity among the n types of virtual storage resources is x. i Let i be an integer, ranging from 1 to n, where n is an integer greater than or equal to 1. The number of virtual storage resources with n storage capacities can be the same or different. Then, based on the disk creation request information, the availability level of the j-th virtual storage resource, and the DN-RAID technology, virtual storage resources that meet the disk creation request information are selected from the virtual storage resources with n storage capacities to create DN-RAID. The disk creation request information includes availability level request information and storage capacity request information. The availability level of the j-th virtual storage resource is the availability level corresponding to the virtual storage resource with the storage capacity indicated by the storage capacity request information, etc. For details, please refer to the detailed description in the method example, which will not be repeated here.
[0072] The storage resource configuration apparatus 70 can further include at least one memory 702 for storing program instructions and / or data. The memory 702 is coupled to the processor 701. The coupling in the embodiments of the present application is indirect coupling or communication connection between apparatuses, units or modules, which can be electrical, mechanical or other forms, for information interaction between apparatuses, units or modules. The processor 701 can operate in cooperation with the memory 702. The processor 701 can execute program instructions stored in the memory 702. At least one of the at least one memory can be included in the processor.
[0073] The storage resource configuration apparatus 70 can further include a communication interface 703 for communicating with other devices through a transmission medium, so that the apparatuses in the storage resource configuration apparatus 70 can communicate with other devices. For example, if the storage resource configuration apparatus 70 is a network device, the other device is a terminal device. If the storage resource configuration apparatus 70 is a terminal device, the other device is a network device.
[0074] The specific connection medium between the communication interface 703, the processor 701 and the memory 702 is not limited in the embodiments of the present application. In the embodiments of the present application, the communication interface 703, the processor 701 and the memory 702 are connected through a bus 704, and the bus is represented by a thick line in the embodiments of the present application. The connection mode between other components is only schematically illustrated and is not limited. The bus can be divided into an address bus, a data bus, a control bus and the like. For convenience of representation, only one thick line is used to represent the bus in the embodiments of the present application, but it does not mean that there is only one bus or only one type of bus. Figure 7 Figure 7 Figure 7
[0075] In the embodiments of the present application, the processor can be a general processor, a digital signal processor, an application specific integrated circuit, a field programmable gate array or other programmable logic device, a discrete gate or transistor logic device, a discrete hardware component, which can implement or execute the disclosed methods, steps and logic block diagrams in the embodiments of the present application. The general processor can be a microprocessor or any conventional processor. The steps of the method disclosed in conjunction with the embodiments of the present application can be directly embodied as execution completed by a hardware processor, or executed by a combination of hardware and software modules in the processor.
[0076] In the embodiments of the present application, the memory can be a non-volatile memory, such as a hard disk drive (HDD) or a solid-state drive (SSD), and can also be a volatile memory, such as a random-access memory (RAM). The memory can be any other medium capable of carrying or storing desired program codes in the form of instructions or data structures and capable of being accessed by a computer, but is not limited to this. The memory in the embodiments of the present application can also be a circuit or any other device capable of realizing a storage function, for storing program instructions and / or data.
[0077] Through the above description of the embodiments, those skilled in the art can clearly understand that, for the convenience and brevity of description, only the division of the above functional modules is taken as an example, and in actual application, the above functions can be completed by different functional modules according to needs, that is, the internal structure of the device is divided into different functional modules to complete all or part of the functions described above.
[0078] In several embodiments provided in the present application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic, for example, the division of the modules or units is only a logical function division, and actual implementation can have another division manner, for example, a plurality of units or components can be combined or integrated into another device, or some features can be ignored or not executed. In addition, the coupling or direct coupling or communication connection between the units or components shown or discussed can be indirect coupling or communication connection through some interface, device or unit, and can be electrical, mechanical or other forms.
[0079] The units described as separate components can or can not be physically separated, and the components shown as units can be one physical unit or multiple physical units, that is, can be located in one place, or can be distributed to multiple different places. Part or all of the units can be selected according to actual needs to achieve the purpose of the embodiments.
[0080] In addition, each functional unit in each embodiment of the present application can be integrated in one processing unit, or each unit can exist physically, or two or more units can be integrated in one unit. The integrated unit can be realized in the form of hardware or in the form of a software functional unit.
[0081] The method provided in the embodiments of the present application can be implemented by software, hardware, firmware or any combination thereof, entirely or partially. When implemented by software, the method can be implemented in the form of a computer program product, entirely or partially. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the processes or functions described in the embodiments of the present application are entirely or partially generated. The computer can be a general-purpose computer, a special-purpose computer, a computer network, a network device, a terminal or other programmable apparatus. The computer instructions can be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another computer-readable storage medium, for example, the computer instructions can be transmitted from one website, computer, server or data center to another website, computer, server or data center through a wired (for example, coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (for example, infrared, wireless, microwave, etc.) manner. The computer-readable storage medium can be any available medium accessible by a computer or a data storage device such as a server, data center, etc. integrated with one or more available media. The available media can be a magnetic medium (for example, a floppy disk, a hard disk, a magnetic tape), an optical medium (for example, a digital video disc (DVD)), or a semiconductor medium (for example, an SSD), etc.
[0082] The above merely provides a specific implementation of the present application, but the protection scope of the present application is not limited thereto, any change or replacement within the technical scope disclosed in the present application should be covered in the protection scope of the present application. Therefore, the protection scope of the present application should be subject to the protection scope of the claims.
Claims
1. A method for configuring storage resources, characterized in that, The blockchain cloud storage network includes n types of virtual storage resources with varying storage capacities, and the method includes: Obtain disk creation request information, which includes availability level request information and storage capacity request information; determine virtual storage resources that meet the disk creation request information from the n types of virtual storage resources based on the disk creation request information, wherein the availability level of the virtual storage resource is determined based on the availability duration of the virtual storage resource, the availability level refers to the level of availability classification of the virtual storage resource, and the availability refers to the ratio of the normal usage time of the virtual storage resource within a preset duration to the preset duration, where n is an integer greater than or equal to 1; Create a distributed independent disk redundancy array (DN-RAID) based on the virtual storage resources that meet the disk creation request information.
2. The storage resource configuration method according to claim 1, characterized in that, Before obtaining the disk creation request information, the method further includes: Hardware storage resources are allocated according to preset rules to obtain virtual storage resources of the n storage capacities. The number of virtual storage resources of the i-th storage capacity among the n storage capacities is... where i is an integer, ranging from 1 to n; Determine the initial availability level of the virtual storage resource of the i-th storage capacity.
3. The storage resource configuration method according to claim 2, characterized in that, The process of dividing hardware storage resources according to preset rules to obtain virtual storage resources of the n storage capacities includes: The hardware storage resources are divided according to the maximum capacity value, the minimum capacity value, and the ratio of storage unit capacities to obtain virtual storage resources with the n storage capacities. The relationship between the maximum capacity value, the minimum capacity value, and the ratio of storage unit capacities is as follows: ,in, This indicates the maximum capacity value of the storage unit. This represents the minimum capacity value of the storage unit. This represents the ratio of the storage cell capacities, where m is an integer greater than or equal to 0.
4. The storage resource configuration method according to claim 3, characterized in that, The maximum capacity of the storage unit is 1024GB, the minimum capacity of the storage unit is 4GB, and the capacity ratio of the storage units is 4.
5. The storage resource configuration method according to any one of claims 1-4, characterized in that, The step of determining virtual storage resources that match the disk creation request information from n types of virtual storage resources based on the disk creation request information includes: Based on the storage capacity request information, determine the virtual storage resources that meet the storage capacity request information from the n types of virtual storage resources; The number of virtual storage resources corresponding to the storage capacity requested is determined based on the availability level request information and the availability level of the virtual storage resources corresponding to the storage capacity indicated by the storage capacity request information. The availability level corresponding to the virtual storage resources corresponding to the storage capacity indicated by the storage capacity request information is the initial availability level or the updated availability level.
6. The storage resource configuration method according to claim 2, characterized in that, After determining the initial availability level of the virtual storage resource of the i-th storage capacity, the method further includes: The ratio of the available duration of the virtual storage resources of the i-th storage capacity to the preset duration is determined based on the available duration of the virtual storage resources of the i-th storage capacity. The availability level of the virtual storage resource of the i-th storage capacity is updated based on the ratio of available time of the virtual storage resource of the i-th storage capacity and the preset availability level.
7. A storage resource allocation device, characterized in that, The blockchain cloud storage network includes n types of virtual storage resources with varying storage capacities, including: The acquisition unit is used to acquire disk creation request information, which includes availability level request information and storage capacity request information. The processing unit is configured to determine, based on the disk creation request information, virtual storage resources that meet the disk creation request information from the virtual storage resources of the n storage capacities. The availability level of the virtual storage resource is determined based on the availability duration of the virtual storage resource. The availability level refers to the level of availability classification of the virtual storage resource. The availability refers to the ratio of the normal usage time of the virtual storage resource within a preset duration to the preset duration, where n is an integer greater than or equal to 1. The processing unit is also configured to create a distributed independent disk redundancy array (DN-RAID) based on virtual storage resources that meet the disk creation request information.
8. The storage resource configuration device according to claim 7, characterized in that, The processing unit is further configured to partition hardware storage resources according to preset rules to obtain virtual storage resources of the n storage capacities, wherein the number of virtual storage resources of the i-th storage capacity among the n storage capacities is . where i is an integer, ranging from 1 to n; The processing unit is also used to determine the initial availability level of the virtual storage resource of the i-th storage capacity.
9. The storage resource configuration device according to claim 8, characterized in that, The processing unit is specifically used for: The hardware storage resources are divided according to the maximum capacity value, the minimum capacity value, and the ratio of storage unit capacities to obtain virtual storage resources with the n storage capacities. The relationship between the maximum capacity value, the minimum capacity value, and the ratio of storage unit capacities is as follows: ,in, This indicates the maximum capacity value of the storage unit. This represents the minimum capacity value of the storage unit. This represents the ratio of the storage cell capacities, where m is an integer greater than or equal to 0.
10. The storage resource configuration device according to claim 9, characterized in that, The maximum capacity of the storage unit is 1024GB, the minimum capacity of the storage unit is 4GB, and the capacity ratio of the storage units is 4.
11. The storage resource allocation apparatus according to any one of claims 7-10, characterized in that, The processing unit is specifically used for: Based on the storage capacity request information, determine the virtual storage resources that meet the storage capacity request information from the n types of virtual storage resources; The number of virtual storage resources corresponding to the storage capacity requested is determined based on the availability level request information and the availability level of the virtual storage resources corresponding to the storage capacity indicated by the storage capacity request information. The availability level corresponding to the virtual storage resources corresponding to the storage capacity indicated by the storage capacity request information is the initial availability level or the updated availability level.
12. The storage resource configuration device according to claim 8, characterized in that, The processing unit is further configured to: The ratio of the available duration of the virtual storage resources of the i-th storage capacity to the preset duration is determined based on the available duration of the virtual storage resources of the i-th storage capacity. The availability level of the virtual storage resource of the i-th storage capacity is updated based on the ratio of available time of the virtual storage resource of the i-th storage capacity and the preset availability level.
13. A storage resource allocation device, characterized in that, include: At least one processor, memory, bus, and transceiver, wherein the memory is used to store a computer program such that when the computer program is executed by the at least one processor, it implements the storage resource configuration method as described in any one of claims 1-6.
14. A computer-readable storage medium, characterized in that, include: Computer software instructions; When the computer software instructions are executed in the storage resource configuration device or in a chip embedded in the storage resource configuration device, the storage resource configuration device performs the storage resource configuration method as described in any one of claims 1-6.
15. A computer program product containing instructions, characterized in that, When the computer program product is run on the storage resource configuration device or in the chip built into the storage resource configuration device, it causes the storage resource configuration device to perform the storage resource configuration method as described in any one of claims 1-6.
Citation Information
Patent Citations
Method and device for initializing RAID
CN106354435A
Spatial data storage organization method and system in consideration of load balancing and disc efficiency
CN106933511A
Method for achieving global abrasion balancing
CN107665090A
A method for constructing test data hierarchy of hot spot data based on Vdbench
CN108984353A
Apparatus and method for providing redundant arrays storage devices
US20070067665A1