Data disk capacity management method and device, electronic equipment and storage medium

CN117435328BActive Publication Date: 2026-08-18RUIJIE NETWORKS CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202210831434.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-07-15
Publication Date
2026-08-18
Estimated Expiration
2042-07-15

AI Technical Summary

Technical Problem

然而,在有些应用场景中,由于企业在信息化建设的不同时期采购了不同品牌、不同型号的存储硬件资源,如服务器、数据盘(泛指HDD、SSD等存储资源,在本发明中,并不区分“硬盘”和“数据盘”,以下的部分描述中会用“硬盘”代替“数据盘”)等,从而造成了存储硬件间存在着或多或少的差异

Benefits of technology

[0008] The adaptive data disk capacity management method provided in this invention has the following advantages: (1) It automatically adjusts the available capacity of a group of data disks based on the capacity value of the smallest data disk and the capacity difference threshold, so that the available capacity difference of each data disk in the group is within the set range, avoiding load imbalance caused by excessive capacity difference; (2) When the capacity of the smallest capacity disk in a group of data disks changes, it can automatically adjust the available capacity of the group of data disks based on the new capacity of the smallest capacity disk, which is highly flexible; (3) It can adjust the capacity difference threshold according to different application scenarios and system status. The storage system can automatically adjust the available capacity of the data disks according to the adjusted capacity difference threshold to adapt to different scenarios of performance priority and capacity priority, so as to ensure that the storage system has the best performance while meeting the capacity requirements.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117435328B_ABST
    Figure CN117435328B_ABST
Patent Text Reader

Abstract

The application provides a kind of adaptive data disk capacity management method, device, electronic equipment and storage medium.The data disk capacity management method includes the following steps: judging whether the capacity difference threshold of a group of data disks or the capacity of the minimum capacity disk is changed;If changed, the following steps are performed: obtaining the current capacity difference threshold and the capacity of the minimum capacity disk, calculating the available capacity limit value according to the current capacity difference threshold and the capacity of the minimum capacity disk;According to the available capacity limit value, adjust the available capacity of the data disk to be adjusted, wherein the available capacity of the data disk to be adjusted does not exceed the available capacity limit value.The method in the application limits the available capacity difference between data disks within a set range by setting the available capacity limit value, avoiding load imbalance caused by excessive capacity difference, and the method can automatically adjust with high flexibility.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of storage technology, and in particular to an adaptive data disk capacity management method, apparatus, electronic device, and storage medium. Background Technology

[0002] With the rapid development of technologies such as cloud computing and big data, data is growing explosively, leading to an ever-increasing demand for storage space and requiring storage devices to achieve higher performance to meet the real-world data storage requirements. Traditional storage systems use centralized storage servers to store all data, making these servers a bottleneck for system performance and posing reliability and security risks, thus failing to meet the demands of large-scale data storage. Current storage systems are evolving towards large-scale, distributed, and virtualized architectures.

[0003] A distributed storage system organizes fragmented hard disk space across multiple server nodes into a logically contiguous large storage space using software or other methods. Multiple storage servers collaborate to present users with a unified, virtual, single spatial view. Each independent device in a distributed storage system is called a storage node. It employs a scalable architecture, utilizing multiple storage devices to share storage tasks and leveraging location servers to locate stored information. This not only improves system reliability and access efficiency but also facilitates easy expansion.

[0004] For distributed storage systems, it is generally required that all server nodes within the cluster maintain consistent hardware configurations to fully utilize storage capacity and achieve better storage performance. However, in some application scenarios, enterprises may purchase different brands and models of storage hardware resources, such as servers and data disks (generally referring to HDDs, SSDs, and other storage resources; in this invention, the distinction between "hard disk" and "data disk" is not made, and "hard disk" will be used instead of "data disk" in the following descriptions), resulting in some degree of difference between the storage hardware.

[0005] With the continuous development of hard drive manufacturing technology, the capacity of a single hard drive has been constantly increasing. This inevitably leads to the problem of heterogeneous hard drive capacity when expanding storage systems or replacing components. However, existing storage solutions cannot effectively handle this capacity disparity, thus affecting the user experience of storage products. Furthermore, because larger capacity drives bear a heavier load, their failure rate increases, resulting in significant data security risks.

[0006] Therefore, there is an urgent need for a data disk capacity management method that can solve the storage performance impact and data security risks caused by the unbalanced load resulting from excessive capacity differences between hard drives. Summary of the Invention

[0007] To address the aforementioned technical problems, this invention provides an adaptive data disk capacity management method, characterized by comprising the following steps: determining whether the capacity difference threshold of a group of data disks or the capacity of the minimum capacity disk has changed; if no change has occurred, then no adjustment is made to the available capacity of each data disk; if a change has occurred, then the following steps are performed: obtaining the current capacity difference threshold and the capacity of the minimum capacity disk, calculating an available capacity limit value based on the current capacity difference threshold and the capacity of the minimum capacity disk; adjusting the available capacity of the data disk to be adjusted based on the available capacity limit value, wherein the available capacity of the data disk to be adjusted does not exceed the available capacity limit value.

[0008] The adaptive data disk capacity management method provided in this invention has the following advantages: (1) It automatically adjusts the available capacity of a group of data disks based on the capacity value of the smallest data disk and the capacity difference threshold, so that the available capacity difference of each data disk in the group is within the set range, avoiding load imbalance caused by excessive capacity difference; (2) When the capacity of the smallest capacity disk in a group of data disks changes, it can automatically adjust the available capacity of the group of data disks based on the new capacity of the smallest capacity disk, which is highly flexible; (3) It can adjust the capacity difference threshold according to different application scenarios and system status. The storage system can automatically adjust the available capacity of the data disks according to the adjusted capacity difference threshold to adapt to different scenarios of performance priority and capacity priority, so as to ensure that the storage system has the best performance while meeting the capacity requirements.

[0009] Preferably, the capacity difference threshold is one of the following: percentage, capacity difference, or weight.

[0010] Preferably, when the capacity difference threshold is a percentage, the available capacity limit value = the capacity of the minimum capacity disk * (1 + capacity difference threshold).

