Distributed storage pool high water level reconstruction strategy optimization method, device and equipment
Through simulation and policy generation methods, the problem of incomplete data reconstruction after hard disk failure under high water level of the storage pool is solved, and high data reliability and high system availability are achieved.
Patent Information
- Application Number
- CN202412000325.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-31
- Publication Date
- 2025-04-11
- Estimated Expiration
- 2044-12-31
AI Technical Summary
In the high water level scenario of the storage pool, the data reconstruction after the hard disk fails, resulting in the service being read-only and unwritable. It is impossible to ensure that the faulty data can be completely reconstructed, which may lead to data loss.
By obtaining the historical distribution information of the placing groups in the object storage device data set and the storage pool, the current distribution information of the storage pool after the failure is simulated, and the current water level information of each object storage device is determined based on the reconstruction preset bandwidth and current distribution information, and a water level reconstruction strategy is generated to indicate whether the faulty hard disk is kicked out.
Ensure that data remains consistent after failure, improve data reliability, reduce uncertainty and potential costs during the reconstruction process, shorten the time for system response to failures, improve overall performance, and maintain high availability of the system through optimized resource allocation.
Smart Images

Figure CN119806919A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of storage technology, and in particular to a method, device and equipment for optimizing a high water level reconstruction strategy of a distributed storage pool. Background Art
[0002] In the scenario of high water level in the storage pool, a hard disk failure occurs. After the hard disk is kicked out, the data on it is reconstructed to other hard disks in the node where the hard disk is located. Along with the reconstructed data and business, the other hard disks in the node are filled up, resulting in read-only business. To solve this problem, a known approach is to set a water level threshold at the time of failure, such as 85%. When the storage pool reaches this water level, the failed hard disk is not allowed to be kicked out of the storage pool to trigger reconstruction. However, this solution only looks at the water level of the storage pool, the control is not precise enough, and it cannot cope with the scenario of multiple hard disk failures. For example, if the current water level of the storage pool is 84%, multiple hard disks are faulty at this time, and reconstruction is allowed to be triggered, but reconstruction cannot be completed. The water level of other hard disks will rise to the threshold, making the business read-only and not writable. There is no guarantee that the failed data can be reconstructed, resulting in data loss. Summary of the invention
[0003] In view of this, the present invention provides a distributed storage pool high water level reconstruction strategy optimization method, device and equipment to solve the problem that data reconstruction control is not precise enough and cannot cope with multiple hard disk failures.
[0004] In a first aspect, the present invention provides a method for optimizing a high water level reconstruction strategy of a distributed storage pool, the method comprising:
[0005] Obtaining an object storage device data set and historical distribution information of a placement group in a storage pool, wherein the object storage device data set includes status information corresponding to a plurality of object storage devices, and storage pool information to which the plurality of object storage devices belong, wherein the plurality of object storage devices include object storage devices that have failed and object storage devices that are in a normal state;
[0006] Based on the status information of each object storage device and the storage pool information, simulate and determine the current distribution information of the placement group in the storage pool after the failed object storage device is kicked out, and determine whether to reconstruct the placement group corresponding to the failed object storage device;
[0007] If reconstruction is performed, the current water level information of each object storage device in a normal state is determined according to the reconstruction preset bandwidth, the current distribution information, and the storage pool information;
[0008] A water level reconstruction strategy is generated according to the current water level information, wherein the water level reconstruction strategy is used to indicate whether to kick out the failed object storage device.
[0009] The distributed storage pool high water level reconstruction strategy optimization method provided by the present invention has the following advantages:
[0010] In the above method, by timely reconstructing the placement group when the object storage device fails, it can be ensured that data is not lost due to the failure, and the reliability of data storage can be improved. Therefore, by automatically identifying the faulty device and simulating the reconstruction process, the uncertainty and potential cost in the actual reconstruction process can be reduced through pre-simulation and strategy generation. Reduce the risk caused by improper data migration during the reconstruction process. Quickly determine whether reconstruction is required and how to reconstruct, which can shorten the system's response time to failure and improve overall performance. By effectively managing and replacing faulty devices, the stability and fault tolerance of the system can be enhanced. Furthermore, by reasonably allocating and adjusting storage resources, the utilization of storage space in the storage pool can be maximized. According to the current water level information, the system can dynamically allocate resources to ensure the balance of the storage pool. Finally, according to the water level reconstruction strategy, it is determined whether to kick out the failed object storage device, and the high availability of the system is maintained by timely reconstruction and optimization of resource allocation.
[0011] In an optional implementation, the storage pool information includes water level information of the storage pool and the number of placement groups in the storage pool;
[0012] Based on the status information of each object storage device and the storage pool information, the current distribution information of the placement group in the storage pool after the failed object storage device is kicked out is simulated and determined, and whether to reconstruct the placement group corresponding to the failed object storage device, specifically including:
[0013] The status information of each object storage device, the water level information of the storage pool, and the number of placement groups in the storage pool are input into the data distribution algorithm to simulate the current distribution information of the placement groups in the storage pool after the failed object storage device is kicked out.
[0014] Compare current distribution information with historical distribution information;
[0015] When it is determined that the current distribution information is inconsistent with the historical distribution information, it is determined to reconstruct the placement group corresponding to the failed object storage device.
[0016] Specifically, the water level information of the storage pool (i.e., the usage of storage resources) is used to evaluate the necessity of reconstruction and optimize the allocation of storage resources. The number of placement groups in the storage pool helps to simulate and optimize data distribution more accurately. The status information of the object storage device is used to distinguish the object storage devices that have failed and the object storage devices that have not failed. This information and the number of placement groups in the storage pool are input into the data separation algorithm to simulate the current distribution information of the placement groups in the storage pool after the storage devices of the failed objects are kicked out. By comparing the historical distribution information with the current distribution information, it can be ensured that the data remains consistent after the failure occurs, thereby improving the reliability of the data. By simulating the distribution of the failed device after being kicked out, possible data distribution problems can be predicted in advance and the reaction time when the actual failure occurs can be reduced. The simulation results help decision makers determine whether the placement group needs to be reconstructed, thereby avoiding unnecessary reconstruction operations. Based on historical and current data, the system can intelligently adjust the storage pool configuration to improve resource utilization efficiency. Determine the best reconstruction time to reduce data interruption and system downtime. The water level reconstruction strategy generated according to the current water level information helps to accurately control data migration and avoid resource waste. Automated processes and intelligent decision-making reduce the workload of operation and maintenance and improve operation and maintenance efficiency. By optimizing storage resource utilization and reducing unnecessary reconstruction, operation and maintenance costs can be controlled.
[0017] In an optional implementation manner, the storage pool information also includes the redundancy type of the storage pool and the data storage capacity of the placement group corresponding to each object storage device in the storage pool;
[0018] If reconstruction is performed, the current water level information of each object storage device in a normal state is determined according to the reconstruction preset bandwidth, current distribution information, and storage pool information, including:
[0019] Determine the total capacity to be reconstructed according to the redundancy type of the storage pool, the current distribution information, and the data storage capacity of the placement group corresponding to the object storage device that has failed in the storage pool;
[0020] The current water level information of each object storage device in normal state is determined according to the preset reconstruction bandwidth, the total capacity to be reconstructed, the current distribution information, the number of placement groups in the storage pool, and the data storage capacity of the placement groups corresponding to the object storage devices in normal state in the storage pool.
[0021] Specifically, different redundancy types have different ways of determining the total capacity to be reconstructed. The current information of the placement group can determine the number of placement groups stored in the failed object storage device and the number of placement groups stored in the unfailed object storage device, and then determine the data storage capacity of the placement group to be migrated, and then determine the total capacity to be reconstructed. Then, based on the data storage capacity of the placement group corresponding to each object storage device, the storage resources are allocated and optimized more accurately to avoid data overload or resource waste. Using the preset bandwidth and current distribution information of the reconstruction, the system can quickly calculate the bandwidth and resources required for reconstruction, thereby improving the efficiency of reconstruction. By determining the current water level information of each normal object storage device, the system can better balance the load and avoid performance degradation or failure due to overload. Accurate water level information and redundancy strategies help to speed up data recovery and reduce the impact of failures on business. According to the actual data storage capacity of each device, the system can allocate resources more reasonably and improve the overall performance of the storage pool. By combining the preset bandwidth and the actual data storage capacity, the system can avoid bandwidth overload and ensure the smooth progress of the data reconstruction process. During the reconstruction process, accurate water level information helps to quickly locate the problem device and improve the efficiency of fault handling. Therefore, it is necessary to determine the current water level information of each object storage device in a normal state. By optimizing the reconstruction strategy and resource allocation, the system stability is enhanced and the system fluctuation caused by improper reconstruction is reduced.
[0022] In an optional implementation, determining the total capacity to be reconstructed according to the redundancy type of the storage pool, current distribution information, and the data storage capacity of the placement group corresponding to the failed object storage device in the storage pool includes:
[0023] Extracting a first mapping relationship from the current distribution information, where the first mapping relationship is a first mapping relationship re-established between a placement group to which data stored in a failed object storage device belongs and an object storage device in a normal state;
[0024] Determine, according to the redundancy type of the storage pool and the data storage capacity of the placement group corresponding to the failed object storage device, the raw capacity of the placement group corresponding to the failed object storage device on the normal object storage device with which the first mapping relationship is established;
[0025] The total capacity to be reconstructed is determined based on the raw capacity of the placement group corresponding to the failed object storage device on the normal object storage device with which the placement group has established a first mapping relationship.
[0026] Specifically, according to the first mapping relationship, it is determined to which object storage device in a normal state the placement group to which the data stored in the failed object storage device belongs can be assigned, that is, the first mapping relationship is extracted. Then, according to the redundancy type of the storage pool and the data storage capacity of the placement group corresponding to the failed object storage device, the raw capacity of the placement group corresponding to the failed object storage device on the object storage device in a normal state with which the first mapping relationship is established; finally, based on the raw capacity of the placement group corresponding to the failed object storage device on the object storage device in a normal state with which the first mapping relationship is established, the total capacity to be reconstructed is determined. The total reconstruction capacity is the sum of all raw capacities. In the above method, by extracting the first mapping relationship, that is, the mapping between the placement group to which the data stored in the failed object storage device belongs and the object storage device in a normal state, the total capacity to be reconstructed can be accurately calculated to avoid insufficient or excessive capacity. According to the redundancy type of the storage pool and the data storage capacity of the failed placement group, the system can optimize the use of redundant resources to ensure the security of data after reconstruction. By determining the raw capacity, that is, the space available for storing failed data on the object storage device in a normal state, the system can more effectively utilize existing resources. After determining the total capacity to be reconstructed, the reconstruction process can be planned more efficiently, reducing the time and resources required for reconstruction and speeding up data recovery. By accurately calculating the total capacity to be reconstructed, the operation and maintenance efficiency of the storage pool and the reliability of the system are improved, while reducing costs and improving user experience.
[0027] In an optional implementation, according to the preset reconstruction bandwidth, the total capacity to be reconstructed, the current distribution information, the number of placement groups in the storage pool, and the data storage capacity of the placement groups corresponding to the object storage devices in the storage pool in a normal state, the current water level information of each object storage device in a normal state is determined, including:
[0028] Predict the incremental service data during the reconstruction period based on the preset reconstruction bandwidth and the total capacity to be reconstructed;
[0029] Based on the number of placement groups in the storage pool and the service data increment during the reconstruction period, the average data increment of each placement group is obtained;
[0030] Based on the current distribution information of the placement groups in the storage pool, the redundancy type of the storage pool, the number of placement groups in the storage pool, the average data increment of each placement group, and the data storage capacity of the placement groups corresponding to the object storage devices in the storage pool that are in normal state, determine the current water level information of each object storage device that is in normal state.
[0031] Specifically, by predicting the incremental business data during the reconstruction period, bandwidth resources can be planned and adjusted in advance, reconstruction efficiency can be improved, and reconstruction time can be reduced. Based on the average data increment of the placement group, storage resources can be reasonably allocated to avoid overloading of certain storage devices while ensuring that other devices are not idle. By monitoring the current water level information of each storage device, potential storage bottlenecks can be discovered and handled in a timely manner to enhance system stability. Accurate water level information helps to quickly locate and restore data on faulty devices and speed up fault recovery. Reduce system interruption time caused by reconstruction or fault recovery and improve user experience.
[0032] In an optional implementation, predicting the service data increment during the reconstruction period according to the reconstructed preset bandwidth and the total capacity to be reconstructed includes:
[0033] Predict data reconstruction time based on the total capacity to be reconstructed and the preset reconstruction bandwidth;
[0034] Based on the incremental business data during the failure of the object storage device that has failed and the time when the failure occurred, obtain the business data growth rate;
[0035] The data reconstruction time and business data growth rate are used to predict the business data increment during the reconstruction period.
[0036] In an optional implementation, when the water level reconstruction strategy indicates that the failed object storage device cannot be kicked out, the method further includes:
[0037] Save the water level information of each object storage device in the storage pool;
[0038] Periodically detect changes in the water level information of each object storage device;
[0039] When it is determined according to the change that the water level information of the first object storage device drops below the preset water level threshold, it is re-determined whether the failed object storage device meets the kick-out condition, wherein the first object storage device is any object storage device in the storage pool.
[0040] In an optional implementation, when the water level reconstruction strategy indicates that the failed object storage device is kicked out, the method further includes:
[0041] After executing the operation of kicking out the failed object storage device, determining whether to trigger a reconstruction operation;
[0042] Identify the danger level corresponding to the current water level information of each object storage device in a normal state;
[0043] When the reconstruction operation is triggered, the actual business increment generated during the reconstruction time is obtained;
[0044] The reconstruction control strategy is determined based on the danger level, data reconstruction time, actual business increment, and predicted business data increment during the reconstruction period corresponding to the current water level information of each object storage device in a normal state.
[0045] In a second aspect, the present invention provides a distributed storage pool high water level reconstruction strategy optimization device, the device comprising:
[0046] A data acquisition module, used to acquire an object storage device data set and historical distribution information of a placement group in a storage pool, wherein the object storage device data set includes status information corresponding to a plurality of object storage devices, and information of storage pools to which the plurality of object storage devices belong, wherein the plurality of object storage devices include object storage devices that have failed and object storage devices that are in a normal state;
[0047] A processing module, configured to simulate and determine, based on the status information of each of the object storage devices and the storage pool information, the current distribution information of the placement groups in the storage pool after the failed object storage device is kicked out, and determine whether to reconstruct the placement group corresponding to the failed object storage device;
[0048] A water level acquisition module, used for determining the current water level information of each object storage device in a normal state according to the preset reconstruction bandwidth, the current distribution information, and the storage pool information if reconstruction is performed;
[0049] The processing module is further used to generate a water level reconstruction strategy according to the current water level information, wherein the water level reconstruction strategy is used to indicate whether to kick out the object storage device that has failed.
[0050] The distributed storage pool high water level reconstruction strategy optimization device provided by the present invention has the following advantages:
[0051] In the above method, by timely reconstructing the placement group when the object storage device fails, it can be ensured that data is not lost due to the failure, and the reliability of data storage can be improved. Therefore, by automatically identifying the faulty device and simulating the reconstruction process, the uncertainty and potential cost in the actual reconstruction process can be reduced through pre-simulation and strategy generation. Reduce the risk caused by improper data migration during the reconstruction process. Quickly determine whether reconstruction is required and how to reconstruct, which can shorten the system's response time to failure and improve overall performance. By effectively managing and replacing faulty devices, the stability and fault tolerance of the system can be enhanced. Furthermore, by reasonably allocating and adjusting storage resources, the utilization of storage space in the storage pool can be maximized. According to the current water level information, the system can dynamically allocate resources to ensure the balance of the storage pool. Finally, according to the water level reconstruction strategy, it is determined whether to kick out the failed object storage device, and the high availability of the system is maintained by timely reconstruction and optimization of resource allocation.
[0052] In a third aspect, the present invention provides a computer device, comprising: a memory and a processor, the memory and the processor being communicatively connected to each other, the memory storing computer instructions, and the processor executing the distributed storage pool high water level reconstruction strategy optimization method of the first aspect or any corresponding embodiment thereof by executing the computer instructions.
[0053] In a fourth aspect, the present invention provides a computer-readable storage medium having computer instructions stored thereon, the computer instructions being used to enable a computer to execute the distributed storage pool high water level reconstruction strategy optimization method of the above-mentioned first aspect or any corresponding embodiment thereof.
[0054] In a fifth aspect, the present invention provides a computer program product, comprising computer instructions for causing a computer to execute the distributed storage pool high water level reconstruction strategy optimization method of the first aspect or any corresponding embodiment thereof. BRIEF DESCRIPTION OF THE DRAWINGS
[0055] In order to more clearly illustrate the specific embodiments of the present invention or the technical solutions in the related technologies, the drawings required for use in the specific embodiments or the related technical descriptions will be briefly introduced below. Obviously, the drawings described below are some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0056] Figure 1 It is a flow chart of a distributed storage pool high water level reconstruction strategy optimization method provided by an embodiment of the present invention;
[0057] Figure 2It is a flow chart of another distributed storage pool high water level reconstruction strategy optimization method provided by an embodiment of the present invention;
[0058] Figure 3 It is a flow chart of another distributed storage pool high water level reconstruction strategy optimization method provided by an embodiment of the present invention;
[0059] Figure 4 It is a flow chart of another distributed storage pool high water level reconstruction strategy optimization method provided by an embodiment of the present invention;
[0060] Figure 5 It is a schematic diagram of the overall process of a distributed storage pool high water level reconstruction strategy optimization method provided by an embodiment of the present invention;
[0061] Figure 6 It is a structural block diagram of a distributed storage pool high water level reconstruction strategy optimization device provided by an embodiment of the present invention;
[0062] Figure 7 It is a schematic diagram of the hardware structure of a computer device provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0063] In order to make the purpose, technical solution and advantages of the embodiments of the present invention clearer, the technical solution in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative work are within the scope of protection of the present invention.
[0064] Before introducing the embodiments of the present application, the following contents are first introduced:
[0065] Distributed storage usually consists of several server nodes (each server node has several disks). These server nodes are organized into a distributed storage cluster through distributed storage software, which then manages the server nodes and provides storage services to the outside world. Distributed storage software manages the storage resources (disks) on the server by creating storage pools. A storage pool can be understood as a logical container for storing data objects and related metadata. It can be regarded as a group of relatively independent data storage spaces. There are multiple server nodes in the storage pool, and the hard disks on them are managed by the object storage device service. Usually, one hard disk corresponds to one object storage device service. In addition, there are several placement groups in the storage pool. The placement group is a logical concept that corresponds to the object storage device through the data distribution algorithm, and thus generates two storage pool-level data redundancy methods: replica and erasure. Therefore, a placement group exists in multiple object storage devices. When business data needs to be written to the storage pool, the client will cut the data into fixed sizes. This fixed-size data is called an object. The object and placement group are matched through a consistent hashing algorithm. The corresponding placement group can be calculated through the object name. The placement group exists on multiple object storage devices. In this way, the object is written to the disk through the object storage device service.
[0066] A placement group (PG) is a logical concept used to distribute data objects to different object storage devices (OSDs) in a storage system. Through the data distribution algorithm, PGs are mapped to OSDs to achieve balanced distribution and redundant storage of data. Specifically, the data distribution algorithm maps data objects to different PGs according to certain rules. Each PG has a unique identifier and is associated with a group of OSDs. When a data object needs to be stored, it is assigned to a specific PG, and then the data is stored on the corresponding OSD based on the correspondence between the PG and the OSD. The advantage of doing this is that it can achieve balanced distribution of data, avoid excessive load on some OSDs, and also improve data reliability and fault tolerance. By storing data on multiple OSDs, redundant backup of data can be achieved, and when an OSD fails, data can be restored from other OSDs.
[0067] In actual applications, after long-term use of distributed storage, the water level in the storage pool will become higher and higher, and the hard disk failure rate will also increase. When a hard disk fails and reaches failure rebalancing, the hard disk will be kicked out of the storage pool, and the data on it will be reconstructed to other hard disks through reconstruction to ensure data security and sufficient redundancy. In general, the storage pool will set some thresholds. For example, when the water level of the storage pool or the hard disk reaches 95%, the storage pool is marked as full. At this time, the business is only allowed to read, not write.
[0068] However, in the above method, there is a scenario where a hard disk fails when the storage pool is at a high water level. After the hard disk is kicked out, the data on it is reconstructed to other hard disks on the node where the hard disk is located. Along with the reconstructed data and business, the other hard disks of the node are filled up, resulting in read-only business but not writable business.
[0069] In order to avoid the above situation, in the related technology, a water level threshold is set at the time of failure, such as 85%. When the storage pool reaches this water level, the failed hard disk is not allowed to be kicked out of the storage pool to trigger reconstruction. However, this solution only looks at the water level of the storage pool, the control is not precise enough, and it cannot cope with the scenario of multiple hard disk failures. For example, if the current water level of the storage pool is 84%, and multiple hard disks fail at this time, reconstruction is allowed to be triggered, but reconstruction cannot be completed in reality. The water level of other hard disks will rise to the threshold, making the business read-only and not writable.
[0070] The embodiment of the present invention provides a method for optimizing a high-water-level reconstruction strategy of a distributed storage pool, which avoids incomplete data reconstruction by accurately predicting the reconstructed data, thereby improving the security of data reconstruction.
[0071] According to an embodiment of the present invention, an embodiment of a method for optimizing a high water level reconstruction strategy for a distributed storage pool is provided. It should be noted that the steps shown in the flowchart in the accompanying drawings can be executed in a computer system such as a set of computer executable instructions, and although a logical order is shown in the flowchart, in some cases, the steps shown or described may be executed in an order different from that shown here.
[0072] In this embodiment, a distributed storage pool high water level reconstruction strategy optimization method is provided, which can be used in electronic devices such as clients, servers, etc. Figure 1 is a flow chart of a method for optimizing a high water level reconstruction strategy of a distributed storage pool according to an embodiment of the present invention. Figure 1 As shown, the process includes the following steps:
[0073] Step S101, obtaining historical distribution information of placement groups in an object storage device data set and a storage pool.
[0074] Specifically, the object storage device data set includes status information corresponding to multiple object storage devices respectively and storage pool information to which the multiple object storage devices belong. The multiple object storage devices include object storage devices that have failed and object storage devices that are in normal status.
[0075] Step S102, based on the status information of each object storage device and the storage pool information, simulate and determine the current distribution information of the placement group in the storage pool after the failed object storage device is kicked out, and determine whether to reconstruct the placement group corresponding to the failed object storage device.
[0076] Specifically, based on the data distribution algorithm, through the status information of the failed object storage device, the status information of the normal object storage device, and the storage pool information, the placement group distribution information after the failed object storage device is kicked out is simulated.
[0077] Then, it is confirmed whether the placement group distribution information after the failed object storage device is kicked out is consistent with the historical distribution information. When the data is inconsistent, the placement group corresponding to the failed object storage device is reconstructed.
[0078] Step S103: if reconstruction is performed, the current water level information of each object storage device in a normal state is determined according to the reconstruction preset bandwidth, the current distribution information, and the storage pool information.
[0079] Step S104: Generate a water level reconstruction strategy based on current water level information.
[0080] The water level reconstruction strategy is used to indicate whether to kick out the failed object storage device.
[0081] Specifically, when the current water level information of the OSD reaches a certain height, the business is only allowed to read, and cannot be written. Therefore, if it is determined based on the simulation that reconstruction is required, it is also necessary to determine the current water level information of each object storage in a normal state based on the reconstruction preset bandwidth, current distribution information, and storage pool information. The current water level information of each OSD in a normal state has a relatively large impact on the water level information of the storage pool. Because it is necessary to consider whether the sum of the water level information of the remaining OSDs in a normal state will reach the upper limit of the water level information of the storage after the failed OSD is kicked out, resulting in the subsequent only being able to read data but not write data. Moreover, there is also a risk when the water level information of a single OSD reaches the preset upper limit. Therefore, it is necessary to generate a reconstruction strategy based on the current water level information of each OSD in a normal state to indicate whether to kick out the failed object storage device.
[0082] The preset reconstruction bandwidth represents the current data reconstruction speed. The amount of data storage increased during the reconstruction can be determined based on the current data reconstruction speed. The water level information of the object storage device in a normal state before the data storage capacity is increased can be determined based on the current distribution information and storage pool information. Then, based on the water level information between the increased data storage capacity and the object storage device in a normal state without the increased data storage capacity, the current water level information of the object storage device in a normal state after the reconstruction is determined.
[0083] If the current water level information of the object storage device in normal state does not reach the preset threshold standard, the faulty object storage device is not allowed to be kicked out. If the current water level information of the object storage device in normal state does not exceed the preset threshold, the faulty object storage device will be kicked out.
[0084] The distributed storage pool high water level reconstruction strategy optimization method provided in this embodiment can ensure that data is not lost due to failures and improve the reliability of data storage by timely reconstructing the placement group when the object storage device fails. Therefore, by automatically identifying the faulty device and simulating the reconstruction process, the uncertainty and potential costs in the actual reconstruction process can be reduced through pre-simulation and strategy generation. Reduce the risk caused by improper data migration during the reconstruction process. Quickly determine whether reconstruction is required and how to reconstruct, which can shorten the system's response time to failure and improve overall performance. By effectively managing and replacing faulty devices, the stability and fault tolerance of the system can be enhanced. Furthermore, by reasonably allocating and adjusting storage resources, the utilization rate of storage space in the storage pool can be maximized. According to the current water level information, the system can dynamically allocate resources to ensure the balance of the storage pool. Finally, according to the water level reconstruction strategy, it is determined whether to kick out the failed object storage device, and the high availability of the system is maintained by timely reconstruction and optimization of resource allocation.
[0085] In this embodiment, a distributed storage pool high water level reconstruction strategy optimization method is provided, which can be used for the above-mentioned mobile terminals, such as mobile phones, tablet computers, etc. Figure 2 FIG. 4 is a flow chart of another distributed storage pool high water level reconstruction strategy optimization method provided by an embodiment of the present invention. Figure 2 As shown, based on the above-mentioned embodiment, the storage pool information includes the water level information of the storage pool and the number of placement groups in the storage pool;
[0086] Based on the status information of each object storage device and the storage pool information, the current distribution information of the placement group in the storage pool after the failed object storage device is kicked out is simulated and determined, and whether to reconstruct the placement group corresponding to the failed object storage device, specifically including the following method steps:
[0087] Step S201, input the status information of each object storage device, the water level information of the storage pool, and the number of placement groups in the storage pool into the data distribution algorithm to simulate the current distribution information of the placement groups in the storage pool after the failed object storage device is kicked out.
[0088] The specific data distribution algorithm can directly simulate the corresponding results, that is, simulate the current distribution information of the placement group in the storage pool after the failed object storage device is kicked out.
[0089] Step S202, comparing the current distribution information with the historical distribution information.
[0090] Specifically, the distribution information of the storage devices whose fault objects have not been kicked out is compared with the distribution information of the storage devices whose fault objects have been kicked out.
[0091] Step S203: when it is determined that the current distribution information is inconsistent with the historical distribution information, it is determined to reconstruct the placement group corresponding to the failed object storage device.
[0092] If the current distribution information is inconsistent with the historical distribution information, a capacity balancing operation is triggered to reconstruct the placement group corresponding to the failed object storage device.
[0093] The embodiment of the present invention provides a distributed storage pool high water level reconstruction strategy optimization method, in which the water level information of the storage pool (i.e., the usage of storage resources) is used to evaluate the necessity of reconstruction and optimize the allocation of storage resources. The number of placement groups in the storage pool helps to simulate and optimize data distribution more accurately. The status information of the object storage device is used to distinguish the object storage device that has failed and the object storage device that has not failed. This information and the number of placement groups in the storage pool are input into the data separation algorithm to summarize, which can simulate the current separation information of the placement group in the storage pool after the storage device of the failed object is kicked out. By comparing the historical distribution information with the current distribution information, it can be ensured that the data remains consistent after the failure occurs, thereby improving the reliability of the data. By simulating the distribution of the failed device after being kicked out, possible data distribution problems can be predicted in advance, reducing the reaction time when the actual failure occurs. The simulation results help decision makers determine whether the placement group needs to be reconstructed, thereby avoiding unnecessary reconstruction operations. Based on historical and current data, the system can intelligently adjust the storage pool configuration to improve resource utilization efficiency. Determine the best reconstruction time to reduce data interruption and system downtime. The water level reconstruction strategy generated based on the current water level information helps to accurately control data migration and avoid resource waste. Automated processes and intelligent decision-making reduce the workload of operation and maintenance and improve operation and maintenance efficiency. By optimizing storage resource utilization and reducing unnecessary reconstruction, operation and maintenance costs are controlled.
[0094] In this embodiment, a distributed storage pool high water level reconstruction strategy optimization method is provided, which can be used for the above-mentioned mobile terminals, such as mobile phones, tablet computers, etc. Figure 3 FIG. 1 is a flow chart of another distributed storage pool high water level reconstruction strategy optimization method provided by an embodiment of the present invention. Figure 3 shown.
[0095] Specifically, the storage pool information also includes the redundancy type of the storage pool and the data storage capacity of the placement group corresponding to each object storage device in the storage pool.
[0096] Based on any of the above embodiments, if reconstruction is performed, the current water level information of each object storage device in a normal state is determined according to the reconstruction preset bandwidth, the current distribution information, and the storage pool information, specifically including:
[0097] Step 301 : Determine the total capacity to be reconstructed according to the redundancy type of the storage pool, current distribution information, and the data storage capacity of the placement group corresponding to the object storage device that has failed in the storage pool.
[0098] In an optional example, the total capacity to be reconstructed may be determined by referring to the following method steps:
[0099] Step a1: extracting a first mapping relationship from current distribution information.
[0100] Specifically, the first mapping relationship is a first mapping relationship re-established between the placement group to which the data stored in the failed object storage device belongs and the object storage device in a normal state.
[0101] Step a2, determining the raw capacity of the placement group corresponding to the failed object storage device on the normal object storage device with which the first mapping relationship is established, based on the redundancy type of the storage pool and the data storage capacity of the placement group corresponding to the failed object storage device.
[0102] Specifically, the redundancy type of the storage pool is obtained, and the method for obtaining the raw capacity on the object storage device is determined based on the redundancy type. If the redundancy type of the storage pool is a replica type, the raw capacity of the placement group on the object storage device is the data storage capacity of the placement group corresponding to the failed object storage device.
[0103] If the redundancy type of the storage pool is the erasure K+M type, the raw capacity of the placement group on the object storage device is the data storage capacity of the placement group corresponding to the failed object storage device divided by the total number of fragments into which the original data is divided and the number of check fragments.
[0104] In a specific example, there are two conversion methods for the raw capacity of the placement group on the object storage device in a normal state with which the first mapping relationship is established based on the redundancy type of the storage pool. The first is when the redundancy type of the storage pool is copy, the raw capacity of the placement group on the object storage device is the data amount of the current placement group. The second is when the redundancy type of the storage pool is erasure K+M, the raw capacity of the placement group on the object storage device = the data amount of the placement group / (K+M), where K is the number of fragments into which the original data is divided, and M is the number of check fragments.
[0105] Step a3: determining the total capacity to be reconstructed based on the raw capacity of the placement group corresponding to the failed object storage device on the normal object storage device with which the first mapping relationship is established.
[0106] In a specific example, the object storage device members corresponding to the placement group PG1.0 include (osd.0, osd.2, osd.4), that is, the data in the placement group is stored (or backed up) on different OSD devices, such as osd.0, osd.2, and osd.4. At this time, it is found that osd.4 fails, and if the simulation kicks osd.4 out. After the simulation determines that the placement group PG1.0 needs to be reconstructed, the data storage capacity of the placement group in osd.4 needs to be allocated to the member osd.6 that has not failed. Then, according to the redundancy type of the storage pool and the data storage capacity of osd.4 corresponding to the placement group, it will constitute part of the raw capacity on osd.6. Of course, if there are other OSD devices that fail, and the data storage capacity of the corresponding placement group is also allocated to osd.6, it is also necessary to determine this part of the raw capacity according to the above method, and finally determine the sum of all raw capacities that need to be transferred to the osd.6 device, that is, the raw capacity of the placement group corresponding to the failed object storage device on the object storage device in a normal state that has established a first mapping relationship with itself. Here, osd.6 is the object storage device in a normal state that the placement group corresponding to the failed object storage device has established a first mapping relationship with itself. Therefore, the function of the first mapping relationship is to find the object storage device that the placement group corresponding to the failed object storage device needs to migrate data.
[0107] Step S302, determining the current water level information of each object storage device in a normal state according to the reconstructed preset bandwidth, the total capacity to be reconstructed, the current distribution information, the number of placement groups in the storage pool, and the data storage capacity of the placement groups corresponding to the object storage devices in a normal state in the storage pool.
[0108] In an optional example, the specific implementation details of the method steps are shown in Figure 4 As shown, the following steps are included:
[0109] Step S401: predicting the service data increment during the reconstruction period according to the reconstructed preset bandwidth and the total capacity to be reconstructed.
[0110] Specifically, based on the total capacity to be reconstructed and the preset bandwidth for reconstruction, the data reconstruction time is predicted, that is, the total capacity to be reconstructed is divided by the preset bandwidth for reconstruction to calculate the data reconstruction time. Based on the business data increment during the failure of the object storage device that has failed and the time of the failure, the business data growth rate is obtained, and the business data growth rate is calculated by dividing the number by the time to equal the speed. Using the data reconstruction time and the business data growth rate, the business data increment during the reconstruction period is predicted, and the business data increment during the reconstruction period can be obtained by multiplying the data reconstruction time by the business data growth rate.
[0111] Step S402: based on the number of placement groups in the storage pool and the service data increment during the reconstruction, obtain the average data increment of each placement group.
[0112] Specifically, based on the number of placement groups in the storage pool, the service data increment during the reconstruction period is evenly distributed to each placement group, and the average data increment of each placement group is simulated.
[0113] Step S403, based on the current distribution information of the placement groups in the storage pool, the redundancy type of the storage pool, the number of placement groups in the storage pool, the average data increment of each placement group, and the storage capacity information of each object storage device in a normal state, determine the current water level information of each object storage device in a normal state.
[0114] Specifically, based on the current distribution information of the placement groups in the storage pool and the number of placement groups in the storage pool, the average data increment of each placement group is added to the stored capacity information of each object storage device in a normal state. The stored capacity of the object storage device in a normal state plus the average data increment of each placement group is the current water level information of the object storage device in a normal state.
[0115] Specifically, in the above method steps, the current water level information of the object storage device in normal state is determined based on the total amount to be reconstructed and the incremental business data. By optimizing the water level reconstruction strategy, the data can be more evenly distributed in the storage pool, thereby improving the availability and reliability of the data. Accurately predict the water level increase caused by reconstruction after a hard disk failure in a high water level scenario, and make a prediction of the incremental business during the reconstruction. Set the danger level based on the difference with the preset value, and then control whether automatic reconstruction needs to be triggered, and how to adjust the reconstruction speed after the reconstruction is triggered, to prevent incomplete data reconstruction from affecting business reading and writing. The usability of the product is improved, and the optimization strategy can help better manage redundant data, ensuring that the system can still quickly restore data when some storage nodes fail.
[0116] In this embodiment, a distributed storage pool high water level reconstruction strategy optimization method is provided, which can be used for the above-mentioned mobile terminal, such as a mobile phone, a tablet computer, etc. Based on the method corresponding to any of the above-mentioned embodiments, in an optional example, when it is determined that the failed object storage device cannot be kicked out according to the current water level information of each object storage device in a normal state, the following method steps are also included, for example, including:
[0117] Step b1, saving the water level information of each object storage device in the storage pool.
[0118] Step b2: periodically detect changes in the water level information of each object storage device.
[0119] Step b3: when it is determined according to the change that the water level information of the first object storage device drops below a preset water level threshold, it is re-determined whether the object storage device that has failed meets the kick-out condition.
[0120] The first object storage device is any object storage device in the storage pool.
[0121] Specifically, the water level information of each object storage device is periodically judged according to the above process, for example, it is recalculated and judged every five minutes according to the above judgment process; if the faulty object storage device is not allowed to be kicked out, the current water level in the storage pool involved in the faulty object storage device is saved, and the water level is detected based on the timer function. If the water level drops by more than 2%, the judgment is made again until the kick-out conditions are met, and the recorded object storage device water level information is cleared.
[0122] In layman's terms, there is a faulty object storage device that has failed before but did not meet the kick-out conditions at that time. In the subsequent process, it is necessary to repeatedly judge it according to the preset cycle until the kick-out conditions are met, and then stop judging and kick out the faulty object storage device.
[0123] In a specific example, for example, if the data volume water level on the object storage device calculated by simulation exceeds the preset threshold of 93%, the faulty object storage device is not allowed to be kicked out and is recorded at the same time; if the data volume on the object storage device calculated by simulation does not exceed the preset value of 93%, the danger level is set according to the difference with the preset water level. When the difference between the water level of all object storage devices and the preset water level is greater than 20%, the danger level is safe; when the difference between the water level of all object storage devices and the preset water level is between 5% and 20%, the danger level is warning; when the difference between the water level of all object storage devices and the preset water level is within 5%, the danger level is dangerous;
[0124] However, in actual applications, it is necessary to preset the range of danger levels according to actual conditions and set the preset values based on actual conditions.
[0125] In an optional example, when it is determined according to the current water level information of each object storage device in a normal state that the object storage device that has failed is kicked out, the method includes the following steps:
[0126] Step c1: after executing the operation of kicking out the failed object storage device, determine whether to trigger a reconstruction operation.
[0127] Step c2: identifying the danger level corresponding to the current water level information of each object storage device in a normal state.
[0128] Step c3: when it is determined that the reconstruction operation is triggered, the actual service increment generated within the reconstruction time is obtained.
[0129] Specifically, the actual business increment generated during the reconstruction time is obtained in order to control the subsequent reconstruction speed.
[0130] The reconstruction control strategy is determined based on the danger level, data reconstruction time, actual business increment, and predicted business data increment during the reconstruction period corresponding to the current water level information of each object storage device in a normal state.
[0131] Specifically, if the kick-out triggers reconstruction and is at a dangerous level, it is also necessary to monitor data writing in the timer function and adjust different reconstruction strategies according to the predicted reconstruction estimate time and the business increment during the reconstruction period.
[0132] In a specific example, for example: within 50% of the estimated reconstruction time, and the actual business increment is less than 50% of the estimated business increment, no adjustment is made; within 50% of the estimated reconstruction time, and the actual business increment is greater than 50% of the estimated business increment, the business growth rate is calculated based on the current actual business increment and the actual reconstruction time, the estimated business increment is subtracted from the actual business increment to obtain the remaining business increment, the remaining business increment is divided by the business growth rate to obtain the remaining reconstruction time, and the reconstruction speed is obtained by dividing the current remaining reconstruction data volume by the remaining reconstruction time. If the current reconstruction speed is greater than the calculated value, it remains unchanged, otherwise it is adjusted to the calculated value.
[0133] In this embodiment, a distributed storage pool high water level reconstruction strategy optimization method is provided, which can be used for the above-mentioned mobile terminals, such as mobile phones, tablet computers, etc. Figure 5 Schematic diagram of the overall process of a distributed storage pool high water level reconstruction strategy optimization method provided by an embodiment of the present invention. Figure 5 As shown, the details are as follows:
[0134] Step 1: Get the OSD that failed this time, and record the storage pool information involved in the current new failed OSD.
[0135] Specifically, when an OSD fails, the current object storage device data set of the cluster is copied first. Because the object storage device data in the cluster will change, the subsequent simulation process is based on the copied object storage device data set for simulation, avoiding the problem of incorrect simulation results due to changes in object storage device data, and obtaining the OSD that failed this time in the copied object storage device data set.
[0136] In a specific example, the storage pool information involved in all OSDs in the copied object storage device data set is obtained, including OSDs that have failed and OSDs that have not failed, and the failed OSD in the copied object storage device data set is marked as OUT, simulating the storage pool information involved after the failed OSD is kicked out.
[0137] Step 2: Simulate and calculate the placement group distribution information after the failed OSD is kicked out.
[0138] Specifically, based on the storage pool information involved after the failed OSD is kicked out, the placement group distribution information after the failed OSD is kicked out is calculated using a data distribution algorithm.
[0139] Step 3: Calculate the current data volume of the OSD and the total capacity to be reconstructed based on the placement group distribution information and the placement group data volume.
[0140] Specifically, the redundancy type of the storage pool is obtained, and the method for obtaining the raw capacity on the object storage device is determined based on the redundancy type. If the redundancy type of the storage pool is a copy type, the raw capacity of the placement group on the object storage device is the data storage capacity of the placement group corresponding to the failed object storage device. If the redundancy type of the storage pool is an erasure K+M type, the raw capacity of the placement group on the object storage device is the data storage capacity of the placement group corresponding to the failed object storage device divided by the total number of fragments into which the original data is divided and the number of check fragments.
[0141] All placement groups in the storage pool are traversed to obtain the raw capacity of all placement groups on the object storage device, and the sum of the raw capacity of all placement groups in the storage pool on the object storage device is determined as the total capacity to be reconstructed.
[0142] For example: the members of the placement group are OSD1, OSD2, and OSD4. When OSD4 fails, the members of the placement group are OSD1 and OSD2. After simulation calculation, the members are OSD1, OSD2, and OSD6. Then the placement group needs to reconstruct the data to OSD6. Therefore, the current water level of OSD6 is the amount of data stored in OSD6 plus the amount of data to be reconstructed.
[0143] Step 4: simulate and calculate the business increment during the reconstruction period and add the business increment during the reconstruction period to the OSD data volume to obtain the current water level information of each object storage device in a normal state.
[0144] The time required for data reconstruction is calculated by dividing the total capacity to be reconstructed by the preset reconstruction bandwidth. Then, the business data increment during the object storage device failure is divided by the failure time to obtain the business data growth rate. Then the business data growth rate is multiplied by the time required for data reconstruction to obtain the business data increment during reconstruction. Based on the current distribution information of the placement group, the business data increment during reconstruction is evenly distributed to each placement group, and the average data increment of each placement group is simulated to determine the current water level information of each object storage device in normal state.
[0145] Step 5: Determine whether the current water level information of each object storage device in a normal state exceeds a threshold.
[0146] If the current water level information of each object storage device in a normal state does not exceed the threshold, the faulty OSD can be kicked out. If the current water level information of each object storage device in a normal state exceeds the threshold, the faulty OSD cannot be kicked out.
[0147] In a specific example, when the hard disk of the node failure is a solid state drive (SSD), when the number of failed OSDs exceeds 30%, it is determined whether the failed OSDs are allowed to be kicked out.
[0148] Step 6: If the faulty OSD is allowed to be kicked out, set the danger level.
[0149] If the faulty OSD is allowed to be kicked out and the risk level is dangerous, adjust the data reconstruction speed according to the business increment.
[0150] Step 7: If the faulty OSD is not allowed to be kicked out, the OSD that failed before and was not kicked out is re-detected and calculated periodically or according to the water level change to determine whether it can be kicked out.
[0151] In an optional example, a storage pool water level reconstruction model can be constructed based on ARIMA (Autoregressive Integrated Moving Average) as a time series prediction model. For details, see the following:
[0152] Collect historical data, including storage usage, read and write load, and node status.
[0153] Specifically, the space utilization on each storage device or node is monitored and recorded, and the read and write request volume of each storage unit is obtained.
[0154] The storage pool water level reconstruction model is trained using historical data.
[0155] Parameters such as storage utilization, read / write load, and node status are preprocessed, and the preprocessed data is used to train the storage pool water level reconstruction model. The preprocessing includes removing outliers, filling missing values, and normalizing data.
[0156] The storage pool water level reconstruction model is used to predict whether the faulty object storage device can be reconstructed.
[0157] By predicting future load conditions and making dynamic adjustments, we can balance the load between nodes, reduce hot spots, and improve the overall system performance. The storage pool reconstruction optimization method based on prediction and adaptive adjustment can effectively manage the state of the storage pool and improve the overall performance and reliability of the system.
[0158] Specifically, in the above method steps, the business growth rate is calculated based on the current actual business increment and the actual reconstruction time, the remaining business increment is obtained by subtracting the actual business increment from the estimated business increment, the remaining reconstruction time is obtained by dividing the remaining business increment by the business growth rate, and the reconstruction speed is obtained by dividing the current remaining reconstruction data volume by the remaining reconstruction time. The reconstruction speed is adjusted based on the business growth rate and reconstruction time, and the danger level is set according to the difference with the preset value. Then, it can be controlled whether automatic reconstruction needs to be triggered, and how to adjust the reconstruction speed after the reconstruction is triggered, so as to prevent incomplete data reconstruction from affecting business reading and writing. The usability of the product is improved.
[0159] In this embodiment, a distributed storage pool high water level reconstruction strategy optimization device is also provided, which is used to implement the above-mentioned embodiments and preferred implementation modes, and will not be repeated here. As used below, the term "module" can be a combination of software and / or hardware that implements a predetermined function. Although the device described in the following embodiments is preferably implemented in software, the implementation of hardware, or a combination of software and hardware, is also possible and conceivable.
[0160] This embodiment provides a distributed storage pool high water level reconstruction strategy optimization device, such as Figure 6 As shown, including:
[0161] The data acquisition module 601 is used to acquire an object storage device data set and historical distribution information of a placement group in a storage pool, wherein the object storage device data set includes status information corresponding to a plurality of object storage devices, and storage pool information to which the plurality of object storage devices belong, wherein the plurality of object storage devices include object storage devices that have failed and object storage devices that are in a normal state;
[0162] The processing module 602 is used to simulate and determine, based on the status information of each of the object storage devices and the storage pool information, the current distribution information of the placement group in the storage pool after the failed object storage device is kicked out, and determine whether to reconstruct the placement group corresponding to the failed object storage device;
[0163] The water level acquisition module 603 is used to determine the current water level information of each object storage device in a normal state according to the preset reconstruction bandwidth, the current distribution information, and the storage pool information if reconstruction is performed;
[0164] The processing module 602 is further configured to generate a water level reconstruction strategy according to the current water level information, wherein the water level reconstruction strategy is used to indicate whether to kick out the object storage device that has failed.
[0165] In an optional example, the storage pool information includes water level information of the storage pool and the number of placement groups in the storage pool; the processing module 602 is specifically used to:
[0166] Input the status information of each object storage device, the water level information of the storage pool, and the number of placement groups in the storage pool into the data distribution algorithm to simulate the current distribution information of the placement groups in the storage pool after the failed object storage device is kicked out;
[0167] Comparing the current distribution information with the historical distribution information;
[0168] When it is determined that the current distribution information is inconsistent with the historical distribution information, it is determined to reconstruct the placement group corresponding to the failed object storage device.
[0169] In an optional example, the storage pool information further includes a redundancy type of the storage pool and a placement group data storage capacity corresponding to each of the object storage devices in the storage pool;
[0170] The water level acquisition module 603 is used to determine the total capacity to be reconstructed according to the redundancy type of the storage pool, the current distribution information, and the data storage capacity of the placement group corresponding to the object storage device that has failed in the storage pool;
[0171] The current water level information of each object storage device in a normal state is determined according to the preset reconstruction bandwidth, the total capacity to be reconstructed, the current distribution information, the number of placement groups in the storage pool, and the data storage capacity of the placement groups corresponding to the object storage devices in a normal state in the storage pool.
[0172] In an optional example, the processing module 602 is specifically configured to extract a first mapping relationship from the current distribution information, where the first mapping relationship is a first mapping relationship re-established between a placement group to which data stored in the failed object storage device belongs and an object storage device in a normal state;
[0173] Determine, according to the redundancy type of the storage pool and the data storage capacity of the placement group corresponding to the failed object storage device, the raw capacity of the placement group corresponding to the failed object storage device on the object storage device in a normal state with which the first mapping relationship is established;
[0174] The total capacity to be reconstructed is determined based on the raw capacity of the placement group corresponding to the failed object storage device on the normal object storage device with which the placement group has established a first mapping relationship.
[0175] In an optional example, the water level acquisition module 603 is specifically used to predict the service data increment during the reconstruction period according to the reconstructed preset bandwidth and the total capacity to be reconstructed;
[0176] Based on the number of placement groups in the storage pool and the service data increment during the reconstruction, an average data increment of each placement group is obtained;
[0177] Based on the current distribution information of the placement groups in the storage pool, the redundancy type of the storage pool, the number of placement groups in the storage pool, the average data increment of each of the placement groups, and the data storage capacity of the placement groups corresponding to the object storage devices in the storage pool that are in a normal state, determine the current water level information of each of the object storage devices that are in a normal state.
[0178] In an optional example, the water level acquisition module 603 is specifically used to predict the data reconstruction time based on the total capacity to be reconstructed and the reconstruction preset bandwidth;
[0179] Obtaining a business data growth rate based on a business data increment during a failure of the object storage device that has failed and a failure occurrence time;
[0180] The data reconstruction time and the business data growth rate are used to predict the business data increment during the reconstruction period.
[0181] In an optional example, the processing module 602 is further configured to save the water level information of each of the object storage devices in the storage pool when the water level reconstruction strategy indicates that the failed object storage device cannot be kicked out;
[0182] Periodically detecting changes in water level information of each of the object storage devices;
[0183] When it is determined according to the change that the water level information of the first object storage device drops below a preset water level threshold, it is re-determined whether the failed object storage device meets the kick-out condition, wherein the first object storage device is any object storage device in the storage pool.
[0184] In an optional example, the processing module 602 is further configured to determine whether to trigger a reconstruction operation after executing an operation of kicking out the failed object storage device when the water level reconstruction strategy indicates that the failed object storage device is kicked out;
[0185] Identify the danger level corresponding to the current water level information of each object storage device in a normal state;
[0186] When determining to trigger the reconstruction operation, obtaining the actual service increment generated during the reconstruction time;
[0187] A reconstruction control strategy is determined according to the danger level corresponding to the current water level information of each object storage device in a normal state, the data reconstruction time, the actual business increment, and the predicted business data increment during the reconstruction period.
[0188] The further functional description of each of the above modules and units is the same as that of the above corresponding embodiments and will not be repeated here.
[0189] The distributed storage pool high water level reconstruction strategy optimization device in this embodiment is presented in the form of a functional unit, where the unit refers to an ASIC (Application Specific Integrated Circuit) circuit, a processor and memory that executes one or more software or fixed programs, and / or other devices that can provide the above functions.
[0190] This embodiment provides a distributed storage pool high water level reconstruction strategy optimization device. In the above method, by timely reconstructing the placement group when the object storage device fails, it can ensure that data is not lost due to the failure, and improve the reliability of data storage. Therefore, by automatically identifying the faulty device and simulating the reconstruction process, through pre-simulation and strategy generation, the uncertainty and potential cost in the actual reconstruction process can be reduced. Reduce the risk caused by improper data migration during the reconstruction process. Quickly determine whether reconstruction is required and how to reconstruct, which can shorten the system response time to the failure and improve the overall performance. By effectively managing and replacing the faulty device, the stability and fault tolerance of the system can be enhanced. Furthermore, by reasonably allocating and adjusting storage resources, the utilization rate of the storage space in the storage pool can be maximized. According to the current water level information, the system can dynamically allocate resources to ensure the balance of the storage pool. Finally, according to the water level reconstruction strategy, it is determined whether to kick out the failed object storage device, and the high availability of the system is maintained by timely reconstruction and optimization of resource allocation.
[0191] The embodiment of the present invention also provides a computer device having the above Figure 6 The distributed storage pool high water level reconstruction strategy optimization device shown.
[0192] See also Figure 7 , Figure 7 is a schematic diagram of the structure of a computer device provided by an optional embodiment of the present invention, such as Figure 7 As shown, the computer device includes: one or more processors 10, a memory 20, and interfaces for connecting various components, including high-speed interfaces and low-speed interfaces. Various components are connected to each other using different buses for communication, and can be installed on a common mainboard or installed in other ways as needed. The processor can process the instructions executed in the computer device, including instructions stored in or on the memory to display the graphical information of the GUI on an external input / output device (such as, a display device coupled to the interface). In some optional embodiments, if necessary, multiple processors and / or multiple buses can be used together with multiple memories and multiple memories. Similarly, multiple computer devices can be connected, and each device provides some necessary operations (for example, as a server array, a group of blade servers, or a multi-processor system). Figure 7 A processor 10 is taken as an example.
[0193] The processor 10 may be a central processing unit, a network processor or a combination thereof. The processor 10 may further include a hardware integrated circuit. The hardware integrated circuit may be a dedicated integrated circuit, a programmable logic device or a combination thereof. The programmable logic device may be a complex programmable logic device, a field programmable logic gate array, a general purpose array logic or any combination thereof.
[0194] The memory 20 stores instructions executable by at least one processor 10, so that at least one processor 10 executes the method shown in the above embodiment.
[0195] The memory 20 may include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application required for at least one function; the data storage area may store data created according to the use of the computer device, etc. In addition, the memory 20 may include a high-speed random access memory, and may also include a non-transient memory, such as at least one disk storage device, a flash memory device, or other non-transient solid-state storage device. In some optional embodiments, the memory 20 may optionally include a memory remotely arranged relative to the processor 10, and these remote memories may be connected to the computer device via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.
[0196] The memory 20 may include a volatile memory, such as a random access memory; the memory may also include a non-volatile memory, such as a flash memory, a hard disk or a solid state drive; the memory 20 may also include a combination of the above types of memory.
[0197] The computer device further comprises a communication interface 30 for the computer device to communicate with other devices or a communication network.
[0198] The embodiment of the present invention also provides a computer-readable storage medium. The method according to the embodiment of the present invention can be implemented in hardware, firmware, or can be implemented as a computer code that can be recorded in a storage medium, or can be implemented as a computer code that is originally stored in a remote storage medium or a non-temporary machine-readable storage medium and will be stored in a local storage medium through a network download, so that the method described herein can be stored in such software processing on a storage medium using a general-purpose computer, a dedicated processor, or programmable or dedicated hardware. Among them, the storage medium can be a magnetic disk, an optical disk, a read-only storage memory, a random access memory, a flash memory, a hard disk or a solid-state hard disk, etc.; further, the storage medium can also include a combination of the above types of memories. It can be understood that a computer, a processor, a microprocessor controller, or programmable hardware includes a storage component that can store or receive software or computer code. When the software or computer code is accessed and executed by a computer, a processor, or hardware, the method shown in the above embodiment is implemented.
[0199] A part of the present invention can be applied as a computer program product, such as a computer program instruction, when it is executed by a computer, through the operation of the computer, the method and / or technical solution according to the present invention can be called or provided. It should be understood by those skilled in the art that the existence form of the computer program instruction in the computer-readable medium includes but is not limited to source files, executable files, installation package files, etc., and accordingly, the way in which the computer program instruction is executed by the computer includes but is not limited to: the computer directly executes the instruction, or the computer compiles the instruction and then executes the corresponding compiled program, or the computer reads and executes the instruction, or the computer reads and installs the instruction and then executes the corresponding installed program. Here, the computer-readable medium can be any available computer-readable storage medium or communication medium accessible to the computer. Although the embodiments of the present invention are described in conjunction with the accompanying drawings, those skilled in the art can make various modifications and variations without departing from the spirit and scope of the present invention, and such modifications and variations all fall within the scope defined by the attached claims.
Claims
1. A distributed storage pool high water level reconstruction strategy optimization method, characterized in that: The method comprises: Obtaining an object storage device data set and historical distribution information of a placement group in a storage pool, wherein the object storage device data set includes status information corresponding to a plurality of object storage devices, and storage pool information to which the plurality of object storage devices belong, wherein the plurality of object storage devices include object storage devices that have failed and object storage devices that are in a normal state; Based on the status information of each of the object storage devices and the storage pool information, simulate and determine the current distribution information of the placement group in the storage pool after the failed object storage device is kicked out, and determine whether to reconstruct the placement group corresponding to the failed object storage device; If reconstruction is performed, the current water level information of each object storage device in a normal state is determined according to the reconstruction preset bandwidth, the current distribution information, and the storage pool information; A water level reconstruction strategy is generated according to the current water level information, wherein the water level reconstruction strategy is used to indicate whether to kick out the object storage device that has failed.
2. The distributed storage pool high water level reconstruction strategy optimization method according to claim 1 is characterized in that: The storage pool information includes water level information of the storage pool and the number of placement groups in the storage pool; The step of simulating and determining, based on the status information of each of the object storage devices and the storage pool information, the current distribution information of the placement group in the storage pool after the failed object storage device is kicked out, and determining whether to reconstruct the placement group corresponding to the failed object storage device, specifically includes: Input the status information of each object storage device, the water level information of the storage pool, and the number of placement groups in the storage pool into the data distribution algorithm to simulate the current distribution information of the placement groups in the storage pool after the failed object storage device is kicked out; Comparing the current distribution information with the historical distribution information; When it is determined that the current distribution information is inconsistent with the historical distribution information, it is determined to reconstruct the placement group corresponding to the failed object storage device.
3. The distributed storage pool high water level reconstruction strategy optimization method according to claim 2 is characterized in that: The storage pool information also includes the redundancy type of the storage pool and the data storage capacity of the placement group corresponding to each of the object storage devices in the storage pool; If reconstruction is performed, the current water level information of each object storage device in a normal state is determined according to the reconstruction preset bandwidth, the current distribution information, and the storage pool information, specifically including: Determine the total capacity to be reconstructed according to the redundancy type of the storage pool, the current distribution information, and the data storage capacity of the placement group corresponding to the object storage device that has failed in the storage pool; The current water level information of each object storage device in a normal state is determined according to the preset reconstruction bandwidth, the total capacity to be reconstructed, the current distribution information, the number of placement groups in the storage pool, and the data storage capacity of the placement groups corresponding to the object storage devices in a normal state in the storage pool.
4. The distributed storage pool high water level reconstruction strategy optimization method according to claim 3 is characterized in that: The determining the total capacity to be reconstructed according to the redundancy type of the storage pool, the current distribution information, and the data storage capacity of the placement group corresponding to the object storage device that has failed in the storage pool includes: Extracting a first mapping relationship from the current distribution information, where the first mapping relationship is a first mapping relationship re-established between a placement group to which data stored in the failed object storage device belongs and an object storage device in a normal state; Determine, according to the redundancy type of the storage pool and the data storage capacity of the placement group corresponding to the failed object storage device, the raw capacity of the placement group corresponding to the failed object storage device on the object storage device in a normal state with which the first mapping relationship is established; The total capacity to be reconstructed is determined based on the raw capacity of the placement group corresponding to the failed object storage device on the normal object storage device with which the placement group has established a first mapping relationship.
5. The distributed storage pool high water level reconstruction strategy optimization method according to claim 3 or 4, characterized in that: The method of determining the current water level information of each object storage device in a normal state according to the preset reconstruction bandwidth, the total capacity to be reconstructed, the current distribution information, the number of placement groups in the storage pool, and the data storage capacity of the placement groups corresponding to the object storage devices in a normal state in the storage pool includes: Predicting the service data increment during the reconstruction period according to the reconstruction preset bandwidth and the total capacity to be reconstructed; Based on the number of placement groups in the storage pool and the service data increment during the reconstruction, an average data increment of each placement group is obtained; Based on the current distribution information of the placement groups in the storage pool, the redundancy type of the storage pool, the number of placement groups in the storage pool, the average data increment of each of the placement groups, and the data storage capacity of the placement groups corresponding to the object storage devices in the storage pool that are in a normal state, determine the current water level information of each of the object storage devices that are in a normal state.
6. The distributed storage pool high water level reconstruction strategy optimization method according to claim 5 is characterized in that: The predicting of the service data increment during the reconstruction period according to the reconstructed preset bandwidth and the total capacity to be reconstructed includes: Predicting data reconstruction time based on the total capacity to be reconstructed and the preset reconstruction bandwidth; Obtaining a business data growth rate based on a business data increment during a failure of the object storage device that has failed and a failure occurrence time; The data reconstruction time and the business data growth rate are used to predict the business data increment during the reconstruction period.
7. The distributed storage pool high water level reconstruction strategy optimization method according to any one of claims 1 to 4, characterized in that: When the water level reconstruction strategy indicates that the failed object storage device cannot be kicked out, the method further includes: Saving water level information of each of the object storage devices in the storage pool; Periodically detecting changes in water level information of each of the object storage devices; When it is determined according to the change that the water level information of the first object storage device drops below a preset water level threshold, it is re-determined whether the failed object storage device meets the kick-out condition, wherein the first object storage device is any object storage device in the storage pool.
8. The distributed storage pool high water level reconstruction strategy optimization method according to claim 6 is characterized in that: When the water level reconstruction strategy indicates that the failed object storage device is kicked out, the method further includes: After executing the operation of kicking out the failed object storage device, determining whether to trigger a reconstruction operation; Identify the danger level corresponding to the current water level information of each object storage device in a normal state; When determining to trigger the reconstruction operation, obtaining the actual service increment generated during the reconstruction time; A reconstruction control strategy is determined according to the danger level corresponding to the current water level information of each object storage device in a normal state, the data reconstruction time, the actual business increment, and the predicted business data increment during the reconstruction period.
9. A distributed storage pool high water level reconstruction strategy optimization device, characterized in that: The device comprises: A data acquisition module, used to acquire an object storage device data set and historical distribution information of a placement group in a storage pool, wherein the object storage device data set includes status information corresponding to a plurality of object storage devices, and information of storage pools to which the plurality of object storage devices belong, wherein the plurality of object storage devices include object storage devices that have failed and object storage devices that are in a normal state; A processing module, configured to simulate and determine, based on the status information of each of the object storage devices and the storage pool information, the current distribution information of the placement groups in the storage pool after the failed object storage device is kicked out, and determine whether to reconstruct the placement group corresponding to the failed object storage device; A water level acquisition module, used for determining the current water level information of each object storage device in a normal state according to the preset reconstruction bandwidth, the current distribution information, and the storage pool information if reconstruction is performed; The processing module is further used to generate a water level reconstruction strategy according to the current water level information, wherein the water level reconstruction strategy is used to indicate whether to kick out the object storage device that has failed.
10. A computer device, characterized in that: include: A memory and a processor, wherein the memory and the processor are communicatively connected to each other, the memory stores computer instructions, and the processor executes the distributed storage pool high water level reconstruction strategy optimization method according to any one of claims 1 to 8 by executing the computer instructions.
11. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer instructions, and the computer instructions are used to enable a computer to execute the distributed storage pool high water level reconstruction strategy optimization method according to any one of claims 1 to 8.
Citation Information
Patent Citations
Distributed cluster storage pool capacity intelligent emergency system, method and medium
CN112631511A
Method, device and equipment for controlling data reconstruction and readable medium
CN113687798A
Method and device for checking validity of data reconstruction
CN117555735A
Distributed cluster data reconstruction method and device, and program product
CN118312103A
Ensuring Sufficient Available Storage Capacity for Data Resynchronization / Reconstruction in a Hyper-converged Infrastructure
US20210055872A1