Cloud computing resource preemption management method and device, equipment and storage medium
By using the method of pre-occupying record linked list and the previous record identification in cloud computing resource management, the repeated reading and writing problems during resource adjustment are solved, the traceability and systematicity of records are realized, and the difficulty of data management is reduced.
Patent Information
- Application Number
- CN202411563298.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-04
- Publication Date
- 2025-02-14
AI Technical Summary
When resource adjustments are made, existing cloud computing resource management solutions will lead to repeated reading and writing of resources and pre-occupy records, increasing the difficulty of data management and problem investigation, and ineffective traceability and summary of historical configuration records.
By saving each pre-occupy record in the target cloud host's pre-occupy record linked list and including the identification of the previous record in each record, the association and statistics of the record are realized, repeated reading and writing are avoided, and traceability of records is supported.
It reduces the burden of reading and writing data, realizes traceability of pre-occupy records, simplifies data management and problem investigation of cloud hosts, and improves the systematicity and orderliness of cloud computing resource pre-occupy management.
Smart Images

Figure CN119440844A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the field of cloud computing technology, and in particular to a method, device, equipment and storage medium for pre-occupancy management of cloud computing resources. Background Art
[0002] In the cloud computing resource management scenario, when the user adjusts the resources of the cloud host in the target server through the scheduling service, the scheduling service will first pre-occupy the target resources in the target server to prevent resource pre-occupancy. After the pre-occupancy is successful, the scheduling service will generate a new pre-occupancy record, and then the target server will adjust the target resources. After the adjustment is successful, the original pre-occupancy record will be replaced by the new pre-occupancy record. If the adjustment of the target resource fails (for example, hardware damage), the pre-occupied target resource needs to be rolled back, the pre-occupancy record needs to be deleted to release the resource, and a new pre-occupancy record needs to be generated to restore the target resource to the state before the pre-occupancy, to ensure alignment with the actual resource usage of the cloud host and avoid resource duplication.
[0003] Since each cloud host has only one current reservation record, each resource adjustment operation on the cloud host will query the current resources of the cloud host and perform related operations on the current reservation record of the cloud host to change the current reservation record to a new reservation record. This solution will repeatedly read and write the resources of the cloud host and one reservation record of the cloud host, increasing the data reading and writing burden, and it is impossible to trace the reservation record and summarize the historical configuration increase and decrease records of the cloud host, which greatly increases the difficulty of data management and problem troubleshooting of the cloud host. Summary of the invention
[0004] In order to solve the above technical problems, the present disclosure provides a method, apparatus, device and storage medium for pre-occupancy management of cloud computing resources.
[0005] A first aspect of the present disclosure provides a pre-occupancy management method for cloud computing resources, including:
[0006] In response to receiving a resource adjustment instruction for a target cloud host, obtaining a first pre-occupancy record corresponding to a current state of the target cloud host from a pre-occupancy record linked list corresponding to the target cloud host, the pre-occupancy record linked list including all pre-occupancy records corresponding to the target cloud host, each pre-occupancy record including a pre-occupancy resource of the pre-occupancy record in a target server to which the target cloud host belongs, a pre-occupancy record identifier corresponding to the pre-occupancy record, and a pre-occupancy record identifier corresponding to a previous pre-occupancy record;
[0007] Acquire a first pre-emption record identifier corresponding to the first pre-emption record from the first pre-emption record;
[0008] Determine the target resource in the target server to be adjusted by the resource adjustment instruction request;
[0009] Preoccupy the target resources in the target server, generate a second preoccupation record corresponding to the target cloud host, and save the second preoccupation record to the preoccupation record linked list corresponding to the target cloud host. The second preoccupation record includes the preoccupied target resource, the second preoccupation record identifier corresponding to the second preoccupation record, and the first preoccupation record identifier.
[0010] A second aspect of the present disclosure provides a pre-occupancy management device for cloud computing resources, including:
[0011] A first acquisition module is used for, in response to receiving a resource adjustment instruction for a target cloud host, acquiring a first pre-occupancy record corresponding to a current state of the target cloud host from a pre-occupancy record linked list corresponding to the target cloud host, wherein the pre-occupancy record linked list includes all pre-occupancy records corresponding to the target cloud host, and each pre-occupancy record includes a pre-occupancy resource of the pre-occupancy record in a target server to which the target cloud host belongs, a pre-occupancy record identifier corresponding to the pre-occupancy record, and a pre-occupancy record identifier corresponding to a previous pre-occupancy record;
[0012] A second acquisition module, configured to acquire a first pre-occupation record identifier corresponding to the first pre-occupation record from the first pre-occupation record;
[0013] A first determining module, used for determining a target resource in a target server to be adjusted by a resource adjustment instruction request;
[0014] The pre-occupancy module is used to pre-occupy the target resources in the target server, generate a second pre-occupancy record corresponding to the target cloud host, and save the second pre-occupancy record to the pre-occupancy record linked list corresponding to the target cloud host. The second pre-occupancy record includes the pre-occupied target resource, the second pre-occupancy record identifier corresponding to the second pre-occupancy record, and the first pre-occupancy record identifier.
[0015] A third aspect of the present disclosure provides a scheduling device, including a memory and a processor, wherein a computer program is stored in the memory, and when the computer program is executed by the processor, the pre-occupancy management method of cloud computing resources of the first aspect can be implemented.
[0016] A fourth aspect of the present disclosure provides a computer-readable storage medium, in which a computer program is stored. When the computer program is executed by a processor, the pre-occupancy management method of cloud computing resources of the first aspect can be implemented.
[0017] Compared with the prior art, the technical solution provided by the present invention has the following advantages:
[0018] The present disclosure obtains a first pre-occupancy record corresponding to a current state of the target cloud host from a pre-occupancy record linked list corresponding to the target cloud host in response to receiving a resource adjustment instruction for the target cloud host, the pre-occupancy record linked list including all pre-occupancy records corresponding to the target cloud host, each pre-occupancy record including the pre-occupancy resource of the pre-occupancy record in a target server to which the target cloud host belongs, a pre-occupancy record identifier corresponding to the pre-occupancy record, and a pre-occupancy record identifier corresponding to a previous pre-occupancy record; a second acquisition module is used to obtain a first pre-occupancy record identifier corresponding to the first pre-occupancy record from the first pre-occupancy record; determine a target resource in the target server requested to be adjusted by the resource adjustment instruction; pre-occupy the target resource in the target server, generate a second pre-occupancy record corresponding to the target cloud host, and save the second pre-occupancy record in the pre-occupancy record linked list corresponding to the target cloud host, the second pre-occupancy record including the pre-occupied target resource, a second pre-occupancy record identifier corresponding to the second pre-occupancy record, and the first pre-occupancy record identifier. Therefore, when the cloud computing resources of the cloud host are adjusted, each pre-occupancy record corresponding to the cloud host can be saved in the pre-occupancy record linked list corresponding to the cloud host, and by including the pre-occupancy record identifier corresponding to the previous pre-occupancy record in each pre-occupancy record, each pre-occupancy record can be associated in sequence, and the pre-occupancy records corresponding to the cloud host can be counted through the pre-occupancy record linked list corresponding to the cloud host. There is no need to repeatedly read and write the resources of the cloud host and the pre-occupancy records of the cloud host, which reduces the burden of data reading and writing, realizes the traceability of the pre-occupancy records, reduces the difficulty of data management and problem troubleshooting of the cloud host, and realizes the systematic and orderly pre-occupancy management of cloud computing resources. BRIEF DESCRIPTION OF THE DRAWINGS
[0019] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present disclosure and, together with the description, serve to explain the principles of the present disclosure.
[0020] In order to more clearly illustrate the embodiments of the present invention 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, for ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.
[0021] Figure 1 It is a flow chart of a pre-occupancy management method of cloud computing resources provided by an embodiment of the present disclosure;
[0022] Figure 2 is a flow chart of another pre-occupancy management method for cloud computing resources provided by an embodiment of the present disclosure;
[0023] Figure 3 is a flow chart of another pre-occupancy management method for cloud computing resources provided by an embodiment of the present disclosure;
[0024] Figure 4 It is a structural diagram of a pre-occupancy management device for cloud computing resources provided by an embodiment of the present disclosure;
[0025] Figure 5 It is a structural diagram of a scheduling device provided in an embodiment of the present disclosure. DETAILED DESCRIPTION
[0026] In order to more clearly understand the above-mentioned objectives, features and advantages of the present disclosure, the scheme of the present disclosure will be further described below. It should be noted that the embodiments of the present disclosure and the features in the embodiments can be combined with each other without conflict.
[0027] In the following description, many specific details are set forth to facilitate a full understanding of the present disclosure, but the present disclosure may also be implemented in other ways different from those described herein; it is obvious that the embodiments in the specification are only part of the embodiments of the present disclosure, rather than all of the embodiments.
[0028] It should be understood that the various steps described in the method embodiments of the present disclosure may be performed in different orders and / or in parallel. In addition, the method embodiments may include additional steps and / or omit the steps shown. The scope of the present disclosure is not limited in this respect.
[0029] It should be noted that, in this article, relational terms such as "first" and "second" are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the existence of other identical elements in the process, method, article or device including the elements.
[0030] It should be noted that the modifications of "one" and "plurality" mentioned in the present disclosure are illustrative rather than restrictive, and those skilled in the art should understand that unless otherwise clearly indicated in the context, it should be understood as "one or more".
[0031] The pre-occupancy management method of cloud computing resources provided by the embodiments of the present disclosure may be executed by a scheduling device, which may be understood as any device with processing and computing capabilities, in which a scheduling service program is installed, and may include but is not limited to electronic devices such as scheduling servers, smart phones, laptops, tablet computers (PADs), desktop computers, etc.
[0032] In order to better understand the inventive concept of the embodiments of the present disclosure, the technical solutions of the embodiments of the present disclosure are described below in conjunction with exemplary embodiments.
[0033] Figure 1 is a flow chart of a pre-occupancy management method for cloud computing resources provided by an embodiment of the present disclosure. The method can be executed by a scheduling device, which can be understood as any device with computing functions and processing capabilities, such as Figure 1 As shown, the pre-occupancy management method of cloud computing resources provided in this embodiment includes the following steps:
[0034] Step 110, in response to receiving a resource adjustment instruction for the target cloud host, obtaining a first pre-occupancy record corresponding to the current state of the target cloud host from the pre-occupancy record linked list corresponding to the target cloud host, the pre-occupancy record linked list including all pre-occupancy records corresponding to the target cloud host, each pre-occupancy record including the pre-occupancy resources of the pre-occupancy record in the target server to which the target cloud host belongs, the pre-occupancy record identifier corresponding to the pre-occupancy record, and the pre-occupancy record identifier corresponding to the previous pre-occupancy record.
[0035] In the disclosed embodiment, the scheduling device stores inventory information of all servers managed by the scheduling device, including total resources, used resources, and available resources of each server.
[0036] The target server is a server managed by the scheduling device, and a target cloud host is created in the target server.
[0037] The resource adjustment instruction for the target cloud host may be understood as an instruction for adjusting the configuration resources in the target cloud host. The configuration resources may include the type of processor, the number of processors, the size of storage space, and the like.
[0038] The resource adjustment instruction may include at least one of a resource upgrade instruction and a resource downgrade instruction.
[0039] Resource upgrade instructions can be understood as resource upgrade instructions, that is, instructions for increasing the configuration resources of the cloud host.
[0040] The resource downgrade instruction can be understood as a resource downgrade instruction, that is, an instruction to reduce the configuration resources of the cloud host.
[0041] A pre-occupancy record linked list corresponding to the target cloud host is pre-built in the scheduling device, and the pre-occupancy record linked list includes all pre-occupancy records corresponding to the target cloud host. Each pre-occupancy record may include the pre-occupancy resources of the pre-occupancy record in the target server to which the target cloud host belongs, the pre-occupancy record identifier corresponding to the pre-occupancy record, and the pre-occupancy record identifier corresponding to the previous pre-occupancy record of the pre-occupancy record.
[0042] The reserved resources may include data such as the size of the reserved storage space and the number of the reserved specific processors.
[0043] The pre-emption record identifier can be understood as an identifier that can uniquely identify the pre-emption record. Each pre-emption record corresponds to a pre-emption identifier, and the pre-emption record and the pre-emption identifier correspond one to one.
[0044] In the disclosed embodiment, a user may send a resource adjustment instruction to a target cloud host to a scheduling device through a client, and the scheduling device may, in response to receiving the resource adjustment instruction to the target cloud host, obtain a first pre-occupancy record corresponding to the current state of the target cloud host from a pre-occupancy record linked list corresponding to the target cloud host. It can be understood that the first pre-occupancy record is the latest pre-occupancy record in the pre-occupancy record linked list corresponding to the target cloud host.
[0045] Step 120: Obtain a first pre-emption record identifier corresponding to the first pre-emption record from the first pre-emption record.
[0046] In the embodiment of the present disclosure, the first pre-occupation record may include resources of the currently occupied target server, a first pre-occupation record identifier corresponding to the first pre-occupation record, and a pre-occupation record identifier corresponding to a pre-occupation record previous to the first pre-occupation record.
[0047] The scheduling device may obtain the first pre-occupation record identifier corresponding to the first pre-occupation record from the first pre-occupation record.
[0048] Step 130: Determine the target resource in the target server that the resource adjustment instruction requests to be adjusted.
[0049] In the embodiment of the present disclosure, the scheduling device may obtain, from the resource adjustment instruction, the target resource in the target server requested to be adjusted by the resource adjustment instruction.
[0050] In some embodiments, when the resource adjustment instruction is a resource upgrade instruction, the target resource is the resource in the target server that the resource upgrade instruction requests to upgrade. For example, the target resource may be an increased number of specific processors, an increased storage space size, etc.
[0051] In other embodiments, when the resource adjustment instruction is a resource downsizing instruction, the target resource is a resource in the target server that the resource downsizing instruction requests to downgrade. For example, the target resource may be a reduced number of specific processors, a reduced storage space size, etc.
[0052] Step 140, pre-occupy the target resources in the target server, generate a second pre-occupancy record corresponding to the target cloud host, and save the second pre-occupancy record to the pre-occupancy record linked list corresponding to the target cloud host. The second pre-occupancy record includes the pre-occupied target resource, the second pre-occupancy record identifier corresponding to the second pre-occupancy record, and the first pre-occupancy record identifier.
[0053] In the disclosed embodiment, after obtaining the first pre-occupancy record and the target resource corresponding to the current state of the target cloud host, the scheduling device can pre-occupy the target resource in the target server, generate a second pre-occupancy record corresponding to the target cloud host, and save the second pre-occupancy record to the pre-occupancy record linked list corresponding to the target cloud host. The second pre-occupancy record can include the pre-occupied target resource, the second pre-occupancy record identifier corresponding to the second pre-occupancy record, and the first pre-occupation record identifier. Thus, the second pre-occupancy record can be associated with the first pre-occupancy record through the first pre-occupancy record identifier.
[0054] Therefore, when the cloud computing resources of the cloud host are adjusted, each pre-occupancy record corresponding to the cloud host can be saved in the pre-occupancy record linked list corresponding to the cloud host, and by including the pre-occupancy record identifier corresponding to the previous pre-occupancy record in each pre-occupancy record, each pre-occupancy record can be associated in sequence, and the pre-occupancy records corresponding to the cloud host can be counted through the pre-occupancy record linked list corresponding to the cloud host. There is no need to repeatedly read and write the resources of the cloud host and the pre-occupancy records of the cloud host, which reduces the burden of data reading and writing, realizes the traceability of the pre-occupancy records, reduces the difficulty of data management and problem troubleshooting of the cloud host, and realizes the systematic and orderly pre-occupancy management of cloud computing resources.
[0055] Figure 2 is a flow chart of a pre-occupancy management method for cloud computing resources provided by an embodiment of the present disclosure. The method can be executed by a scheduling device, which can be understood as any device with computing functions and processing capabilities, such as Figure 2 As shown, the pre-occupancy management method of cloud computing resources provided in this embodiment includes the following steps:
[0056] Step 210, in response to receiving a resource adjustment instruction for the target cloud host, obtaining a first pre-occupancy record corresponding to the current state of the target cloud host from the pre-occupancy record linked list corresponding to the target cloud host, the pre-occupancy record linked list including all pre-occupancy records corresponding to the target cloud host, each pre-occupancy record including the pre-occupancy resources of the pre-occupancy record in the target server to which the target cloud host belongs, the pre-occupancy record identifier corresponding to the pre-occupancy record, and the pre-occupancy record identifier corresponding to the previous pre-occupancy record.
[0057] Step 220: Obtain a first pre-occupation record identifier corresponding to the first pre-occupation record from the first pre-occupation record.
[0058] Step 230: Determine the target resource in the target server that the resource adjustment instruction requests to be adjusted.
[0059] Step 240, pre-occupy the target resources in the target server, generate a second pre-occupancy record corresponding to the target cloud host, and save the second pre-occupancy record to the pre-occupancy record linked list corresponding to the target cloud host. The second pre-occupancy record includes the pre-occupied target resource, the second pre-occupancy record identifier corresponding to the second pre-occupancy record, and the first pre-occupancy record identifier.
[0060] Step 250: Send the resource adjustment instruction to the target server, so that the target server adjusts the target resources based on the resource adjustment instruction.
[0061] In the disclosed embodiment, after generating the second reservation record corresponding to the target cloud host, the scheduling device may send the resource adjustment instruction to the target server to which the target cloud host belongs, and the target server may adjust the target resource based on the resource adjustment instruction.
[0062] For example, when the resource adjustment instruction is a resource upgrade instruction, the target server may allocate the target resource to the target cloud host based on the resource upgrade instruction.
[0063] When the resource adjustment instruction is a resource downsizing instruction, the target server may delete the target resources in the target cloud host based on the resource downsizing instruction.
[0064] Step 260: Receive the adjustment result of the target resource by the target server.
[0065] In the disclosed embodiment, after the target server adjusts the target resource based on the resource adjustment instruction, it can generate an adjustment result for the target resource and send the adjustment result for the target resource to the scheduling device. The scheduling device can receive the adjustment result of the target resource by the target server.
[0066] Step 270: Adjust the status of the second pre-occupancy record according to the adjustment result.
[0067] In the disclosed embodiment, the scheduling device may adjust the state of the second pre-occupancy record according to the adjustment result of the target resource by the target server.
[0068] In some embodiments, when the adjustment result of the target server on the target resource is successful, the scheduling device may determine that the second pre-emption record is effective.
[0069] In other embodiments, when the adjustment result of the target server to the target resource fails, the scheduling device can roll back the second pre-occupancy record to the first pre-occupancy record based on the first pre-occupancy record identifier contained in the second pre-occupancy record, delete the second pre-occupancy record in the pre-occupancy record linked list, and adjust the target resource to the state corresponding to the first pre-occupancy record.
[0070] Specifically, in the related art, if the adjustment of the target resource fails (for example, hardware damage), the current pre-occupancy record needs to be deleted, and the current pre-occupancy record and the pre-occupied target resource need to be rolled back. When the pre-occupied target resource is rolled back, the scheduling service needs to query the configuration of the current cloud host, and then regenerate a pre-occupancy record based on the configuration of the current cloud host. Therefore, each time a resource rollback is performed, it is necessary to query the configuration of the current cloud host, which increases the burden of data reading and writing, makes the operation cumbersome and error-prone, and greatly reduces the rollback efficiency.
[0071] In the embodiment of the present disclosure, when the adjustment result of the target server to the target resource fails, the scheduling device can roll back the second pre-occupancy record to the first pre-occupancy record based on the first pre-occupancy record identifier contained in the second pre-occupancy record, and delete the second pre-occupancy record in the pre-occupancy record linked list corresponding to the target cloud host, and adjust the target resource to the state corresponding to the first pre-occupancy record.
[0072] Therefore, when the adjustment of the target resource fails and the current pre-occupancy record and the pre-occupied target resource are rolled back, it is only necessary to determine the previous pre-occupancy record of the current pre-occupancy record according to the pre-occupancy record identifier corresponding to the previous pre-occupancy record contained in the current pre-occupancy record, and then adjust the target resource to the state corresponding to the previous pre-occupancy record. The pre-occupancy record and the target resource can be rolled back without querying the configuration of the current cloud host, which reduces the burden of data reading and writing, is simple to operate, and improves the rollback efficiency of the pre-occupancy record and the target resource. In addition, the pre-occupancy record corresponding to the cloud host is counted through the pre-occupancy record linked list corresponding to the cloud host, so as to achieve the traceability of the pre-occupancy record, reduce the difficulty of data management and problem troubleshooting of the cloud host, and realize the systematic and orderly pre-occupancy management of cloud computing resources.
[0073] Figure 3 is a flow chart of a pre-occupancy management method for cloud computing resources provided by an embodiment of the present disclosure. The method can be executed by a scheduling device, which can be understood as any device with computing functions and processing capabilities, such as Figure 3 As shown, the pre-occupancy management method of cloud computing resources provided in this embodiment includes the following steps:
[0074] Step 310, in response to receiving a resource adjustment instruction for the target cloud host, obtaining a first pre-occupancy record corresponding to the current state of the target cloud host from the pre-occupancy record linked list corresponding to the target cloud host, the pre-occupancy record linked list including all pre-occupancy records corresponding to the target cloud host, the pre-occupancy records in the pre-occupancy record linked list being arranged in chronological order based on the generation time of the pre-occupancy records, each pre-occupancy record including the pre-occupancy resources of the pre-occupancy record in the target server to which the target cloud host belongs, the pre-occupancy record identifier corresponding to the pre-occupancy record, and the pre-occupancy record identifier corresponding to the previous pre-occupancy record.
[0075] In the disclosed embodiment, the pre-occupancy record linked list corresponding to the target cloud host includes all pre-occupancy records corresponding to the target cloud host, each pre-occupancy record includes the pre-occupancy resource of the pre-occupancy record in the target server to which the target cloud host belongs, the pre-occupancy record identifier corresponding to the pre-occupancy record, and the pre-occupancy record identifier corresponding to the previous pre-occupancy record, and each pre-occupancy record in the pre-occupancy record linked list is arranged based on the chronological order of the generation time of the pre-occupancy record. For example, the generation time of the pre-occupancy record may be included in the pre-occupancy record identifier corresponding to the pre-occupancy record, and the scheduling device may obtain the generation time of the pre-occupancy record from the pre-occupancy record identifier corresponding to each pre-occupancy record corresponding to the target cloud host, sort all the pre-occupancy records corresponding to the target cloud host based on the chronological order of the generation time of each pre-occupancy record, and construct the pre-occupancy record linked list corresponding to the target cloud host.
[0076] In response to receiving the resource adjustment instruction for the target cloud host, the scheduling device can obtain the first pre-occupancy record corresponding to the current state of the target cloud host from the pre-occupancy record chain table corresponding to the target cloud host. It can be understood that the first pre-occupancy record is the latest pre-occupancy record in the pre-occupancy record chain table corresponding to the target cloud host.
[0077] Step 320: Obtain a first pre-occupation record identifier corresponding to the first pre-occupation record from the first pre-occupation record.
[0078] Step 330: Determine the target resource in the target server requested to be adjusted by the resource adjustment instruction.
[0079] Step 340: pre-occupy the target resource in the target server and generate a second pre-occupancy record corresponding to the target cloud host. The second pre-occupancy record includes the pre-occupied target resource, a second pre-occupancy record identifier corresponding to the second pre-occupancy record, and the first pre-occupancy record identifier.
[0080] Step 350: Obtain the generation time of the second reservation record.
[0081] In the embodiment of the present disclosure, the scheduling device may obtain the generation time of the second pre-emption record from the second pre-emption record identifier.
[0082] Step 360: based on the generation time of the second pre-occupancy record, save the second pre-occupancy record to the pre-occupancy record linked list corresponding to the target cloud host, wherein the second pre-occupancy record in the pre-occupancy record linked list is located after the first pre-occupancy record.
[0083] In the disclosed embodiment, the scheduling device may save the second pre-occupancy record to the pre-occupancy record linked list corresponding to the target cloud host based on the generation time of the second pre-occupancy record, wherein the second pre-occupancy record in the pre-occupancy record linked list is located after the first pre-occupancy record.
[0084] Therefore, each pre-occupancy record corresponding to the target cloud host can be sorted in the order of the generation time of each pre-occupancy record corresponding to the target cloud host, and the pre-occupancy records corresponding to the cloud host can be orderly counted through the pre-occupancy record linked list corresponding to the cloud host. There is no need to repeatedly read and write the resources of the cloud host and the pre-occupancy records of the cloud host, which reduces the burden of data reading and writing, realizes the traceability of the pre-occupancy records, reduces the difficulty of data management and problem troubleshooting of the cloud host, and further realizes the systematic and orderly pre-occupancy management of cloud computing resources.
[0085] In some embodiments of the present disclosure, the scheduling device can obtain the occupied resources of each pre-occupancy record from multiple pre-occupancy records contained in the pre-occupancy record linked list corresponding to the target cloud host; sort the pre-occupied resources according to the arrangement order of each pre-occupancy record in the pre-occupancy record linked list to obtain the resource demand trend of the target cloud host.
[0086] The resource demand trend can be expressed in the form of a bar chart, a trend chart, etc.
[0087] In other embodiments of the present disclosure, after obtaining the resource demand trend of the target cloud host, the scheduling device can predict the target resource demand of the target cloud host in a future preset time period based on the resource demand trend of the target cloud host, and control the target server to reserve resources corresponding to the target resource demand for the target cloud host in the preset time period.
[0088] The future preset time period can be set as needed, such as the next week, and is not limited here.
[0089] For example, based on the resource demand trend of the target cloud host, it is predicted that the target resource demand of the target cloud host in the future preset period is 1T of storage space. The scheduling device can control the target server to reserve 1T of storage space for the target cloud host in the preset period.
[0090] Therefore, the resource adjustment process of the cloud host can be managed and analyzed through a clear pre-occupancy record list, so as to prepare resources for the subsequent resource configuration adjustment of the cloud host and improve the success rate of cloud host resource configuration and adjustment.
[0091] Figure 41 is a schematic diagram of the structure of a pre-occupancy management device for cloud computing resources provided by an embodiment of the present disclosure. The device can be understood as the above-mentioned scheduling device or a part of the functional modules in the above-mentioned scheduling device. Figure 4 As shown, the cloud computing resource pre-occupancy management device 400 includes:
[0092] A first acquisition module 410 is configured to, in response to receiving a resource adjustment instruction for a target cloud host, acquire a first pre-occupancy record corresponding to a current state of the target cloud host from a pre-occupancy record linked list corresponding to the target cloud host, wherein the pre-occupancy record linked list includes all pre-occupancy records corresponding to the target cloud host, and each pre-occupancy record includes a pre-occupancy resource of the pre-occupancy record in a target server to which the target cloud host belongs, a pre-occupancy record identifier corresponding to the pre-occupancy record, and a pre-occupancy record identifier corresponding to a previous pre-occupancy record;
[0093] The second acquisition module 420 is used to acquire a first pre-occupation record identifier corresponding to the first pre-occupation record from the first pre-occupation record;
[0094] A first determining module 430 is used to determine a target resource in a target server to be adjusted by a resource adjustment instruction request;
[0095] The pre-occupancy module 440 is used to pre-occupy the target resources in the target server, generate a second pre-occupancy record corresponding to the target cloud host, and save the second pre-occupancy record to the pre-occupancy record linked list corresponding to the target cloud host. The second pre-occupancy record includes the pre-occupied target resources, the second pre-occupancy record identifier corresponding to the second pre-occupancy record, and the first pre-occupancy record identifier.
[0096] Optionally, the cloud computing resource pre-occupancy management device includes:
[0097] A sending module, used for sending the resource adjustment instruction to the target server, so that the target server adjusts the target resource based on the resource adjustment instruction;
[0098] A receiving module, used for receiving the adjustment result of the target server on the target resource;
[0099] An adjustment module is used to adjust the state of the second pre-occupancy record according to the adjustment result.
[0100] Optionally, the adjustment module includes:
[0101] A determination submodule, used for determining that the second pre-occupancy record takes effect when the adjustment result is successful;
[0102] The rollback submodule is used to roll back the second pre-occupancy record to the first pre-occupancy record based on the first pre-occupancy record identifier contained in the second pre-occupancy record when the adjustment result is failure, and delete the second pre-occupancy record in the pre-occupancy record linked list to adjust the target resource to the state corresponding to the first pre-occupancy record.
[0103] Optionally, the resource adjustment instruction includes at least one of a resource upgrade instruction and a resource downgrade instruction.
[0104] Optionally, the pre-occupancy records in the pre-occupancy record chain list are arranged in chronological order based on the generation time of the pre-occupancy records;
[0105] The above-mentioned pre-emption module includes:
[0106] An acquisition submodule, used for acquiring the generation time of the second pre-occupancy record;
[0107] The saving submodule is used to save the second pre-occupancy record to the pre-occupancy record linked list corresponding to the target cloud host based on the generation time of the second pre-occupancy record, and the second pre-occupancy record in the pre-occupancy record linked list is located after the first pre-occupancy record.
[0108] Optionally, the cloud computing resource pre-occupancy management device includes:
[0109] A third acquisition module is used to acquire the occupied resources of each of the multiple occupied records contained in the occupied record linked list corresponding to the target cloud host;
[0110] The sorting module is used to sort the reserved resources according to the arrangement order of the reserved records in the reserved record chain table to obtain the resource demand trend of the target cloud host.
[0111] Optionally, the cloud computing resource pre-occupancy management device includes:
[0112] A prediction module, used to predict the target resource demand of the target cloud host in a preset future period based on the resource demand trend of the target cloud host;
[0113] The control module is used to control the target server to reserve resources corresponding to the target resource demand for the target cloud host during a preset period of time.
[0114] The pre-occupancy management device for cloud computing resources provided in the embodiments of the present disclosure can implement the method of any of the above embodiments, and its execution method and beneficial effects are similar, which will not be repeated here.
[0115] The embodiments of the present disclosure also provide a scheduling device, which includes a processor and a memory, wherein a computer program is stored in the memory, and when the computer program is executed by the processor, the method of any of the above embodiments can be implemented, and its execution method and beneficial effects are similar, which will not be repeated here.
[0116] The scheduling device in the embodiments of the present disclosure may be understood as any device with processing and computing capabilities, and the device may include but is not limited to electronic devices such as scheduling servers, smart phones, laptops, tablet computers (PADs), desktop computers, etc.
[0117] Figure 5 is a schematic diagram of a scheduling device provided by an embodiment of the present disclosure, such as Figure 5 As shown, the scheduling device 500 may include a processor 510 and a memory 520, wherein a computer program 521 is stored in the memory 520. When the computer program 521 is executed by the processor 510, the method provided by any of the above embodiments can be implemented. The execution method and beneficial effects are similar and will not be repeated here.
[0118] Of course, to simplify, Figure 5 Only some of the components related to the present invention in the scheduling device 500 are shown, and components such as a bus, an input / output interface, an input device, and an output device are omitted. In addition, according to specific application conditions, the scheduling device 500 may also include any other appropriate components.
[0119] An embodiment of the present disclosure provides a computer-readable storage medium, in which a computer program is stored. When the computer program is executed by a processor, the method of any of the above embodiments can be implemented. The execution method and beneficial effects are similar and will not be repeated here.
[0120] The above-mentioned computer readable storage medium can adopt any combination of one or more readable media. The readable medium can be a readable signal medium or a readable storage medium. The readable storage medium can include, for example, but is not limited to, a system, device or device of electricity, magnetism, light, electromagnetic, infrared, or semiconductor, or any combination of the above. More specific examples (non-exhaustive list) of readable storage media include: an electrical connection with one or more wires, a portable disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above.
[0121] The computer program may be written in any combination of one or more programming languages to write program codes for performing the operations of the disclosed embodiments, including object-oriented programming languages such as Java, C++, etc., and conventional procedural programming languages such as "C" or similar programming languages. The program code may be executed entirely on the user scheduling device, partially on the user device, as a separate software package, partially on the user scheduling device and partially on the remote scheduling device, or entirely on the remote scheduling device or server.
[0122] The above description is only a preferred embodiment of the present disclosure and an explanation of the technical principles used. Those skilled in the art should understand that the scope of disclosure involved in the present disclosure is not limited to the technical solutions formed by a specific combination of the above technical features, but should also cover other technical solutions formed by any combination of the above technical features or their equivalent features without departing from the above disclosed concept. For example, the above features are replaced with the technical features with similar functions disclosed in the present disclosure (but not limited to) by each other to form a technical solution.
[0123] In addition, although each operation is described in a specific order, this should not be understood as requiring these operations to be performed in the specific order shown or in a sequential order. Under certain circumstances, multitasking and parallel processing may be advantageous. Similarly, although some specific implementation details are included in the above discussion, these should not be interpreted as limiting the scope of the present disclosure. Some features described in the context of a separate embodiment can also be implemented in a single embodiment in combination. On the contrary, the various features described in the context of a single embodiment can also be implemented in multiple embodiments individually or in any suitable sub-combination mode.
[0124] The above description is only a specific embodiment of the present disclosure, so that those skilled in the art can understand or implement the present disclosure. Various modifications to these embodiments will be apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present disclosure. Therefore, the present disclosure will not be limited to the embodiments described herein, but will conform to the widest scope consistent with the principles and novel features disclosed herein.
Claims
1. A method for pre-occupancy management of cloud computing resources, characterized in that: include: In response to receiving a resource adjustment instruction for a target cloud host, obtaining a first pre-occupancy record corresponding to a current state of the target cloud host from a pre-occupancy record linked list corresponding to the target cloud host, wherein the pre-occupancy record linked list includes all pre-occupancy records corresponding to the target cloud host, and each pre-occupancy record includes the pre-occupancy resource of the pre-occupancy record in a target server to which the target cloud host belongs, a pre-occupancy record identifier corresponding to the pre-occupancy record, and a pre-occupancy record identifier corresponding to a pre-occupancy record previous to the pre-occupancy record; Acquire a first pre-emption record identifier corresponding to the first pre-emption record from the first pre-emption record; Determine a target resource in the target server that is requested to be adjusted by the resource adjustment instruction; Preoccupy the target resource in the target server, generate a second preoccupation record corresponding to the target cloud host, and save the second preoccupation record to the preoccupation record linked list corresponding to the target cloud host, wherein the second preoccupation record includes the preoccupied target resource, a second preoccupation record identifier corresponding to the second preoccupation record, and the first preoccupation record identifier.
2. The method according to claim 1, characterized in that After the second pre-occupancy record is saved in the pre-occupancy record linked list corresponding to the target cloud host, the method further includes: Sending the resource adjustment instruction to the target server, so that the target server adjusts the target resource based on the resource adjustment instruction; receiving an adjustment result of the target resource by the target server; According to the adjustment result, the state of the second pre-occupancy record is adjusted.
3. The method according to claim 2, characterized in that The adjusting the state of the second pre-occupancy record according to the adjustment result includes: When the adjustment result is successful, determining that the second pre-occupancy record is effective; When the adjustment result is failure, based on the first pre-occupancy record identifier contained in the second pre-occupancy record, the second pre-occupancy record is rolled back to the first pre-occupancy record, and the second pre-occupancy record in the pre-occupancy record linked list is deleted, and the target resource is adjusted to the state corresponding to the first pre-occupancy record.
4. The method according to claim 1, characterized in that: The resource adjustment instruction includes at least one of a resource upgrade instruction and a resource downgrade instruction.
5. The method according to claim 1, characterized in that The pre-occupancy records in the pre-occupancy record chain table are arranged in a chronological order based on the generation time of the pre-occupancy records; The step of saving the second pre-occupancy record to a pre-occupancy record linked list corresponding to the target cloud host includes: Obtaining the generation time of the second reservation record; Based on the generation time of the second pre-occupancy record, the second pre-occupancy record is saved in a pre-occupancy record linked list corresponding to the target cloud host, wherein the second pre-occupancy record in the pre-occupancy record linked list is located after the first pre-occupancy record.
6. The method according to claim 1, characterized in that The method further comprises: Acquire the occupied resources of each of the occupied records from the plurality of occupied records included in the occupied record linked list corresponding to the target cloud host; According to the arrangement order of each of the pre-occupied records in the pre-occupied record linked list, the pre-occupied resources are sorted to obtain the resource demand trend of the target cloud host.
7. The method according to claim 6, characterized in that After obtaining the resource demand trend of the target cloud host, the method further includes: Based on the resource demand trend of the target cloud host, predict the target resource demand of the target cloud host in a future preset period of time; The target server is controlled to reserve resources corresponding to the target resource demand for the target cloud host during the preset time period.
8. A cloud computing resource pre-occupancy management device, characterized in that: include: A first acquisition module is configured to, in response to receiving a resource adjustment instruction for a target cloud host, acquire a first pre-occupancy record corresponding to a current state of the target cloud host from a pre-occupancy record linked list corresponding to the target cloud host, wherein the pre-occupancy record linked list includes all pre-occupancy records corresponding to the target cloud host, and each of the pre-occupancy records includes the pre-occupancy resource of the pre-occupancy record in a target server to which the target cloud host belongs, a pre-occupancy record identifier corresponding to the pre-occupancy record, and a pre-occupancy record identifier corresponding to a previous pre-occupancy record of the pre-occupancy record; A second acquisition module, configured to acquire a first pre-occupation record identifier corresponding to the first pre-occupation record from the first pre-occupation record; A first determining module, configured to determine a target resource in the target server to be adjusted by the resource adjustment instruction request; A pre-occupancy module is used to pre-occupy the target resource in the target server, generate a second pre-occupancy record corresponding to the target cloud host, and save the second pre-occupancy record to the pre-occupancy record linked list corresponding to the target cloud host, wherein the second pre-occupancy record includes the pre-occupied target resource, a second pre-occupancy record identifier corresponding to the second pre-occupancy record, and the first pre-occupation record identifier.
9. A scheduling device, characterized in that: include: A memory and a processor, wherein a computer program is stored in the memory, and when the computer program is executed by the processor, the pre-occupancy management method of cloud computing resources as described in any one of claims 1 to 7 is implemented.
10. A computer-readable storage medium, characterized in that: The storage medium stores a computer program, and when the computer program is executed by a processor, the pre-occupancy management method for cloud computing resources according to any one of claims 1 to 7 is implemented.