[0011] Preferably, when the capacity difference threshold is the capacity difference value, the available capacity limit value = the capacity of the smallest capacity disk + the capacity difference threshold.

[0012] Preferably, adjusting the available capacity of the data disk to be adjusted according to the available capacity limit value includes the following steps: obtaining the actual capacity of the data disk to be adjusted; determining the size of the available capacity limit value and the actual capacity of the data disk to be adjusted; if the available capacity limit value is greater than the actual capacity of the data disk to be adjusted, then the available capacity of the data disk to be adjusted is adjusted to the actual capacity of the data disk to be adjusted; if the available capacity limit value is less than the real-time capacity of the data disk to be adjusted, then the available capacity of the data disk to be adjusted is adjusted to the available capacity limit value.

[0013] Preferably, before adjusting the available capacity of the data disk to be adjusted, the following steps are included: determining whether the data disk to be adjusted meets the conditions for adjusting the available capacity; if the data disk to be adjusted meets the conditions, then the available capacity of the data disk to be adjusted is adjusted; otherwise, the available capacity of the data disk to be adjusted is not adjusted. By determining whether the data disk to be adjusted meets the conditions for adjusting the available capacity, the security of previously stored data can be better guaranteed.

[0014] Preferably, the available capacity adjustment condition is: when the actual capacity of the data disk to be adjusted exceeds the available capacity limit, the storage space beyond the available capacity limit is unused.

[0015] Preferably, the adaptive data disk capacity management method further includes the following steps: outputting at least one of the following parameters: remaining available capacity, utilization rate, and data disk status.

[0016] Preferably, the remaining available capacity is calculated using the following steps: determining whether the available capacity of the data disk after adjustment is greater than the available capacity before adjustment; if the available capacity after adjustment is greater than the available capacity before adjustment, then the remaining available capacity of the current data disk is the remaining available capacity before adjustment plus the difference between the available capacity after adjustment and the available capacity before adjustment; if the available capacity after adjustment is less than the available capacity before adjustment, then the remaining available capacity of the current data disk is the remaining available capacity before adjustment minus the difference between the available capacity before adjustment and the available capacity after adjustment.

[0017] In another aspect, the present invention provides an adaptive data disk capacity management device, characterized in that the adaptive data disk capacity management device includes a minimum capacity acquisition unit, a capacity difference threshold adjustment unit, an available capacity limit value acquisition unit, and an available capacity adjustment unit. The minimum capacity acquisition unit acquires the capacity of a set of data disks with the current minimum capacity and compares it with the capacity of a previously recorded minimum capacity disk. If the two are not equal, the available capacity of the data disk is adjusted. The capacity difference threshold adjustment unit adjusts the capacity difference threshold. When the capacity difference threshold adjustment unit adjusts the capacity difference threshold, the available capacity of the data disk is adjusted. The available capacity limit value acquisition unit calculates an available capacity limit value based on the current minimum capacity disk's capacity and the capacity difference threshold when the available capacity of the data disk is adjusted. The available capacity adjustment unit adjusts the available capacity of the data disk to be adjusted according to the available capacity limit value, wherein the available capacity of the data disk to be adjusted does not exceed the available capacity limit value.

[0018] The adaptive data disk capacity management device of the present invention has the following advantages: (1) The minimum capacity acquisition unit and the capacity difference threshold adjustment unit can detect in real time whether the minimum capacity disk and the capacity difference threshold in a group of data disks have changed. If they have changed, the available capacity adjustment unit can automatically adjust the available capacity of the group of data disks according to the current capacity value of the minimum capacity disk and the capacity difference threshold, so that the available capacity difference of each data disk in the group of data disks is within the set range, avoiding the load imbalance caused by excessive capacity difference. And because it can be adjusted automatically, it is highly flexible; (2) The capacity difference threshold can be adjusted by the capacity difference threshold adjustment unit according to different application scenarios and system status. The storage system can automatically adjust the available capacity of the data disks according to the adjusted capacity difference threshold to adapt to different scenarios of performance priority and capacity priority, so as to ensure that the storage system has the best performance while meeting the capacity requirements.

[0019] Preferably, the adaptive data disk capacity management device further includes an adjustment condition judgment unit, which is used to determine whether the data disk to be adjusted meets the adjustment conditions. If the data disk to be adjusted meets the adjustment conditions, the available capacity of the data disk to be adjusted is adjusted; otherwise, the available capacity of the data disk to be adjusted is not adjusted.

[0020] Preferably, the adjustment condition is: when the actual capacity of the data disk to be adjusted exceeds the available capacity limit, the storage space beyond the available capacity limit is unused.

[0021] Preferably, the available capacity adjustment unit is specifically used for: obtaining the actual capacity of the data disk to be adjusted; determining the size of the available capacity limit value and the actual capacity of the data disk to be adjusted; if the available capacity limit value is greater than the actual capacity of the data disk to be adjusted, then the available capacity of the data disk to be adjusted is adjusted to the actual capacity of the data disk to be adjusted; if the available capacity limit value is less than the real-time capacity of the data disk to be adjusted, then the available capacity of the data disk to be adjusted is adjusted to the available capacity limit value.

[0022] Preferably, the available capacity adjustment unit is further configured to output at least one of the following parameters: remaining available capacity, utilization rate, and data disk status.

[0023] Preferably, when the available capacity adjustment unit outputs the remaining available capacity, it is specifically used to: determine whether the available capacity of the data disk after adjustment is greater than the available capacity before adjustment; if the available capacity after adjustment is greater than the available capacity before adjustment, then the remaining available capacity of the current data disk is the remaining available capacity before adjustment plus the difference between the available capacity after adjustment and the available capacity before adjustment; if the available capacity after adjustment is less than the available capacity before adjustment, then the remaining available capacity of the current data disk is the remaining available capacity before adjustment minus the difference between the available capacity before adjustment and the available capacity after adjustment.

[0024] In another aspect, the present invention provides an electronic device, characterized in that it includes: a memory and a processor; the memory is used to store program code used during the operation of the electronic device; the processor is used to execute the program code to implement an adaptive data disk capacity management method.

[0025] In another aspect, the present invention provides a storage medium characterized in that, when the instructions in the storage medium are executed by a processor of an electronic device, the electronic device is able to execute an adaptive data disk capacity management method. Attached Figure Description

