Cluster resource management method, device, electronic device and storage medium
By migrating data according to the frequency of data access in cloud storage or supercomputing centers, migrating from high-rate storage space to low-rate space, the problem of low storage resource utilization and high cost is solved, and efficient utilization of storage resources is achieved. Cost savings.
Patent Information
- Application Number
- CN201911141045.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2019-11-20
- Publication Date
- 2024-09-17
- Estimated Expiration
- 2039-11-20
AI Technical Summary
In cloud storage or supercomputing centers, the large amount of storage space occupied by tenants results in inefficient storage billing models, poor user experience, and high storage fees.
By obtaining access frequency information of storage data in multi-level storage spaces, the data is migrated from high-rate storage space to low-rate storage space according to preset migration conditions, and data compression and management mode selection are performed before migration to optimize storage. Use of resources.
It improves the effective utilization of storage resources, reduces users' storage costs, and improves user experience.
Smart Images

Figure CN112825023B
Abstract
Description
Technical Field
[0001] The present application relates to the field of storage, and in particular to a cluster resource management method, device, electronic device and storage medium. Background Art
[0002] There are tens of thousands of tenants in cloud storage or supercomputing center's supercomputing clusters, and each tenant occupies a certain amount of storage space. The current storage billing model is generally based on the type of storage media and the amount of space occupied by the user, and the user experience needs to be improved. Summary of the invention
[0003] The embodiments of the present application provide a cluster resource management method, device, electronic device and storage medium, which can improve the effective utilization of storage resources and save storage costs for users.
[0004] In a first aspect, an embodiment of the present application provides a cluster resource management method, the method comprising: obtaining access frequency information of stored data in multi-level storage spaces in a cluster; in response to the access frequency information of first stored data in a first storage space satisfying a preset migration condition, migrating the first stored data from the first storage space to a second storage space, wherein the unit billing of the level to which the second storage space belongs is lower than the unit billing of the level to which the first storage space belongs.
[0005] Optionally, before migrating the first stored data from the first storage space to the second storage space, the method includes: obtaining the data volume of the first stored data; and determining the second storage space from the multi-level storage space based on the data volume and the first storage space.
[0006] Optionally, determining the second storage space from the multi-level storage space based on the data volume and the first storage space includes: determining a degradation parameter of the first stored data based on the data volume; and determining the second storage space based on the degradation parameter and the first storage space.
[0007] Optionally, determining the second storage space from the multi-level storage space based on the data volume and the first storage space includes: querying a preset mapping table based on the data volume and the first storage space to obtain the second storage space, wherein the preset mapping table includes a mapping relationship between a preset data volume range, a preset original storage space and a preset target storage space.
[0008] Optionally, the preset migration condition includes: the number of access times within a preset time period is lower than a first preset threshold, or the interval between the most recent access time and the current time exceeds a second preset threshold.
[0009] Optionally, the multi-level storage space includes three copies of solid-state hard disk storage space, erasure coded solid-state hard disk storage space, three copies of mechanical hard disk storage space, erasure coded mechanical hard disk storage space, shallow compression mechanical hard disk storage space and deep compression mechanical hard disk storage space.
[0010] Optionally, when the second storage space is the shallowly compressed mechanical hard disk storage space or the deeply compressed mechanical hard disk storage space, before migrating the first stored data from the first storage space to the second storage space, the method further includes: compressing and storing the first stored data in the first storage space.
[0011] Optionally, before migrating the first storage data from the first storage space to the second storage space, the method also includes: displaying a first page, wherein the first page includes a management mode selection control; determining a management mode of the first storage data based on an operation of the management mode selection control by a user to which the first storage data belongs, wherein the management mode includes a hosted mode or a manual mode.
[0012] Optionally, before migrating the first stored data from the first storage space to the second storage space, the method further includes: sending a data migration request to a user to which the first stored data belongs, wherein the data migration request includes information of the second storage space.
[0013] Optionally, migrating the first stored data from the first storage space to the second storage space includes: in response to receiving a data migration instruction sent by a user to which the first stored data belongs in response to the data migration request, migrating the first stored data from the first storage space to the second storage space.
[0014] Optionally, after migrating the first storage data from the first storage space to the second storage space, the method further includes: allocating the first storage space to the second storage data according to a specific time granularity.
[0015] Optionally, after migrating the first storage data from the first storage space to the second storage space, the method further includes: in response to detecting an access record of the first storage data in the second storage space, or the access frequency of the first storage data in the second storage space is higher than a third preset threshold, confirming whether the first storage space is occupied; and if the first storage space is not occupied, migrating the first storage data back to the first storage space.
[0016] In a second aspect, an embodiment of the present application provides a cluster resource management device, wherein the resource balancing device includes: an acquisition unit for acquiring access frequency information of stored data in multi-level storage spaces in a cluster; a migration unit for migrating the first stored data from the first storage space to a second storage space in response to the access frequency information of the first stored data in the first storage space satisfying a preset migration condition, wherein the unit billing of the level to which the second storage space belongs is lower than the unit billing of the level to which the first storage space belongs.
[0017] Optionally, before migrating the first stored data from the first storage space to the second storage space, the acquisition unit is further used to: acquire the data volume of the first stored data; and determine the second storage space from the multi-level storage space based on the data volume and the first storage space.
[0018] Optionally, in terms of determining the second storage space from the multi-level storage space based on the data volume and the first storage space, the acquisition unit is specifically used to: determine a degradation parameter of the first stored data based on the data volume; and determine the second storage space based on the degradation parameter and the first storage space.
[0019] Optionally, in terms of determining the second storage space from the multi-level storage space based on the data volume and the first storage space, the acquisition unit is specifically used to: query a preset mapping table based on the data volume and the first storage space to obtain the second storage space, wherein the preset mapping table includes a preset data volume range, a mapping relationship between a preset original storage space and a preset target storage space.
[0020] Optionally, the preset migration condition includes: the number of access times within a preset time period is lower than a first preset threshold, or the interval between the most recent access time and the current time exceeds a second preset threshold.
[0021] Optionally, the multi-level storage space includes three copies of solid-state hard disk storage space, erasure coded solid-state hard disk storage space, three copies of mechanical hard disk storage space, erasure coded mechanical hard disk storage space, shallow compression mechanical hard disk storage space and deep compression mechanical hard disk storage space.
[0022] Optionally, when the second storage space is the shallowly compressed mechanical hard disk storage space or the deeply compressed mechanical hard disk storage space, before migrating the first stored data from the first storage space to the second storage space, the migration unit is also used to: compress and store the first stored data in the first storage space.
[0023] Optionally, before migrating the first storage data from the first storage space to the second storage space, the migration unit is also used to: display a first page, wherein the first page includes a management mode selection control; based on the operation of the management mode selection control by the user to whom the first storage data belongs, determine the management mode of the first storage data, wherein the management mode includes a hosted mode or a manual mode.
[0024] Optionally, before migrating the first stored data from the first storage space to the second storage space, the migration unit is further used to: send a data migration request to a user to which the first stored data belongs, wherein the data migration request includes information about the second storage space.
[0025] Optionally, in terms of migrating the first stored data from the first storage space to the second storage space, the migration unit is specifically used to: in response to receiving a data migration instruction sent by a user to which the first stored data belongs in response to the data migration request, migrate the first stored data from the first storage space to the second storage space.
[0026] Optionally, after migrating the first storage data from the first storage space to the second storage space, the migration unit is further configured to: allocate the first storage space to the second storage data according to a specific time granularity.
[0027] Optionally, after migrating the first storage data from the first storage space to the second storage space, the migration unit is further used to: in response to detecting an access record of the first storage data in the second storage space, or the access frequency of the first storage data in the second storage space is higher than a third preset threshold, confirm whether the first storage space is occupied; and if the first storage space is not occupied, migrate the first storage data back to the first storage space.
[0028] In a third aspect, an embodiment of the present application provides an electronic device, comprising a processor, a memory, a communication interface, and one or more programs, wherein the one or more programs are stored in the memory and configured to be executed by the processor, and the program includes instructions for executing the steps in the first aspect of the embodiment of the present application.
[0029] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program for electronic data exchange, wherein the computer program enables a computer to execute part or all of the steps described in the first aspect of the embodiment of the present application.
[0030] In a fifth aspect, an embodiment of the present application provides a computer cluster, including a cluster resource management device and a cluster resource storage device, wherein the cluster resource storage device includes multi-level storage space, and the cluster resource management device is a cluster resource management device as described in the second aspect of the embodiment of the present application.
[0031] It can be seen that in the embodiment of the present application, the access frequency information of the data stored in the multi-level storage space in the cluster is obtained; in response to the access frequency information of the first storage data in the first storage space meeting the preset migration condition, the first storage data is migrated from the first storage space to the second storage space, wherein the unit billing of the level to which the second storage space belongs is lower than the unit billing of the level to which the first storage space belongs. It can be seen that the solution provided by the present invention can improve the effective utilization rate of storage resources and save storage costs for users. BRIEF DESCRIPTION OF THE DRAWINGS
[0032] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0033] Figure 1 A schematic diagram of the structure of a storage data level detection and data balancing system provided in an embodiment of the present application;
[0034] Figure 2 A schematic diagram of the multi-user storage space level division provided in an embodiment of the present application;
[0035] Figure 3 A schematic diagram of dynamic migration provided in an embodiment of the present application;
[0036] Figure 4 A schematic diagram of a cluster resource management method provided in an embodiment of the present application;
[0037] Figure 5 A schematic diagram of a preset mapping table provided in an embodiment of the present application;
[0038] Figure 6 A schematic diagram of management mode selection provided in an embodiment of the present application;
[0039] Figure 7 A schematic diagram of data migration provided in an embodiment of the present application;
[0040] Figure 8 A schematic diagram of a cluster resource management method provided in an embodiment of the present application;
[0041] Fig. 9 A schematic diagram of a cluster resource management method provided in an embodiment of the present application;
[0042] Fig.10 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application;
[0043] Fig.11 A schematic diagram of the structure of a computer cluster provided in an embodiment of the present application;
[0044] Fig.12 A schematic diagram of the structure of a cluster resource management device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0045] In order to enable those skilled in the art to better understand the solution of the present application, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.
[0046] The terms "first", "second", etc. in the specification and claims of this application and the above-mentioned drawings are used to distinguish different objects, rather than to describe a specific order. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions. For example, a process, method, system, product or device that includes a series of steps or units is not limited to the listed steps or units, but optionally includes steps or units that are not listed, or optionally includes other steps or units inherent to these processes, methods, products or devices.
[0047] Reference to "embodiments" herein means that a particular feature, structure, or characteristic described in conjunction with the embodiments may be included in at least one embodiment of the present application. The appearance of the phrase in various locations in the specification does not necessarily refer to the same embodiment, nor is it an independent or alternative embodiment that is mutually exclusive with other embodiments. It is explicitly and implicitly understood by those skilled in the art that the embodiments described herein may be combined with other embodiments.
[0048] The electronic devices involved in the embodiments of the present application may include various handheld devices with wireless communication functions, vehicle-mounted devices, wireless headsets, computing devices or other processing devices connected to wireless modems, as well as various forms of user equipment (UE), mobile stations (MS), terminal devices, etc. The electronic devices may be, for example, smart phones, tablet computers, etc. For the convenience of description, the above-mentioned devices are collectively referred to as electronic devices.
[0049] See also Figure 1 , Figure 1 A schematic diagram of the structure of the storage data level detection and data balancing system provided in the embodiment of the present application, wherein the system includes a fusion storage cluster (object storage or file storage), a user interface GUI, a user data level detection module, a dynamic migration module, and a user billing module. The storage space of the fusion storage cluster includes a user space and an archive space. The user space is used to store the data of each user, and the archive space is used to store system files such as the charging standards of user spaces at various levels, user operation logs, etc. For the convenience of expression, the user space is collectively referred to as the storage space below. Optionally, the storage space can be as follows Figure 2 As shown, they are divided into levels, such as Figure 2 As shown, Figure 2 This is a schematic diagram of the multi-user storage space level division provided in the embodiment of the present application. In the embodiment of the present application, the storage space can be divided into the following six types according to the storage cost:
[0050] 1) Three-copy SSD storage space (level 1 storage space). This storage space is the highest level and most expensive storage space. In this storage space, data is stored in the SSD storage medium and saved in three copies.
[0051] 2) Erasure Code SSD Storage Space (Level 2 Storage Space). The data in this storage space is active data, and all data is stored in the SSD storage medium, using erasure codes to achieve data security protection.
[0052] 3) Three-copy mechanical hard disk storage space (level 3 storage space). This storage space is the most commonly used storage space by users. In this storage space, data is stored in the mechanical hard disk storage medium and saved in three copies.
[0053] 4) Erasure Code Mechanical Hard Drive Storage Space (Level 4 Storage Space). In this storage space, data is stored in mechanical hard drive storage media, and erasure codes are used to achieve data security protection.
[0054] 5) Shallow compression mechanical hard disk storage space (level 5 storage space). This storage space is also called the cold data area. Before the stored data is migrated to this storage space, it is necessary to use a light compression algorithm (such as the gzip compression algorithm) to compress the stored data. The compression and decompression processes usually take minutes, and the compressed data volume does not shrink much.
[0055] 6) Deep compression mechanical hard disk storage space (6-level storage space). This storage space is also called the extremely cold data area. Before the stored data is migrated to this storage space, a deep compression algorithm (such as the 7zip compression algorithm) is required to compress the stored data. The compression and decompression processes usually take more than an hour. The compressed data volume is greatly reduced, and the storage space is saved significantly.
[0056] The storage space may be divided in other ways, which is not limited in this application.
[0057] It can be seen that the higher the storage space level, the slower the data processing speed, the lower the corresponding storage cost, and the lower the access frequency of the stored data. Figure 3 As shown, Figure 3 The dynamic migration diagram provided in the embodiment of the present application shows that if the stored data needs to be migrated to a shallow compression mechanical hard disk storage space or a deep compression mechanical hard disk storage space, the stored data needs to be compressed first, because the compression speed is faster in the first storage space, so the stored data is compressed before being migrated to the second storage space, which can reduce the data migration cost. Figure 3 In the process, the storage data of the three-copy solid-state hard disk storage space (level 1 storage space) needs to be migrated to the shallowly compressed mechanical hard disk storage space (level 5 storage space). Therefore, the storage data needs to be compressed first using a shallow compression algorithm and then migrated.
[0058] See also Figure 4 , Figure 4 A schematic diagram of a cluster resource management method provided in an embodiment of the present application, the method comprising:
[0059] 401. Obtain access frequency information of data stored in a multi-level storage space in a cluster.
[0060] Among them, the embodiment of the present application is applied to a supercomputing cluster, which is a supercomputing cluster with high performance, high efficiency and easy expansion. Optionally, the access frequency information can be obtained through timed scanning, and the time interval of the timed scanning can be set to once a day, twice a day or once every two days. The access frequency information of the stored data can be obtained through the Access (entry and exit) record, and the access frequency information includes the access frequency of the stored data within a preset time period, the interval between the last access time and the current time, etc.
[0061] 402. In response to access frequency information of first storage data in a first storage space satisfying a preset migration condition, migrate the first storage data from the first storage space to a second storage space, wherein a unit billing of a level to which the second storage space belongs is lower than a unit billing of a level to which the first storage space belongs.
[0062] Different storage spaces have different billing standards. The higher the level of storage space, the higher the storage cost, so the storage fee is also higher. For the same data, when it flows in different storage spaces, its fee also changes accordingly, and the fee granularity can be accurate to the minute level.
[0063] Among them, the preset migration conditions include: the number of access times within a preset time period is lower than a first preset threshold, or the interval between the most recent access time and the current time exceeds a second preset threshold. Different storage spaces may have different settings for the preset time period and the first preset threshold. Because the access frequency of the storage data in the higher-level storage space is relatively high, its preset time period is shorter and the first preset threshold is higher. For example, the preset time period of the three-copy solid-state hard disk storage space (level 1 storage space) can be set to 1 month, and the first preset threshold is 3 times. The preset time period of the erasure coded solid-state hard disk storage space (level 2 storage space) is set to 3 months, and the first preset threshold is 1 time. Therefore, if the storage data stored in the level 1 storage space has an access frequency of less than 3 times within 1 month, the storage data will be migrated to other storage spaces. Similarly, if the storage data stored in the level 2 storage space has no usage record within 3 months, the storage data will be migrated to other storage spaces with lower costs.
[0064] Migration will also occur when the interval between the last access time of the first storage data and the current time exceeds the second preset threshold. Different storage spaces may have different settings for the second preset threshold. The second preset threshold of a higher-level storage space may be smaller. For example, the second preset threshold of a three-copy solid-state drive storage space (level 1 storage space) is set to 3 months. If it exceeds three months and there is no access record of the first storage data in the storage space, it will be migrated.
[0065] It can be seen that in the embodiment of the present application, the access frequency information of the data stored in the multi-level storage space in the cluster is obtained; in response to the access frequency information of the first storage data in the first storage space meeting the preset migration condition, the first storage data is migrated from the first storage space to the second storage space, wherein the unit billing of the level to which the second storage space belongs is lower than the unit billing of the level to which the first storage space belongs. It can be seen that the solution provided by the present invention can improve the effective utilization rate of storage resources and save storage costs for users.
[0066] Optionally, before migrating the first stored data from the first storage space to the second storage space, the method includes:
[0067] Obtain the data volume of the first stored data;
[0068] Determine the second storage space from the multi-level storage spaces according to the data volume and the first storage space.
[0069] Optionally, the determining the second storage space from the multi-level storage spaces according to the data volume and the first storage space includes:
[0070] Determine the downgrading parameter of the first stored data according to the data volume;
[0071] Determine the second storage space based on the downgrading parameter and the first storage space.
[0072] Among them, the larger the volume of the first stored data, the more levels of storage spaces the migration spans, and the more time the migration requires. Also, during the migration of the stored data, the first stored data to be migrated will be locked, and the user cannot perform other operations on the first stored data (such as downloading data, deleting data, copying data, migrating data, etc.). For example, for the first stored data determined to need migration, its first storage space is the 1st-level storage space, its data volume (size) is Data_1, and the downgrading parameter for migration is a. If Data_1 <= 1GB, then a = 1, and the first stored data will be migrated to the 2nd-level storage space; if 1GB < Data_1 <= 5GB, then a = 2, and the first stored data will be migrated to the 3rd-level storage space; if 5GB < Data_1 <= 20GB, then a = 3, and the first stored data will be migrated to the 4th-level storage space; if 20GB < Data_1 <= 100GB, then a = 4, and the first stored data will be migrated to the 5th-level storage space; if 100GB < Data_1, then a = 5, and the first stored data will be migrated to the 6th-level storage space.
[0073] Optionally, the determining the second storage space from the multi-level storage spaces according to the data volume and the first storage space includes:
[0074] Query a preset mapping table based on the data volume and the first storage space to obtain the second storage space, where the preset mapping table includes a preset data volume range and a mapping relationship between a preset original storage space and a preset target storage space.
[0075] See Figure 5 , Figure 5 for the schematic diagram of the preset mapping table provided by the embodiments of the present application. Among them, in Figure 5In (a), the data volume is used as the vertical header and the storage space is used as the horizontal header. Different ranges of data volume and different original storage spaces correspond to different target storage spaces. The target storage space can be determined by querying the preset mapping table according to the range of data volume and original storage space. Optionally, the preset mapping table can also be as follows: Figure 5 As shown in (b), the storage space is used as the vertical header and the data volume is used as the horizontal header. This application does not limit the form of the preset mapping table.
[0076] It can be seen that the embodiment of the present application determines the preset second storage space according to the data volume and the preset original storage space, and can migrate the first stored data to the storage space with the highest cost performance.
[0077] Optionally, when the second storage space is the shallow compression mechanical hard disk storage space or the deep compression mechanical hard disk storage space, before migrating the first stored data from the first storage space to the second storage space, the method further includes:
[0078] The first stored data is compressed and stored in the first storage space.
[0079] Among them, the compression space includes shallow compression mechanical hard disk storage space (5-level storage space) and deep compression mechanical hard disk storage space (6-level storage space). If the second storage space is a 5-level storage space, the first storage data needs to be compressed by a light compression algorithm. If the second storage space is a 6-level storage space, the first storage data needs to be compressed by a deep compression algorithm. During the compression and migration of the first storage data, the first storage data will be locked, and the user cannot operate the first storage data to ensure the smooth completion of data compression and migration.
[0080] It can be seen that in this embodiment, by compressing the first stored data first and then migrating it, the compression time and the migration time are reduced, and the efficiency is improved.
[0081] Optionally, before migrating the first stored data from the first storage space to the second storage space, the method further includes:
[0082] displaying a first page, wherein the first page includes a management mode selection control;
[0083] Based on an operation of the management mode selection control by a user to which the first storage data belongs, a management mode of the first storage data is determined, wherein the management mode includes a trusteeship mode or a manual mode.
[0084] See also Figure 6 , Figure 6A schematic diagram of management mode selection provided for an embodiment of the present application, wherein the management modes include a hosting mode and a manual mode. In the figure, there is a hexagonal "compass" with a pointer in the center of the hexagonal compass. The six vertices of the hexagonal compass represent six storage spaces, respectively. Below the hexagonal compass, there are two option boxes, "manual switching" and "full hosting", i.e., management mode selection controls. Among them, the option box of "manual switching" is gray and is not a recommended option. If the user selects "manual switching", i.e., manual mode, the user can select the corresponding storage space for each file in the stored data by adjusting the pointer to the target vertex; if the user selects the "full hosting" option, i.e., selects the hosting mode, the system will automatically decide whether to migrate the stored data to other storage spaces based on the usage of the user's stored data.
[0085] When the management mode of the first storage data is the manual mode, the user can migrate any data in the storage data at any time, and the second storage space for data migration is selected by the user.
[0086] The management mode may also be selected in other ways, and the present application does not limit the presentation form of the first page and the management mode selection control.
[0087] It can be seen that the manual mode does not require users to manually copy data, and one-click switching is achieved. The user experience is greatly improved. The hosting mode can arrange reasonable storage space for the data in real time according to the usage of the data, realize the balanced use of storage resources, and reduce the user's storage costs.
[0088] Optionally, before migrating the first stored data from the first storage space to the second storage space, the method further includes:
[0089] A data migration request is sent to a user to which the first stored data belongs, wherein the data migration request includes information about the second storage space.
[0090] The migration request includes information such as the access frequency of the first storage data, the second storage space, and the billing standard of the second storage space. When the access frequency information of the first storage data meets the preset migration conditions, if the management mode of the first storage data is manual mode, the cluster will send a data migration request to the user to which the first storage data belongs. If the user chooses to agree to the migration, the first storage data will be migrated. If the user disagrees with the migration, the first storage data will not be migrated. If the management mode of the first storage data is managed mode, the cluster will send a data migration request to the user to which the first storage data belongs. The request is used to notify the user that the first storage data will be migrated. If the user confirms the request or does not respond to the request within a certain period of time, the first storage data will be automatically migrated.
[0091] Optionally, migrating the first stored data from the first storage space to the second storage space includes:
[0092] In response to receiving a data migration instruction in response to the data migration request sent by a user to which the first stored data belongs, the first stored data is migrated from the first storage space to a second storage space.
[0093] like Figure 7 As shown, Figure 7 A schematic diagram of data migration provided in the embodiment of the present application is shown in Figure 7 In Figure a, user 1's storage data is migrated to the deep compression mechanical hard disk storage space (second storage space). At the same time, user 2's storage data is hot data and needs to be expanded. Figure 7 In Figure b, the storage data of user 1 has been migrated, and its logical storage space remains unchanged, but the actual storage space becomes a deep compressed mechanical hard disk storage space. User 2's hot data occupies user 1's first storage space to achieve capacity expansion.
[0094] It can be seen that when a data center has multiple storage media (such as SSD and HDD) and many users use them, it is easy to encounter a situation where the number of users increases dramatically and the overall storage capacity is insufficient. At this time, the method provided in the embodiment of the present application can be used to achieve balanced allocation and effective utilization of the overall storage resources.
[0095] Optionally, after migrating the first stored data from the first storage space to the second storage space, the method further includes:
[0096] The first storage space is allocated to the second storage data according to a specific time granularity.
[0097] Among them, the user may frequently upload or download the stored data in a short period of time, so that the access frequency of the stored data in a short period of time increases. While the user is using it, a large amount of new data will be generated. Such stored data is called hot data. Because of the generation of new data, there is a need to expand the capacity of hot data. In order to improve the utilization rate of the entire storage space, the hot data that needs to be expanded will temporarily occupy the first storage space of the first storage data after the first storage data is migrated, thereby realizing temporary expansion. Among them, if the user's stored data volume is large, some data with low access frequency can be selected from it, and these data can be migrated to a storage space with lower cost to reduce costs. Because the user to whom the first storage space belongs may need to resume using the first storage space at any time, it is necessary to set a certain shared time granularity for the first storage space, that is, a specific time granularity, such as 12h, 1 day, 3 days, 7 days, etc. In the embodiment of the present application, the preset time granularity is set to 1 day.
[0098] It can be seen that by allocating free storage space to other storage data, the utilization rate of multi-level storage space can be improved.
[0099] Optionally, after migrating the first stored data from the first storage space to the second storage space, the method further includes:
[0100] In response to detecting an access record of the first stored data in the second storage space, or the access frequency of the first stored data in the second storage space being higher than a third preset threshold, confirming whether the first storage space is occupied;
[0101] When the first storage space is not occupied, the first stored data is migrated back to the first storage space.
[0102] Among them, the supercomputing cluster obtains the Access (entry and exit) access records of the storage buckets of each storage space, so as to determine the usage of the data stored in each storage space. Once the access record of the migrated first storage data is detected, or its access frequency is higher than the preset threshold, when the first storage space is not occupied, the first storage data is migrated back to the first storage space. Among them, the third preset threshold can be set to 5 times / month, 10 times / month, 20 times / half year, etc. In the embodiment of the present application, the specific time granularity is 1 day. Therefore, if the first storage data meets the requirements for migration back to the first storage space, and the first storage space is occupied, the data occupying the first storage space will be migrated to other free storage spaces on the next day, and then the first storage data will be migrated back to the first storage space. Among them, if the first storage data has been migrated (downgraded) at least twice, after the Access record is detected, the first storage data will still be migrated to the original storage space.
[0103] After migrating the first stored data back to the first storage space, the first stored data is decompressed. Because the decompression speed is faster in the first storage space and the cost of migrating compressed data is lower than that of migrating decompressed data, the stored data is migrated first and then decompressed.
[0104] It can be seen that the supercomputing cluster in the present application can monitor the dynamics of the stored data in real time after the data becomes "cold" and is migrated to other storage spaces, and perform migration operations on the data based on its access information, thereby realizing dynamic adjustment of the cold data.
[0105] See also Figure 8 , Figure 8 A schematic diagram of a cluster resource management method provided in an embodiment of the present application, the method comprising:
[0106] 801. Obtain a first storage space and data volume of first storage data;
[0107] 802. Determine a degradation parameter of the first stored data according to the data amount;
[0108] 803. Determine a second storage space based on the degradation parameter and the first storage space;
[0109] 804. Obtain access frequency information of data stored in the multi-level storage space in the cluster;
[0110] 805. In response to the access frequency information of the first storage data in the first storage space satisfying a preset migration condition, sending a data migration request to a user to which the first storage data belongs, wherein the data migration request includes information of the second storage space, and a unit billing of a level to which the second storage space belongs is lower than a unit billing of a level to which the first storage space belongs;
[0111] 806. In response to receiving a data migration instruction in response to the data migration request sent by the user to which the first stored data belongs, migrate the first stored data from the first storage space to the second storage space;
[0112] 807. Allocate the first storage space to the second storage data according to a specific time granularity;
[0113] 808. In response to detecting an access record of the first stored data in the second storage space, or the access frequency of the first stored data in the second storage space being higher than a third preset threshold, confirming whether the first storage space is occupied;
[0114] 809. When the first storage space is not occupied, migrate the first stored data back to the first storage space.
[0115] The detailed description of each step in this embodiment can be found in the above-mentioned embodiment and will not be repeated here.
[0116] It can be seen that in the embodiment of the present application, the access frequency information of the data stored in the multi-level storage space in the cluster is obtained; in response to the access frequency information of the first storage data in the first storage space meeting the preset migration condition, the first storage data is migrated from the first storage space to the second storage space, wherein the unit billing of the level to which the second storage space belongs is lower than the unit billing of the level to which the first storage space belongs. It can be seen that the solution provided by the present invention can improve the effective utilization rate of storage resources and save storage costs for users.
[0117] See also Fig. 9 , Fig. 9 A schematic diagram of a cluster resource management method provided in an embodiment of the present application, the method comprising:
[0118] 901. Obtain a first storage space and data volume of first storage data;
[0119] 902. Query a preset mapping table based on the first storage space and the data volume to obtain a second storage space, wherein the preset mapping table includes a mapping relationship between a preset data volume range, a preset original storage space, and a preset target storage space;
[0120] 903. Obtain access frequency information of data stored in multi-level storage spaces in the cluster;
[0121] 904. Display a first page, wherein the first page includes a management mode selection control;
[0122] 905. Determine a management mode of the first storage data based on an operation of the management mode selection control by the user to which the first storage data belongs, wherein the management mode includes a trusteeship mode or a manual mode;
[0123] 906. In response to the access frequency information of the first storage data in the first storage space satisfying a preset migration condition, migrating the first storage data from the first storage space to the second storage space, wherein the unit billing of the level to which the second storage space belongs is lower than the unit billing of the level to which the first storage space belongs.
[0124] It can be seen that in the embodiment of the present application, the access frequency information of the data stored in the multi-level storage space in the cluster is obtained; in response to the access frequency information of the first storage data in the first storage space meeting the preset migration condition, the first storage data is migrated from the first storage space to the second storage space, wherein the unit billing of the level to which the second storage space belongs is lower than the unit billing of the level to which the first storage space belongs. It can be seen that the solution provided by the present invention can improve the effective utilization rate of storage resources and save storage costs for users.
[0125] See also Fig.10 , Fig.10 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application, as shown in the figure, includes a processor, a memory, a communication interface, and one or more programs, the programs are stored in the memory and are configured to be executed by the processor. The program includes instructions for executing the following steps:
[0126] Obtain access frequency information of data stored in multi-level storage spaces in the cluster;
[0127] In response to access frequency information of first storage data in a first storage space satisfying a preset migration condition, the first storage data is migrated from the first storage space to a second storage space, wherein a unit billing of a level to which the second storage space belongs is lower than a unit billing of a level to which the first storage space belongs.
[0128] In a possible example, before migrating the first stored data from the first storage space to the second storage space, the program includes instructions for performing the following steps:
[0129] Acquire the data volume of the first stored data;
[0130] The second storage space is determined from the multi-level storage space according to the data amount and the first storage space.
[0131] In a possible example, in determining the second storage space from the multi-level storage space according to the data amount and the first storage space, the program includes instructions for performing the following steps:
[0132] determining, according to the data amount, a degradation parameter of the first stored data;
[0133] Based on the degradation parameter and the first storage space, the second storage space is determined.
[0134] In a possible example, in determining the second storage space from the multi-level storage space according to the data amount and the first storage space, the program includes instructions for performing the following steps:
[0135] A preset mapping table is queried based on the data volume and the first storage space to obtain the second storage space, wherein the preset mapping table includes a mapping relationship between a preset data volume range, a preset original storage space and a preset target storage space.
[0136] In a possible example, the preset migration condition includes: the number of access times within a preset time period is lower than a first preset threshold, or the interval between the most recent access time and the current time exceeds a second preset threshold.
[0137] In one possible example, the multi-level storage space includes three copies of SSD storage space, erasure coded SSD storage space, three copies of mechanical hard disk storage space, erasure coded mechanical hard disk storage space, shallow compression mechanical hard disk storage space and deep compression mechanical hard disk storage space.
[0138] In a possible example, when the second storage space is the shallow compression mechanical hard disk storage space or the deep compression mechanical hard disk storage space, before migrating the first storage data from the first storage space to the second storage space, the program includes instructions for performing the following steps:
[0139] The first stored data is compressed and stored in the first storage space.
[0140] In a possible example, before migrating the first stored data from the first storage space to the second storage space, the program includes instructions for performing the following steps:
[0141] displaying a first page, wherein the first page includes a management mode selection control;
[0142] Based on an operation of the management mode selection control by a user to which the first storage data belongs, a management mode of the first storage data is determined, wherein the management mode includes a trusteeship mode or a manual mode.
[0143] In a possible example, before migrating the first stored data from the first storage space to the second storage space, the program includes instructions for performing the following steps:
[0144] A data migration request is sent to a user to which the first stored data belongs, wherein the data migration request includes information about the second storage space.
[0145] In a possible example, in the aspect of migrating the first stored data from the first storage space to the second storage space, the program includes instructions for executing the following steps:
[0146] In response to receiving a data migration instruction in response to the data migration request sent by a user to which the first stored data belongs, the first stored data is migrated from the first storage space to a second storage space.
[0147] In a possible example, after migrating the first stored data from the first storage space to the second storage space, the program includes instructions for performing the following steps:
[0148] The first storage space is allocated to the second storage data according to a specific time granularity.
[0149] In a possible example, after migrating the first stored data from the first storage space to the second storage space, the program includes instructions for performing the following steps:
[0150] In response to detecting an access record of the first stored data in the second storage space, or the access frequency of the first stored data in the second storage space being higher than a third preset threshold, confirming whether the first storage space is occupied;
[0151] When the first storage space is not occupied, the first stored data is migrated back to the first storage space.
[0152] The above mainly introduces the scheme of the embodiment of the present application from the perspective of the method execution process. It is understandable that, in order to realize the above functions, the electronic device includes a hardware structure and / or software module corresponding to the execution of each function. Those skilled in the art should easily realize that, in combination with the units and algorithm steps of each example described in the embodiment provided herein, the present application can be implemented in the form of hardware or a combination of hardware and computer software. Whether a function is executed in the form of hardware or computer software driving hardware depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to exceed the scope of the present application.
[0153] The embodiment of the present application can divide the electronic device into functional units according to the above method example. For example, each functional unit can be divided according to each function, or two or more functions can be integrated into one processing unit. The above integrated unit can be implemented in the form of hardware or in the form of software functional units. It should be noted that the division of units in the embodiment of the present application is schematic and is only a logical function division. There may be other division methods in actual implementation.
[0154] See also Fig.11 , Fig.11 A schematic diagram of the structure of a computer cluster provided in an embodiment of the present application, as shown in the figure, the computer cluster includes a cluster resource management device and a cluster resource storage device, wherein the cluster resource storage device includes a multi-level storage space, in the embodiment of the present application, the cluster resource management device is as follows Fig.12 The cluster resource management device shown, the cluster resource balancing device includes:
[0155] An acquisition unit 1201 is used to acquire access frequency information of data stored in a multi-level storage space in a cluster;
[0156] The migration unit 1202 is used to migrate the first storage data from the first storage space to the second storage space in response to the access frequency information of the first storage data in the first storage space satisfying a preset migration condition, wherein the unit billing of the level to which the second storage space belongs is lower than the unit billing of the level to which the first storage space belongs.
[0157] In a possible example, before migrating the first storage data from the first storage space to the second storage space, the acquisition unit 1201 is specifically used to: acquire the data volume of the first storage data; and determine the second storage space from the multi-level storage space based on the data volume and the first storage space.
[0158] In one possible example, in terms of determining the second storage space from the multi-level storage space based on the data volume and the first storage space, the acquisition unit 1201 is specifically used to: determine the degradation parameters of the first stored data based on the data volume; and determine the second storage space based on the degradation parameters and the first storage space.
[0159] In one possible example, in terms of determining the second storage space from the multi-level storage space based on the data volume and the first storage space, the acquisition unit 1201 is specifically used to: query a preset mapping table based on the data volume and the first storage space to obtain the second storage space, wherein the preset mapping table includes a preset data volume range, a mapping relationship between a preset original storage space and a preset target storage space.
[0160] In a possible example, the preset migration condition includes: the number of access times within a preset time period is lower than a first preset threshold, or the interval between the most recent access time and the current time exceeds a second preset threshold.
[0161] In one possible example, the multi-level storage space includes three copies of SSD storage space, erasure coded SSD storage space, three copies of mechanical hard disk storage space, erasure coded mechanical hard disk storage space, shallow compression mechanical hard disk storage space and deep compression mechanical hard disk storage space.
[0162] In a possible example, when the second storage space is the shallowly compressed mechanical hard disk storage space or the deeply compressed mechanical hard disk storage space, before migrating the first storage data from the first storage space to the second storage space, the migration unit 1202 is also used to: compress and store the first storage data in the first storage space.
[0163] In a possible example, before migrating the first storage data from the first storage space to the second storage space, the migration unit 1202 is also used to: display a first page, wherein the first page includes a management mode selection control; determine the management mode of the first storage data based on the operation of the management mode selection control by the user to whom the first storage data belongs, wherein the management mode includes a hosted mode or a manual mode.
[0164] In a possible example, before migrating the first stored data from the first storage space to the second storage space, the migration unit 1202 is further used to: send a data migration request to a user to which the first stored data belongs, wherein the data migration request includes information about the second storage space.
[0165] In one possible example, in terms of migrating the first stored data from the first storage space to the second storage space, the migration unit 1202 is specifically used to: in response to receiving a data migration instruction sent by a user to which the first stored data belongs in response to the data migration request, migrate the first stored data from the first storage space to the second storage space.
[0166] In a possible example, after migrating the first storage data from the first storage space to the second storage space, the migration unit 1202 is further configured to: allocate the first storage space to the second storage data according to a specific time granularity.
[0167] In a possible example, after migrating the first storage data from the first storage space to the second storage space, the migration unit 1202 is further used to: in response to detecting an access record of the first storage data in the second storage space, or the access frequency of the first storage data in the second storage space is higher than a third preset threshold, confirm whether the first storage space is occupied; and if the first storage space is not occupied, migrate the first storage data back to the first storage space.
[0168] It can be seen that in the embodiment of the present application, the access frequency information of the data stored in the multi-level storage space in the cluster is obtained; in response to the access frequency information of the first storage data in the first storage space meeting the preset migration condition, the first storage data is migrated from the first storage space to the second storage space, wherein the unit billing of the level to which the second storage space belongs is lower than the unit billing of the level to which the first storage space belongs. It can be seen that the solution provided by the present invention can improve the effective utilization rate of storage resources and save storage costs for users.
[0169] The embodiment of the present application further provides a computer-readable storage medium storing a computer program for electronic data exchange, wherein the computer program enables a computer to execute part or all of the steps of any cluster resource management method as described in the above method embodiments.
[0170] The embodiment of the present application also provides a computer program product, which includes a non-transitory computer-readable storage medium storing a computer program, and the computer program enables a computer to execute part or all of the steps of any cluster resource management method recorded in the above method embodiments.
[0171] It should be noted that, for the aforementioned method embodiments, for the sake of simplicity of description, they are all expressed as a series of action combinations, but those skilled in the art should be aware that the present application is not limited by the described order of actions, because according to the present application, certain steps can be performed in other orders or simultaneously. Secondly, those skilled in the art should also be aware that the embodiments described in the specification are all preferred embodiments, and the actions and modules involved are not necessarily required by the present application. In the above embodiments, the description of each embodiment has its own emphasis, and for the parts that are not described in detail in a certain embodiment, please refer to the relevant description of other embodiments.
[0172] As described above, the above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application is described in detail with reference to the above embodiments, a person of ordinary skill in the art should understand that the technical solutions recorded in the above embodiments can still be modified, or some of the technical features can be replaced by equivalents. However, these modifications or replacements do not make the essence of the corresponding technical solutions deviate from the scope of the technical solutions of the embodiments of the present application.
Claims
1. A cluster resource management method, characterized in that: The method comprises: Obtain access frequency information of data stored in multi-level storage spaces in the cluster; In response to the access frequency information of the first storage data in the first storage space satisfying the preset migration condition, the data volume of the first storage data is obtained; according to the data volume and the first storage space, a second storage space is determined from the multi-level storage space; the determining the second storage space from the multi-level storage space according to the data volume and the first storage space includes: querying a preset mapping table based on the data volume and the first storage space to obtain the second storage space, wherein the preset mapping table includes a mapping relationship between a preset data volume range, a preset original storage space and a preset target storage space; The first storage data is migrated from the first storage space to a second storage space, wherein a unit charge of a level to which the second storage space belongs is lower than a unit charge of a level to which the first storage space belongs.
2. The method according to claim 1, characterized in that: The determining the second storage space from the multi-level storage space according to the data amount and the first storage space includes: determining, according to the data amount, a degradation parameter of the first stored data; Based on the degradation parameter and the first storage space, the second storage space is determined.
3. The method according to claim 1 or 2, characterized in that: The preset migration conditions include: The number of visits within the preset time period is lower than the first preset threshold, or the interval between the most recent visit time and the current time exceeds the second preset threshold.
4. The method according to claim 1 or 2, characterized in that: The multi-level storage space includes three copies of solid-state hard disk storage space, erasure code solid-state hard disk storage space, three copies of mechanical hard disk storage space, erasure code mechanical hard disk storage space, shallow compression mechanical hard disk storage space and deep compression mechanical hard disk storage space.
5. The method according to claim 4, characterized in that In a case where the second storage space is the shallow compression mechanical hard disk storage space or the deep compression mechanical hard disk storage space, before migrating the first storage data from the first storage space to the second storage space, the method further includes: The first stored data is compressed and stored in the first storage space.
6. The method according to claim 1 or 2, characterized in that: Before migrating the first stored data from the first storage space to the second storage space, the method further includes: displaying a first page, wherein the first page includes a management mode selection control; Based on an operation of the management mode selection control by a user to which the first storage data belongs, a management mode of the first storage data is determined, wherein the management mode includes a trusteeship mode or a manual mode.
7. The method according to claim 1 or 2, characterized in that: Before migrating the first stored data from the first storage space to the second storage space, the method further includes: A data migration request is sent to a user to which the first stored data belongs, wherein the data migration request includes information about the second storage space.
8. The method according to claim 7, characterized in that The migrating the first stored data from the first storage space to the second storage space includes: In response to receiving a data migration instruction in response to the data migration request sent by a user to which the first stored data belongs, the first stored data is migrated from the first storage space to a second storage space.
9. The method according to claim 1 or 2, characterized in that: After migrating the first stored data from the first storage space to the second storage space, the method further includes: The first storage space is allocated to the second storage data according to a specific time granularity.
10. The method according to claim 1 or 2, characterized in that: After migrating the first stored data from the first storage space to the second storage space, the method further includes: In response to detecting an access record of the first stored data in the second storage space, or the access frequency of the first stored data in the second storage space being higher than a third preset threshold, confirming whether the first storage space is occupied; When the first storage space is not occupied, the first stored data is migrated back to the first storage space.
11. A cluster resource management device, characterized in that: include: An acquisition unit, used to acquire access frequency information of data stored in a multi-level storage space in a cluster; The acquisition unit is further configured to acquire the data volume of the first storage data in response to the access frequency information of the first storage data in the first storage space satisfying the preset migration condition; and determine the second storage space from the multi-level storage space according to the data volume and the first storage space; The acquisition unit is specifically used for: Based on the data volume and the first storage space, a preset mapping table is queried to obtain the second storage space, wherein the preset mapping table includes a mapping relationship between a preset data volume range, a preset original storage space and a preset target storage space; A migration unit is used to migrate the first storage data from the first storage space to a second storage space, wherein the unit billing of the level to which the second storage space belongs is lower than the unit billing of the level to which the first storage space belongs.
12. The device according to claim 11, characterized in that In the aspect of determining the second storage space from the multi-level storage space according to the data amount and the first storage space, the acquiring unit is specifically configured to: Determine a degradation parameter of the first storage data according to the data amount; and determine the second storage space based on the degradation parameter and the first storage space.
13. The device according to claim 11 or 12, characterized in that The preset migration conditions include: The number of visits within the preset time period is lower than the first preset threshold, or the interval between the most recent visit time and the current time exceeds the second preset threshold.
14. The device according to claim 11 or 12, characterized in that The multi-level storage space includes three copies of solid-state hard disk storage space, erasure code solid-state hard disk storage space, three copies of mechanical hard disk storage space, erasure code mechanical hard disk storage space, shallow compression mechanical hard disk storage space and deep compression mechanical hard disk storage space.
15. The device according to claim 14, characterized in that In a case where the second storage space is the shallow compression mechanical hard disk storage space or the deep compression mechanical hard disk storage space, before migrating the first stored data from the first storage space to the second storage space, the migration unit is further used to: The first stored data is compressed and stored in the first storage space.
16. The device according to claim 11 or 12, characterized in that Before migrating the first stored data from the first storage space to the second storage space, the migration unit is further used to: A first page is displayed, wherein the first page includes a management mode selection control; and a management mode of the first storage data is determined based on an operation of the management mode selection control by a user to which the first storage data belongs, wherein the management mode includes a hosting mode or a manual mode.
17. The device according to claim 11 or 12, characterized in that Before migrating the first stored data from the first storage space to the second storage space, the migration unit is further used to: A data migration request is sent to a user to which the first stored data belongs, wherein the data migration request includes information about the second storage space.
18. The device according to claim 17, characterized in that In the aspect of migrating the first stored data from the first storage space to the second storage space, the migration unit is specifically used for: In response to receiving a data migration instruction in response to the data migration request sent by a user to which the first stored data belongs, the first stored data is migrated from the first storage space to a second storage space.
19. The device according to claim 11 or 12, characterized in that After migrating the first stored data from the first storage space to the second storage space, the migration unit is further used to: The first storage space is allocated to the second storage data according to a specific time granularity.
20. The device according to claim 11 or 12, characterized in that After migrating the first stored data from the first storage space to the second storage space, the migration unit is further used to: In response to detecting an access record of the first stored data in the second storage space, or the access frequency of the first stored data in the second storage space being higher than a third preset threshold, confirming whether the first storage space is occupied; When the first storage space is not occupied, the first stored data is migrated back to the first storage space.
21. An electronic device, characterized in that: The method comprises a processor and a memory, wherein the memory is used to store a computer program, and the processor is used to call the computer program stored in the memory to execute instructions of the steps in the method according to any one of claims 1 to 10.
22. A computer-readable storage medium, characterized in that: Used to store a computer program, wherein the computer program enables a computer to execute the method according to any one of claims 1 to 10.
23. A computer cluster, characterized in that: It comprises a cluster resource management device and a cluster resource storage device, wherein the cluster resource storage device comprises a multi-level storage space, and the cluster resource management device is a cluster resource management apparatus as claimed in any one of claims 11-20.
Citation Information
Patent Citations
Method for processing data blocks, and data block storage equipment and system
CN102156738A
Method for realizing intelligent degradation of data cached in SSD (Solid State Disk) of storage system
CN103744623A
Method for improving data transfer efficiency under automatic data hierarchical storage frame
CN104133643A
Level-to-level data management method and device and electronic equipment
CN105183389A
Data migration method and device
CN105487823A