[0026] Figure 1 This is a flowchart of the data disk capacity management method provided in this invention.

[0027] Figure 2 This is a flowchart illustrating the process of adjusting the available capacity of the data disk to be adjusted in this invention.

[0028] Figure 3 A flowchart for adjusting the remaining available capacity of a data disk.

[0029] Figure 4 This is a diagram illustrating the storage space usage on two data disks.

[0030] Figure 5 A diagram illustrating the creation of a set of data disks; Figure 5 'a' is a schematic diagram showing the actual capacity of this group of data disks; Figure 5 b is a diagram showing the available capacity of each data disk after the adjustment of this group of data disks.

[0031] Figure 6 One embodiment of adding a data disk; Figure 6 'a' represents a diagram illustrating the original available capacity of the data disks in this group. Figure 6 b represents the data disk in this group of data disks after the addition of the data disk; Figure 6 c is a diagram showing the available capacity of each data disk after the adjustment of this group of data disks.

[0032] Figure 7 One embodiment of adding a data disk; Figure 7'a' represents a diagram illustrating the original available capacity of the data disks in this group. Figure 7 b represents the data disk in this group of data disks after the addition of the data disk; Figure 7 c is a diagram showing the available capacity of each data disk in this group when the available capacity of the original data disk cannot be adjusted after adding a data disk; Figure 7 d is a diagram showing the available capacity of each data disk after the adjustment of the original data disk's available capacity after adding a data disk, when the available capacity of the original data disk can be adjusted.

[0033] Figure 8 An example of removing a data disk; Figure 8 'a' represents a diagram illustrating the original available capacity of the data disks in this group. Figure 8 b represents the data disks in this group after a data disk is removed; Figure 8 c is a diagram showing the available capacity of each data disk after the adjustment of this group of data disks.

[0034] Figure 9 An example of removing a data disk; Figure 9 'a' represents a diagram illustrating the original available capacity of the data disks in this group. Figure 9 b represents the data disks in this group after a data disk is removed; Figure 9 c is a diagram showing the available capacity of each data disk after the adjustment of this group of data disks.

[0035] Figure 10 An example of changing the capacity difference threshold; Figure 10 a is a diagram showing the available capacity of the original data disks in this group of data disks; Figure 10 b is a schematic diagram showing the available capacity of each data disk after the capacity difference threshold is changed.

[0036] Figure 11 This is a schematic diagram of the data capacity disk capacity management device in this invention. Detailed Implementation

[0037] To address the impact of heterogeneous capacity disks on storage performance and data security risks, existing technologies mainly offer the following solutions: (1) Changing physical configuration: This involves directly modifying the hardware configuration to change the physical capacity of the hard drives, ensuring that the capacity of each drive remains consistent. This is an offline adjustment method, which is cumbersome, and each setting and modification requires offline operation, resulting in poor flexibility. (2) Weighting through software configuration: This involves assigning different weight values ​​to different storage resources as needed through software configuration, and designing algorithms to ensure that hard drives with higher weight values ​​are more likely to be selected, i.e., more likely to be used, thereby achieving effective control over heterogeneous storage resources, such as Ceph distributed storage. However, the problem with this method is that the higher the weight of the hard drive, the higher the probability of its use, which will increase the probability of its failure and may affect the data security of the entire storage system. Therefore, for distributed storage, especially for heterogeneous distributed storage, there is currently no good management method that can make heterogeneous distributed storage systems both flexible and secure.

[0038] To address the aforementioned issues, this invention provides an adaptive data disk capacity management method. This method automatically adjusts the available capacity of the remaining data disks based on the data disk with the smallest capacity and a capacity difference threshold within a group of data disks. This limits the difference in available capacity within a set range, thereby preventing unbalanced loads caused by excessive capacity differences. Furthermore, this method can automatically adjust the available capacity of the remaining data disks based on the smallest capacity disk or the capacity difference threshold. Therefore, this method does not require manual intervention and offers good flexibility.

[0039] Please refer to Figure 1 As shown, Figure 1This is a flowchart of a data disk capacity management method provided by the present invention. The data disk capacity management method includes step S1-1: determining whether the capacity difference threshold of a group of data disks or the capacity of the minimum capacity disk has changed; if no change has occurred, the available capacity of each data disk is not adjusted; if a change has occurred, step S1-2 is executed; wherein, a group of data disks can be all data disks in a storage pool, all data disks of a node in the storage pool, or data disks in a performance layer of the storage pool, without limitation, and can all be adjusted according to the method of the present invention. A storage pool refers to a storage resource pool formed by aggregating a group of data disks. A storage pool can contain multiple nodes, and the data disks in each node can be further divided into multiple different performance layers, each performance layer containing a group of data disks. When partitioning storage nodes, data disks with similar performance within a storage node can be divided into different performance layers based on the performance differences of each data disk. For example, if a storage node contains both hard disk drives (HDDs) and solid-state drives (SSDs), then all HDDs can be assigned to one performance layer and all SSDs to another performance layer.

[0040] The capacity difference threshold is used to limit the difference between the capacity of each data disk in a group of data disks and the minimum capacity disk. This invention does not limit the type of capacity difference threshold; it can be a percentage, a capacity difference value, a weight, etc. When the capacity difference threshold is a percentage, it means that the available capacity of each data disk in a group of data disks is at most the threshold value greater than the capacity of the minimum capacity disk. For example, when the capacity difference threshold is set to 20%, it means that the available capacity of each data disk is at most 20% greater than the capacity of the minimum capacity disk; when the capacity difference threshold is set to 0%, it means that the available capacity of each data disk should be equal to the capacity of the minimum capacity disk. When the capacity difference threshold is a capacity difference value, it means that the difference between the available capacity of each data disk in a group of data disks and the capacity of the minimum capacity disk does not exceed the threshold value. For example, when the capacity difference threshold is set to 100GB, it means that the difference between the available capacity of each data disk and the capacity of the minimum capacity disk does not exceed 100GB.

[0041] Capacity difference thresholds can be manually set according to different application scenarios. For example, in an environment with heterogeneous data disk capacities, the capacity difference threshold can be set to 0% in the early stages of storage system use to ensure consistent available capacity across all data disks, thereby avoiding load imbalance and improving the service performance of the storage system. Later in the usage of the storage system, when available capacity is exhausted and no additional data disks are available for expansion, the priority of available capacity takes precedence over performance. Users can then increase the capacity difference threshold to release previously restricted capacity from large-capacity disks, increasing the available capacity of the storage system. The capacity difference threshold can be adjusted according to different application scenario requirements. By adjusting the capacity difference threshold, the difference between data disks can be adjusted. This avoids load imbalance caused by excessive capacity differences, which could affect the service performance of the storage system. It also allows for the release of capacity from large-capacity disks when expansion is needed, fully utilizing the bandwidth of each data disk. Therefore, it can balance performance and capacity requirements, maximizing the performance of the storage system while ensuring sufficient capacity.

[0042] The capacity difference threshold can also be automatically and dynamically adjusted based on the current remaining available capacity. For example, in the initial stage of storage system use, because there is a large amount of remaining available capacity, the capacity difference threshold can be set to a low value; when the remaining available capacity falls below a certain level, the capacity difference threshold is increased to release some of the restricted capacity of large-capacity disks to meet storage capacity demands; when the remaining available capacity is above a certain level, the capacity difference threshold is decreased to reclaim some capacity from large-capacity disks to avoid load imbalance between data disks and thus improve the performance of the storage system.

[0043] Capacity difference thresholds can include multiple different values ​​and can be set separately for different data disks. For example, if a data pool contains both HDDs and SSDs, and all data in the pool needs to be adjusted simultaneously, a first capacity difference threshold and a second capacity difference threshold can be set. The first threshold is used to adjust HDDs, and the second threshold is used to adjust SSDs. Alternatively, specific capacity difference thresholds can be set for special data disks in the storage system. For instance, if the capacity and performance of a particular data disk in the system are significantly better than other data disks, a first and a second capacity difference threshold can be set. The first threshold is used to adjust the capacity of other data disks, while the second threshold is used to adjust the capacity of the special data disk, where the second threshold is higher than the first. There is no limitation on the number or type of capacity difference thresholds; they can be set and adjusted according to different systems and application scenarios. By setting different capacity difference thresholds for different application scenarios, the capacity difference between each data disk in a group of storage disks and the smallest capacity disk can be dynamically adjusted, maximizing the performance of the storage system while ensuring that the storage system's capacity requirements are met.

[0044] S1-2: Obtain the current capacity difference threshold and the capacity of the minimum capacity disk. Calculate the available capacity limit based on these two values. The available capacity limit indicates that the available capacity of each data disk in a group of data disks cannot exceed the available capacity limit. If the capacity difference threshold is a percentage, then the available capacity limit = minimum capacity disk capacity * (1 + capacity difference threshold); if the capacity difference threshold is a capacity difference value, then the available capacity limit = minimum capacity disk capacity + capacity difference threshold. By setting the available capacity limit, the capacity difference between each data disk in the group and the minimum capacity disk can be kept within a set range, avoiding load imbalance caused by excessive capacity differences.

[0045] S1-3: Adjust the available capacity of the data disk to be adjusted according to the available capacity limit.

[0046] Please refer to Figure 2The diagram shows a flowchart of adjusting the available capacity of a data disk to be adjusted according to the present invention. Adjusting the available capacity of the data disk to be adjusted includes the following steps: S2-1 Obtain the actual capacity of the data disk to be adjusted; S2-2: Determine the difference between the available capacity limit and the actual capacity of the data disk to be adjusted. If the available capacity limit is greater than the actual capacity, proceed to step S2-3; if the available capacity limit is less than or equal to the actual capacity, proceed to step S2-4; Step S2-3: The available capacity of the data disk to be adjusted is equal to the actual capacity; Step S2-4: The available capacity of the data disk to be adjusted is equal to the available capacity limit. Therefore, after adjustment, the available capacity of each data disk in this group does not exceed the available capacity limit.

[0047] To better record information on each data disk, if the available capacity of a data disk changes after adjustments are made, the parameters related to that data disk (remaining available capacity, utilization rate, data disk status, etc.) should also be adjusted accordingly. Please refer to... Figure 3 The diagram shows a flowchart for adjusting the remaining available capacity of a data disk. Adjusting the remaining available capacity of a data disk includes the following steps: Step S3-1: Determine if the adjusted available capacity of the data disk is greater than the original available capacity. If the adjusted available capacity is greater than the original available capacity, proceed to step S3-2; if the adjusted available capacity is less than the original available capacity, proceed to step S3-3. Step S3-2: The current remaining available capacity of the data disk is the original remaining available capacity plus the difference between the adjusted and original available capacity. Step S3-3: The current remaining available capacity of the data disk is the original remaining available capacity minus the difference between the original and adjusted available capacity. Step S3-4: Output the current remaining available capacity of the data disk. By obtaining the current remaining available capacity of each data disk, the remaining available capacity of the entire storage system can be obtained. This parameter can be used to adjust the capacity difference threshold. Simultaneously, by obtaining the current remaining available capacity of each data disk, the utilization rate of each data disk can be determined, providing a better understanding of the status of each data disk in the storage system.

[0048] In one embodiment, each data disk reserves a certain amount of storage space as hot spare space according to the configuration. When the available capacity on the data disk changes, the hot spare space capacity and the remaining available hot spare capacity of the data disk should be adjusted accordingly.

[0049] In one embodiment, the group of data disks are data disks on the same performance layer. When adjusting the available capacity of the group of data disks, the capacity and related parameters of the node where the group of data disks are located, as well as the capacity and related parameters of the storage pool where the group of data disks are located, can also be adjusted.

[0050] To better ensure the security of the original data on the data disk during data disk adjustment, preferably, before adjusting the available capacity of the data disk to be adjusted, it also includes determining whether the data disk to be adjusted meets the conditions for available capacity adjustment, and adjusting the available capacity of the data disks that meet the conditions. One implementation is to determine whether all data disks in a group of data disks meet the adjustment conditions before performing the adjustment; another implementation is to determine whether each data disk in the hard disk group meets the adjustment conditions separately, and adjust the hard disks that meet the adjustment conditions. The conditions for determining whether a data disk meets the adjustment conditions are: if the actual capacity of the data disk to be adjusted exceeds the available capacity limit, and storage space exceeding the available capacity limit is used, then to ensure the security of the data stored on the data disk, its available capacity adjustment is not allowed; if the data disk has not used storage space exceeding the available capacity limit, then its available capacity adjustment is allowed. Please refer to... Figure 4 As shown, Figure 4 This diagram illustrates the storage space usage of two data disks. Based on the adjustment criteria above, it can be seen that data disk A's storage space exceeding the available capacity limit is unused, thus meeting the adjustment conditions; data disk B uses storage space exceeding the available capacity limit, therefore not meeting the adjustment conditions. Specifically, regarding whether to adjust data disks A and B, since data disk B does not meet the available capacity adjustment conditions, its available capacity will not be adjusted. If adjustment is only required when the adjustment conditions are met, then the available capacity of data disk A will be adjusted. If adjustment is only performed after all data disks in a group meet the adjustment conditions, it is also necessary to determine whether other data disks in the same group as data disk A also meet the adjustment conditions. Only when all data disks in the group meet the adjustment conditions will data disk A be adjusted. By adding a check to determine whether the data disk to be adjusted meets the available capacity adjustment conditions, and only adjusting the available capacity of data disks that meet the conditions, the security of data on the storage system is enhanced, and the reliability of the data disk capacity management method in this invention is improved.

[0051] The data disk capacity management method provided in this invention has the following advantages: (1) The available capacity of a group of data disks is automatically adjusted according to the capacity value of the smallest capacity disk in the group and the capacity difference threshold, so that the available capacity difference of each data disk in the group is within the set range, avoiding load imbalance caused by excessive capacity difference; (2) When the capacity of the smallest capacity disk in a group of data disks changes, the available capacity of the group of data disks can be automatically adjusted according to the new capacity of the smallest capacity disk, which is highly flexible; (3) The capacity difference threshold can be adjusted according to different application scenarios and system status. The storage system can automatically adjust the available capacity of the data disks according to the adjusted capacity difference threshold to adapt to different scenarios of performance priority and capacity priority, so as to ensure that the storage system has the best performance while meeting the capacity requirements.

[0052] To better illustrate the data disk capacity management method of the present invention, we provide several embodiments below to explain the operation process of the data disk capacity management method of the present invention.

[0053] Example 1: Creating a set of data disks

[0054] like Figure 5 As shown, Figure 5 This is a diagram illustrating the creation of a group of data disks. This group of data disks can be data disks within a specific performance tier of the storage pool, such as... Figure 5 As shown in a, Figure 5 Figure 'a' illustrates the actual capacity of this data disk group, which includes three disks with capacities of 1TB, 10TB, and 1.1TB, with the smallest capacity disk being 1TB. Assuming a capacity difference threshold of 20%, the available capacity limit can be calculated as 1TB * (1 + 20%) = 1.2TB. When the data disk group is first created, all three disks are unused, therefore, they all meet the adjustment conditions. The actual capacities of the 1TB and 1.1TB data disks are both less than the available capacity limit of 1.2TB; therefore, the available capacity of these two data disks is their actual capacity. For the 10TB data disk, because its actual capacity is greater than the available capacity limit, its available capacity is the available capacity limit of 1.2TB, meaning its available capacity will be limited to 1.2TB. Figure 5 Figure b shows the available capacity of each data disk after adjustment, i.e., the available capacities after adjustment are 1TB, 1.2TB, and 1.1TB, respectively. This embodiment demonstrates that the difference in available capacity between the data disks in this group is limited to within 20%, thus avoiding unbalanced load and overall performance degradation caused by excessive capacity differences between hard drives.

[0055] Example 2: Adding a data disk

[0056] 1. The increased data disk capacity is greater than the capacity of the existing minimum capacity disk.

[0057] Please refer to Figure 6 As shown, Figure 6 One embodiment for adding a data disk. Figure 6 a is a diagram showing the original available capacity of the data disks in this group of data disks, which includes two 1TB capacity disks; Figure 6 b represents the data disk in the group after the addition of the data disk. It can be seen that the added data disk has a capacity of 2TB, which is greater than the capacity of the existing minimum capacity disk. At this point, the minimum capacity disk remains at 1TB. Assuming the capacity difference threshold is set at 20%, the available capacity limit can be calculated as 1TB * (1 + 20%) = 1.2TB. Since the newly added data disk necessarily meets the adjustment conditions, its available capacity is adjusted to 1.2TB. Please refer to... Figure 6 Figure c shows a schematic diagram of the available capacity of each data disk after the adjustment of this group of data disks.

[0058] 2. The increased data disk capacity is less than or equal to the capacity of the existing minimum capacity disk.

[0059] Please refer to Figure 7 As shown, Figure 7 One embodiment for adding a data disk. Figure 7 a is a diagram showing the original available capacity of the data disks in this group of data disks. This group of data disks includes two data disks, each with a capacity of 2TB. Figure 7 b represents the data disk in the group after the addition of the data disk. Therefore, the added data disk has a capacity of 1TB, and its capacity is the smallest in the group. Assuming the capacity difference threshold is set at 20%, the available capacity limit can be calculated as 1TB * (1 + 20%) = 1.2TB. If the original 2TB data disk uses storage space exceeding the 1.2TB limit, then to ensure data storage security, the available capacity of the original two 2TB data disks will not be adjusted. Figure 7 Figure c shows the available capacity of each data disk in this group when the available capacity of the original data disk cannot be adjusted after adding a data disk. If the original 2TB data disk has not used storage space exceeding the 1.2TB limit, the available capacity of the original two 2TB data disks will be adjusted. Please refer to [reference needed]. Figure 7 As shown in d, this diagram illustrates the available capacity of each data disk after the adjustment of the original data disk's available capacity following the addition of a data disk.

[0060] Example 3: Removing the Data Disk

[0061] 1. Remove large-capacity data disks

[0062] Please refer to Figure 8 As shown, Figure 8 An example of removing a data disk. Figure 8 a is a schematic diagram of the original available capacity of the data disks in this group of data disks. This group of data disks includes one data disk with an available capacity of 1TB and two data disks with an available capacity of 1.2TB. The actual capacity of the two data disks with an available capacity of 1.2TB is 2TB (the process of adjusting from an actual capacity of 2TB to an available capacity of 1.2TB is omitted here, and the capacity difference threshold is still set to 20%). Figure 8 b represents the remaining data disks in the group after removing one data disk. Therefore, the usable capacity after removing the data disk is 1.2TB. Since the smallest capacity disk in the group remains unchanged at 1TB after removing this data disk, the usable capacity of the remaining data disks remains unchanged. Figure 8 Figure c shows a diagram illustrating the available capacity of each data disk after the group of data disks is adjusted following the removal of one data disk.

[0063] 2. Remove the smallest capacity disk

[0064] Please refer to Figure 9 As shown, Figure 9 An example of removing a data disk. Figure 9 a is a schematic diagram of the original available capacity of the data disks in this group of data disks. This group of data disks includes one data disk with an available capacity of 1TB and two data disks with an available capacity of 1.2TB. The actual capacity of the two data disks with an available capacity of 1.2TB is 2TB (the process of adjusting from an actual capacity of 2TB to an available capacity of 1.2TB is omitted here, and the capacity difference threshold is still set to 20%). Figure 9 b represents the data disk in the group after removing one data disk. Therefore, the available capacity after removing the data disk is 1TB. Since removing this data disk changes the minimum capacity disk in the group to an actual capacity of 2TB (i.e., the minimum capacity disk here changes to 2TB), and assuming the capacity difference threshold remains at 20%, the new available capacity limit is 2TB * (1 + 20%) = 2.4TB. The available capacity of the group is then adjusted based on the new minimum capacity disk and available capacity limit, as follows: Figure 9Figure c shows a schematic diagram illustrating the available capacity of each data disk in the group after removing one data disk and adjusting the capacity. It can be seen that when the removed data disk is the smallest capacity disk in the group, the available capacity of the group may increase. As shown in this embodiment, after removing the smallest capacity disk, the available capacity of the group increases from (1+1.2+1.2)TB = 3.4TB to (2+2)TB = 4TB. Therefore, removing the smallest capacity disk in a group can be used as a means of capacity expansion.

[0065] Example 4: Change in Capacity Difference Threshold

[0066] Please refer to Figure 10 As shown, Figure 10 This is an example of changing the capacity difference threshold. Figure 10 a is a schematic diagram of the original available capacity of the data disks in this group of data disks. This group of data disks includes one data disk with an available capacity of 1TB and two data disks with an available capacity of 1.2TB. The actual capacity of the two data disks with an available capacity of 1.2TB is 2TB (the process of adjusting from an actual capacity of 2TB to an available capacity of 1.2TB is omitted here, and the capacity difference threshold is set to 20%). Figure 10 Figure b shows the available capacity of each data disk in this group after the capacity difference threshold is changed. The capacity difference threshold changes from 20% to 40%, while the minimum capacity disk remains unchanged at 1TB. Based on the current minimum capacity disk of 1TB and the capacity difference threshold of 40%, the current available capacity limit is calculated to be 1TB * (1 + 40%) = 1.4TB. Since the current available capacity limit is less than the actual capacity of the two data disks other than the minimum capacity disk (2TB), and assuming that the available capacity of these two data disks can be adjusted from 1.2TB to 1.4TB, the available capacity of each data disk in this group after the adjustment is as follows: Figure 10 As shown in b.

[0067] In another aspect, the present invention provides a data disk capacity management device. Please refer to... Figure 11 The diagram shown is a schematic of the data disk capacity management device of the present invention. The data disk capacity management device includes a minimum capacity acquisition unit 111, a capacity difference threshold adjustment unit 112, an available capacity limit value acquisition unit 113, and an available capacity adjustment unit 114.

[0068] The minimum capacity acquisition unit 111 is used to acquire the capacity of the current minimum capacity disk of a group of data disks, and compare the current minimum capacity disk capacity with the previously recorded minimum capacity disk capacity. If the two are not equal, it means that the minimum capacity disk has changed, so it is necessary to trigger the adjustment of the available capacity of each data disk in the group of data disks; if the two are equal, it means that the minimum capacity disk has not changed, so it is not necessary to trigger the adjustment of the available capacity of each data disk in the group of data disks.

[0069] The capacity difference threshold adjustment unit 112 is used to adjust the capacity difference threshold to limit the difference between the capacity of each data disk in a group of data disks and the minimum capacity disk. When the capacity difference threshold adjustment unit adjusts the capacity difference threshold, it will trigger the adjustment of the available capacity of each data disk in the group of data disks; when the capacity difference threshold adjustment unit does not adjust the capacity difference threshold, it will not trigger the adjustment of the available capacity of each data disk in the group of data disks.

[0070] The capacity difference threshold adjustment unit can be adjusted manually or automatically. When manually adjusted, users can adjust the capacity difference threshold according to different application scenarios. For example, in an environment with heterogeneous data disk capacity, the capacity difference threshold can be set to 0% in the early stages of storage system use to ensure consistent available capacity across all data disks, thereby avoiding load imbalance and improving storage system performance. Later, when available capacity is exhausted and no additional data disks are available for expansion, the priority of available capacity takes precedence over performance. Users can then increase the capacity difference threshold to release previously restricted capacity from larger disks, increasing the available capacity of the storage system. When automatically adjusted, the program can be configured to adjust the capacity difference threshold based on the current remaining capacity. For example, in the initial stages of storage system use, because there is ample remaining available capacity, the capacity difference threshold can be set to a low value. When the remaining available capacity falls below a certain level, the capacity difference threshold is increased to release some of the restricted capacity of large-capacity disks to meet storage capacity demands. When the remaining available capacity exceeds a certain level, the capacity difference threshold is decreased to reclaim some capacity from large-capacity disks to avoid load imbalances among data disks, thereby improving storage system performance. By setting different capacity difference thresholds for different application scenarios, the capacity difference between each data disk and the smallest capacity disk in a group of storage disks can be dynamically adjusted, maximizing storage system performance while ensuring that storage system capacity requirements are met.

[0071] The available capacity limit value acquisition unit 113 is used to calculate the available capacity limit value of each data disk in the group of data disks when the adjustment of the available capacity of the data disk is triggered, based on the capacity of the current minimum capacity disk and the capacity difference threshold. The available capacity limit value acquisition unit 113 can calculate the available capacity limit value according to different types of capacity difference thresholds. If the capacity difference threshold is a percentage, then the available capacity limit value = the capacity of the minimum capacity disk * (1 + capacity difference threshold); if the capacity difference threshold is a capacity difference, then the available capacity limit value = the capacity of the minimum capacity disk + the capacity difference threshold.

[0072] The available capacity adjustment unit 114 is used to adjust the available capacity of the data disk to be adjusted according to the available capacity limit value. The steps for adjusting the available capacity of each data disk are as follows: obtain the actual capacity of the data disk to be adjusted; determine the size of the available capacity limit value and the actual capacity of the data disk to be adjusted. If the available capacity limit value is greater than the actual capacity of the data disk to be adjusted, then the available capacity of the data disk to be adjusted is the actual capacity of the data disk to be adjusted; if the available capacity limit value is less than or equal to the actual capacity of the data disk to be adjusted, then the available capacity of the data disk to be adjusted is the available capacity limit value.

[0073] The available capacity adjustment unit 114 can also calculate the remaining available capacity of each data disk. The remaining available capacity reflects parameters such as the utilization rate and status of each data disk. The calculation process for the remaining available capacity is as follows: It is determined whether the available capacity of the data disk after adjustment is greater than the available capacity before adjustment. If the adjusted available capacity is greater than the original available capacity, the remaining available capacity of the current data disk is the original remaining available capacity plus the difference between the adjusted and original available capacity. If the adjusted available capacity is less than the original available capacity, the remaining available capacity of the current data disk is the original remaining available capacity minus the difference between the original and adjusted available capacity.

[0074] To better ensure the security of the original data on the data disk during data disk adjustment, the data disk capacity management device provided in this invention also includes an adjustment condition judgment unit. If the data disk to be adjusted meets the adjustment conditions, the available capacity of the data disk is adjusted; if the data disk to be adjusted does not meet the adjustment conditions, the available capacity of the data disk is not adjusted. The judgment criteria for whether the adjustment conditions are met in the adjustment condition judgment unit can be as follows: if the actual capacity of the data disk exceeds the available capacity limit and storage space beyond the available capacity limit is used, then to ensure the security of the data stored on the data disk, its available capacity is not allowed to be adjusted; if no storage space beyond the available capacity limit is used, then its available capacity is allowed to be adjusted. Based on the above adjustment condition judgment criteria, other adjustment condition judgment criteria can be added: such as whether all data disks in the group to which the data disk to be adjusted belongs meet the available capacity adjustment conditions. Only when all data disks in the group meet the available capacity adjustment conditions will the available capacity of the data disk to be adjusted be adjusted. By adding an adjustment condition judgment unit, it is possible to determine whether the data disk to be adjusted meets the available capacity adjustment conditions, and only the data disks that meet the adjustment conditions are adjusted for available capacity, thereby enhancing the security of data on the storage system and improving the reliability of the data disk capacity management device in this invention.

[0075] The data disk management device provided in this invention has the following advantages: (1) The minimum capacity acquisition unit and the capacity difference threshold adjustment unit can detect in real time whether the minimum capacity disk and the capacity difference threshold in a group of data disks have changed. If they have changed, the available capacity adjustment unit can automatically adjust the available capacity of the group of data disks according to the current capacity value of the minimum capacity disk and the capacity difference threshold, so that the available capacity difference of each data disk in the group of data disks is within the set range, avoiding the load imbalance caused by excessive capacity difference. And because it can be adjusted automatically, it is highly flexible; (2) The capacity difference threshold can be adjusted by the capacity difference threshold adjustment unit according to different application scenarios and system status. The storage system can automatically adjust the available capacity of the data disks according to the adjusted capacity difference threshold to adapt to different scenarios of performance priority and capacity priority, so as to ensure that the storage system has the best performance while meeting the capacity requirements.

[0076] This application also provides an electronic device, including: a memory and a processor:

[0077] The memory is used to store the program code used by the electronic device during operation;

[0078] The processor is used to execute the program code to implement the adaptive data disk capacity management method as described above.

[0079] This application also provides a storage medium that, when instructions in the storage medium are executed by a processor of an electronic device, enables the electronic device to perform the adaptive data disk capacity management method as described above.

[0080] Those skilled in the art will understand that embodiments of this application can be provided as methods, systems, or computer program products. Therefore, this application can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, this application can take the form of a computer program product embodied on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0081] This application is described with reference to flowchart illustrations and / or block diagrams of methods, electronic devices (systems), and computer program products according to this application. It should be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing electronic device to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing electronic device, generate instructions for implementing the flowchart illustrations. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.

[0082] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing electronic device to operate in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.

[0083] These computer program instructions can also be loaded onto a computer or other programmable data processing electronic device to cause a series of operational steps to be performed on the computer or other programmable electronic device to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable electronic device for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.

[0084] Obviously, those skilled in the art can make various modifications and variations to this application without departing from the spirit and scope of this application. Therefore, if such modifications and variations fall within the scope of the claims of this application and their equivalents, this application also intends to include such modifications and variations.

Claims

1. An adaptive data disk capacity management method, characterized in that, The adaptive data disk capacity management method includes the following steps: Determine whether the capacity difference threshold of a group of data disks or the capacity of the smallest capacity disk has changed; if not, do not adjust the available capacity of each data disk. If changes occur, follow these steps: Obtain the current capacity difference threshold and the capacity of the minimum capacity disk, and calculate the available capacity limit value based on the current capacity difference threshold and the capacity of the minimum capacity disk; The available capacity of the data disk to be adjusted is adjusted according to the available capacity limit value, wherein the available capacity of the data disk to be adjusted does not exceed the available capacity limit value.

2. The adaptive data disk capacity management method according to claim 1, characterized in that, The capacity difference threshold is one of the following: percentage, capacity difference, or weight.

3. The adaptive data disk capacity management method according to claim 2, characterized in that, When the capacity difference threshold is a percentage, the available capacity limit value = the capacity of the minimum capacity disk * (1 + capacity difference threshold).

4. The adaptive data disk capacity management method according to claim 2, characterized in that, When the capacity difference threshold is the capacity difference value, the available capacity limit value = the capacity of the minimum capacity disk + the capacity difference threshold.

5. The adaptive data disk capacity management method according to claim 1, characterized in that, When adjusting the available capacity of the data disk to be adjusted based on the available capacity limit value, the following steps are included: Obtain the actual capacity of the data disk to be adjusted; The available capacity limit is compared with the actual capacity of the data disk to be adjusted. If the available capacity limit is greater than the actual capacity of the data disk to be adjusted, the available capacity of the data disk to be adjusted is adjusted to the actual capacity of the data disk to be adjusted. If the available capacity limit is less than the real-time capacity of the data disk to be adjusted, then the available capacity of the data disk to be adjusted is adjusted to the available capacity limit.

6. The adaptive data disk capacity management method according to claim 1, characterized in that, Before adjusting the available capacity of the data disk to be adjusted, the following steps are also included: Determine whether the data disk to be adjusted meets the conditions for adjusting available capacity. If the data disk to be adjusted meets the conditions, then adjust the available capacity of the data disk to be adjusted; otherwise, do not adjust the available capacity of the data disk to be adjusted.

7. The adaptive data disk capacity management method according to claim 6, characterized in that, The available capacity adjustment conditions are as follows: When the actual capacity of the data disk to be adjusted exceeds the available capacity limit, the storage space beyond the available capacity limit is unused.

8. The adaptive data disk capacity management method according to claim 1, characterized in that, The adaptive data disk capacity management method further includes the following steps: outputting at least one of the following parameters: remaining available capacity, utilization rate, and data disk status.

9. The adaptive data disk capacity management method according to claim 8, characterized in that, The remaining available capacity is calculated using the following steps: Determine whether the available capacity of the data disk after adjustment is greater than the available capacity before adjustment. If the available capacity after adjustment is greater than the available capacity before adjustment, then the remaining available capacity of the current data disk is the remaining available capacity before adjustment plus the difference between the available capacity after adjustment and the available capacity before adjustment. If the adjusted available capacity is less than the original available capacity, then the remaining available capacity of the current data disk is the original remaining available capacity minus the difference between the original and adjusted available capacity.

10. An adaptive data disk capacity management device, characterized in that, The adaptive data disk capacity management device includes a minimum capacity acquisition unit, a capacity difference threshold adjustment unit, an available capacity limit value acquisition unit, and an available capacity adjustment unit, wherein... The minimum capacity acquisition unit is used to acquire the capacity of the current minimum capacity disk of a group of data disks, and compare the current minimum capacity disk capacity with the previously recorded minimum capacity disk capacity. If the two are not equal, the available capacity of the data disk is adjusted. The capacity difference threshold adjustment unit is used to adjust the capacity difference threshold. When the capacity difference threshold adjustment unit adjusts the capacity difference threshold, it triggers the adjustment of the available capacity of the data disk. The available capacity limit value acquisition unit is used to calculate the available capacity limit value based on the capacity value of the current smallest capacity disk and the capacity difference threshold when the available capacity of the data disk is adjusted. The available capacity adjustment unit is used to adjust the available capacity of the data disk to be adjusted according to the available capacity limit value, wherein the available capacity of the data disk to be adjusted does not exceed the available capacity limit value.

11. The adaptive data disk capacity management device according to claim 10, characterized in that, The adaptive data disk capacity management device further includes an adjustment condition judgment unit, which is used to determine whether the data disk to be adjusted meets the adjustment conditions. If the data disk to be adjusted meets the adjustment conditions, the available capacity of the data disk to be adjusted is adjusted. Otherwise, do not adjust the available capacity of the data disk to be adjusted.

12. The adaptive data disk capacity management device according to claim 11, characterized in that, The adjustment condition is as follows: when the actual capacity of the data disk to be adjusted exceeds the available capacity limit, the storage space beyond the available capacity limit is unused.

13. The adaptive data disk capacity management device according to claim 10, characterized in that, The available capacity adjustment unit is specifically used for: Obtain the actual capacity of the data disk to be adjusted; The available capacity limit is compared with the actual capacity of the data disk to be adjusted. If the available capacity limit is greater than the actual capacity of the data disk to be adjusted, the available capacity of the data disk to be adjusted is adjusted to the actual capacity of the data disk to be adjusted. If the available capacity limit is less than the real-time capacity of the data disk to be adjusted, then the available capacity of the data disk to be adjusted is adjusted to the available capacity limit.

14. The adaptive data disk capacity management device according to claim 10, characterized in that, The available capacity adjustment unit is also used to output at least one of the following parameters: remaining available capacity, utilization rate, and data disk status.

15. The adaptive data disk capacity management device according to claim 14, characterized in that, When the available capacity adjustment unit outputs the remaining available capacity, it is specifically used for: Determine whether the available capacity of the data disk after adjustment is greater than the available capacity before adjustment. If the available capacity after adjustment is greater than the available capacity before adjustment, then the remaining available capacity of the current data disk is the remaining available capacity before adjustment plus the difference between the available capacity after adjustment and the available capacity before adjustment. If the adjusted available capacity is less than the original available capacity, then the remaining available capacity of the current data disk is the original remaining available capacity minus the difference between the original and adjusted available capacity.

16. An electronic device, characterized in that, include: Memory and processor; The memory is used to store the program code used by the electronic device during operation; The processor is used to execute the program code to implement the adaptive data disk capacity management method as described in any one of claims 1-9.

17. A storage medium, characterized in that, When the instructions in the storage medium are executed by the processor of the electronic device, the electronic device is able to perform the adaptive data disk capacity management method as described in any one of claims 1-9.

Citation Information

Patent Citations

  • Storage system capacity expansion method, readable storage medium and computing equipment

    CN111208952A

  • Method, electronic device and computer program product for managing disks

    US20210132802A1