CN115118731A - Cloud resource management method and device, storage medium and electronic equipment - Google Patents
Cloud resource management method and device, storage medium and electronic equipment Download PDFInfo
- Publication number
- CN115118731A CN115118731A CN202210724906.2A CN202210724906A CN115118731A CN 115118731 A CN115118731 A CN 115118731A CN 202210724906 A CN202210724906 A CN 202210724906A CN 115118731 A CN115118731 A CN 115118731A
- Authority
- CN
- China
- Prior art keywords
- user
- cloud
- resource
- cloud resource
- resources
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Granted
Links
- 238000007726 management method Methods 0.000 title claims abstract description 36
- 238000000034 method Methods 0.000 claims abstract description 49
- 238000011156 evaluation Methods 0.000 claims abstract description 27
- 238000012544 monitoring process Methods 0.000 claims abstract description 14
- 238000011084 recovery Methods 0.000 claims description 28
- 238000004064 recycling Methods 0.000 claims description 16
- 238000012545 processing Methods 0.000 claims description 5
- 238000013468 resource allocation Methods 0.000 claims description 5
- 238000004364 calculation method Methods 0.000 claims description 3
- 239000002699 waste material Substances 0.000 abstract description 6
- 230000008569 process Effects 0.000 description 12
- 230000008859 change Effects 0.000 description 6
- 238000010586 diagram Methods 0.000 description 4
- 238000013210 evaluation model Methods 0.000 description 4
- 230000009471 action Effects 0.000 description 3
- 230000006870 function Effects 0.000 description 2
- 238000005457 optimization Methods 0.000 description 2
- 230000004044 response Effects 0.000 description 2
- 238000004458 analytical method Methods 0.000 description 1
- 238000012550 audit Methods 0.000 description 1
- 230000009286 beneficial effect Effects 0.000 description 1
- 238000005516 engineering process Methods 0.000 description 1
- 238000011990 functional testing Methods 0.000 description 1
- 230000007774 longterm Effects 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
- 230000000737 periodic effect Effects 0.000 description 1
- 238000013439 planning Methods 0.000 description 1
- 230000000750 progressive effect Effects 0.000 description 1
Images
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
- H04L67/10—Protocols in which an application is distributed across nodes in the network
- H04L67/1001—Protocols in which an application is distributed across nodes in the network for accessing one among a plurality of replicated servers
- H04L67/1004—Server selection for load balancing
- H04L67/1023—Server selection for load balancing based on a hash applied to IP addresses or costs
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Management, Administration, Business Operations System, And Electronic Commerce (AREA)
Abstract
The invention provides a cloud resource management method and device, a storage medium and electronic equipment, wherein the method comprises the following steps: receiving a cloud resource request of a user, wherein the cloud resource request is used for requesting to allocate cloud resources; responding to the cloud resource request, and distributing the cloud resources corresponding to the cloud resource request to the user under the condition that the user meets preset distribution conditions; monitoring the use state information of the cloud resources; calculating the cost loss of the user according to the use state information of the cloud resources, and determining the use score of the user according to the cost loss of the user; generating a cloud resource use evaluation result according to the cost loss and the use score of the user, and outputting the cloud resource use evaluation result; the cloud resource usage assessment result is used for indicating that the user optimizes the resource usage. By applying the method provided by the embodiment of the invention, the utilization rate of the cloud resources can be provided, and the vacancy and waste of the cloud resources are avoided.
Description
Technical Field
The invention relates to the technical field of data processing, in particular to a cloud resource management method and device, a storage medium and electronic equipment.
Background
In recent years, with the continuous maturity of cloud computing technology and the expansion of cloud market scale, the threshold of using cloud resources by users is greatly reduced. When a user uses resources, in order to ensure that the resource requirements of long-term planning are met and the resource usage under the condition of peak traffic is met, the user often applies for the resources in excess, so that the vacancy and the waste of cloud resources are easily caused.
Disclosure of Invention
The technical problem to be solved by the invention is to provide a cloud resource management method, which can provide the utilization rate of cloud resources and avoid the vacancy and waste of the cloud resources.
The invention also provides a cloud resource management device used for ensuring the realization and application of the method in practice.
A cloud resource management method, comprising:
receiving a cloud resource request of a user, wherein the cloud resource request is used for requesting to allocate cloud resources;
responding to the cloud resource request, and distributing the cloud resources corresponding to the cloud resource request to the user under the condition that the user meets preset distribution conditions;
monitoring the use state information of the cloud resource;
calculating the cost loss of the user according to the use state information of the cloud resources, and determining the use score of the user according to the cost loss of the user;
generating a cloud resource use evaluation result according to the cost loss and the use score of the user, and outputting the cloud resource use evaluation result; the cloud resource usage assessment result is used for indicating that the user optimizes the resource usage.
Optionally, the method for calculating the cost loss of the user according to the usage state information of the cloud resource includes:
determining a resource product unit price, a key index and an index unit price of the key index of the cloud resource;
calculating the use cost loss of the user according to the key index, the index unit price, a preset use rate threshold value and the resource use rate in the use state information;
calculating the cost loss of the user's quota according to the unused quota, the total quota and the unit price of the resource product contained in the use state information;
and calculating the cost loss of the user according to the use cost loss and the quota cost loss.
The method described above, optionally, the determining the usage score of the user according to the cost loss of the user includes:
determining the total cost of the key resources of the tenant;
and determining the usage score of the user according to the total cost of the tenant key resources and the cost loss of the user.
Optionally, the method further includes, after determining the usage score of the user according to the cost loss of the user:
receiving a capacity expansion request of the user; the capacity expansion request comprises capacity expansion parameters;
judging whether the cloud resources distributed to the user meet preset expansion conditions or not according to the expansion parameters, the cost loss and the quota cost loss;
under the condition that the cloud resources meet the capacity expansion conditions, capacity expansion is carried out on the cloud resources;
outputting prompt information under the condition that the cloud resources do not meet the capacity expansion condition; the prompt message is used for prompting the user to optimize the use of resources.
Optionally, the method further includes, after monitoring the usage state information of the cloud resource, that:
obtaining a recycling impact parameter from the usage status information of the cloud resource; the recycling impact parameter comprises at least one of idle time of unused resources and resource utilization rate;
judging whether the cloud resources meet preset recovery conditions or not according to the recovery influence parameters;
determining the recovery limit of the cloud resource under the condition that the cloud resource meets a preset recovery condition;
and recovering the cloud resources according to the recovery amount.
Optionally, in the method, the allocating the cloud resource corresponding to the cloud resource request to the user includes:
acquiring resource parameters of the cloud resource request;
and distributing the cloud resources corresponding to the cloud resource request to the user according to the resource parameters.
A cloud resource management apparatus, comprising:
the cloud resource allocation system comprises a receiving unit, a processing unit and a processing unit, wherein the receiving unit is used for receiving a cloud resource request of a user, and the cloud resource request is used for requesting to allocate cloud resources;
the allocation unit is used for responding to the cloud resource request, and allocating the cloud resources corresponding to the cloud resource request to the user under the condition that the user meets a preset allocation condition;
the monitoring unit is used for monitoring the use state information of the cloud resources;
the computing unit is used for computing the cost loss of the user according to the use state information of the cloud resources and determining the use score of the user according to the cost loss of the user;
the output unit is used for generating a cloud resource use evaluation result according to the cost loss and the use score of the user and outputting the cloud resource use evaluation result; the cloud resource usage assessment result is used for indicating that the user optimizes the resource usage.
The above apparatus, optionally, the calculating unit includes:
the first determining subunit is used for determining a resource product unit price, a key index and an index unit price of the key index of the cloud resource;
the first calculating subunit is configured to calculate, according to the key index, the index unit price, a preset usage rate threshold, and a resource usage rate in the usage state information, a usage cost loss of the user;
the second calculating subunit is used for calculating the cost loss of the quota of the user according to the unused quota, the total quota and the unit price of the resource product, which are contained in the using state information;
and the third calculating subunit is used for calculating the cost loss of the user according to the use cost loss and the quota cost loss.
A storage medium, comprising storage instructions, wherein the instructions, when executed, control a device on which the storage medium is located to perform the cloud resource management method as described above.
An electronic device comprising a memory, and one or more instructions, wherein the one or more instructions are stored in the memory and configured to be executed by the one or more processors to perform the cloud resource management method as described above.
Compared with the prior art, the invention has the following advantages:
the invention provides a cloud resource management method and device, a storage medium and electronic equipment, wherein the method comprises the following steps: receiving a cloud resource request of a user, wherein the cloud resource request is used for requesting to allocate cloud resources; responding to the cloud resource request, and distributing the cloud resources corresponding to the cloud resource request to the user under the condition that the user meets preset distribution conditions; monitoring the use state information of the cloud resources; calculating the cost loss of the user according to the use state information of the cloud resources, and determining the use score of the user according to the cost loss of the user; generating a cloud resource use evaluation result according to the cost loss and the use score of the user, and outputting the cloud resource use evaluation result; the cloud resource usage assessment result is used for indicating that the user optimizes the resource usage. By applying the method provided by the embodiment of the invention, the utilization rate of the cloud resources can be improved, and the vacancy and the waste of the cloud resources are avoided.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to the provided drawings without creative efforts.
Fig. 1 is a flowchart of a method of a cloud resource management method according to the present invention;
FIG. 2 is a flow chart of a process for calculating a cost loss for a user according to the present invention;
FIG. 3 is a flow chart of a process for determining a usage score for a user according to the present invention;
fig. 4 is a schematic structural diagram of a cloud resource management apparatus according to the present invention;
fig. 5 is a schematic structural diagram of an electronic device provided in the present invention;
fig. 6 is a flowchart of a cloud resource management process provided in the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
In this application, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other identical elements in a process, method, article, or apparatus that comprises the element.
An embodiment of the present invention provides a cloud resource management method, which may be applied to an electronic device, where the electronic device may be a device in a cloud resource management platform, and a flowchart of the method is shown in fig. 1, and specifically includes:
s101: receiving a cloud resource request of a user, wherein the cloud resource request is used for requesting to allocate cloud resources.
In this embodiment, the cloud resource request may be a request sent when there is a cloud resource demand by a user.
Optionally, the cloud resource may include at least one product of a cloud server, a cloud hard disk, a database, and a network bandwidth.
S102: responding to the cloud resource request, and distributing the cloud resources corresponding to the cloud resource request to the user under the condition that the user meets preset distribution conditions.
In this embodiment, in response to the cloud resource request, it may be determined whether the user satisfies a preset allocation condition.
Optionally, an achievable manner of determining whether the user satisfies the preset allocation condition may be: determining service demand information of a user, judging whether the service demand information is matched with the cloud resource quota requested by the cloud resource request, and determining that the user meets the allocation condition under the condition that the service demand information is matched with the cloud resource quota; and under the condition that the service demand information is not matched with the cloud resource limit, determining that the user does not meet the distribution condition.
Another achievable way of determining whether the user satisfies the preset allocation condition may be: determining historical cloud resources currently acquired by a user, determining whether the historical cloud resources can be optimally used, and if the historical cloud resources can be optimally used and the optimally used historical cloud resources can meet the service requirement information of the user, determining that the user does not meet the allocation condition; otherwise, determining that the user meets the allocation condition.
S103: and monitoring the use state information of the cloud resources.
In this embodiment, the usage state information of the cloud resource may include information such as a resource usage rate, a resource usage condition, and a cloud resource quota of the cloud resource, and the resource usage condition may include whether there is an unused resource, an idle duration of the unused resource, and an unused quota of the cloud resource.
S104: and calculating the cost loss of the user according to the use state information of the cloud resources, and determining the use score of the user according to the cost loss of the user.
In this embodiment, the cost loss of the user may include a usage cost loss and a credit cost loss; the use cost loss can be calculated according to the resource utilization rate, and the quota cost loss is calculated according to the unused quota of the cloud resource.
S105: generating a cloud resource use evaluation result according to the cost loss and the use score of the user, and outputting the cloud resource use evaluation result; the cloud resource usage assessment result is used for indicating that the user optimizes the resource usage.
In this embodiment, the cloud resource usage evaluation result may be displayed and output on a preset display interface, or the cloud resource usage evaluation result may be sent to a terminal of the user.
In some embodiments, one possible way to generate cloud resource usage assessment results is: after the cost loss of the user is calculated, the cost loss of the user can be compared with a preset loss threshold value to obtain a comparison result; after the usage score of the user is determined, the usage score of the user and the usage scores of other users are ranked to obtain the ranking of the user, and a cloud resource usage evaluation result can be generated according to the ranking of the user and the comparison result.
By applying the method provided by the embodiment of the invention, the cloud resource use evaluation result is generated according to the cost loss and the use score of the user, and the cloud resource use evaluation result is output to indicate the user to optimize the resource use. The cloud resource utilization rate can be provided, and the vacancy and waste of cloud resources are avoided.
In an embodiment provided by the present invention, based on the above scheme, optionally, the calculating a cost loss of the user according to the usage state information of the cloud resource, as shown in fig. 2, includes:
s201: and determining the resource product unit price, the key index and the index unit price of the key index of the cloud resource.
The cloud resource in this embodiment may include at least one product of a cloud server, a cloud hard disk, a database, and a network bandwidth, and the key index of the resource may be at least one of a CPU, a memory, a storage space, a data space, and the like.
S202: and calculating the use cost loss of the user according to the key index, the index unit price, a preset use rate threshold value and the resource use rate in the use state information.
In this embodiment, the usage threshold corresponding to the different cloud resources may be the same or different, and the usage threshold may be a preset required usage, for example, when the cloud resources are cloud servers CVMs, the usage threshold may be 20%; in the case that the cloud resource is a cloud hard disk CBS, the usage threshold may be 20%; in the case where the cloud resources are a database, the usage threshold may be 20%; where the cloud resources are network bandwidth, the usage threshold may be 25%.
Alternatively, one possible way to calculate the usage cost penalty is to:
I i =|R-Mi|*Ci*P1
wherein, I i The cost loss of the cloud resource product i is shown, R is a utilization rate threshold value, L can take a value of 20%, Mi is the resource utilization rate, Ci is a key index, and P1 is the index unit price.
Specifically, under the condition that the number of the cloud resources is multiple, the use cost losses of the products of the cloud resources can be summed up to obtain the total use cost loss of the cloud resources.
S203: and calculating the cost loss of the quota of the user according to the unused quota, the total quota and the unit price of the resource product contained in the using state information.
In this embodiment, the unused quota may be a quota of an unused resource in the cloud resource, that is, a quota of an idle resource.
Optionally, a feasible way to calculate the credit cost loss of the user is as follows:
K i =(C q -Q*T)*P2
wherein, K i Cost loss of quota for product i of cloud resources, C q Is unused quota, Q is total quota, T is maneuvering quota space ratio,t can be 10%, and P2 is the unit price of the resource product.
Specifically, under the condition that the number of the cloud resources is multiple, the cost losses of the quota of each product of the cloud resources can be summed to obtain the total quota cost loss of the cloud resources.
S204: and calculating the cost loss of the user according to the use cost loss and the quota cost loss.
In this embodiment, the cloud resource usage cost loss and the quota cost loss may be summed to obtain the cost loss of the user.
In an embodiment provided by the present invention, based on the above scheme, optionally, the determining the usage score of the user according to the cost loss of the user includes, as shown in fig. 3:
s301: and determining the total cost of the key resources of the tenant.
In this embodiment, the total cost of the tenant key resource, which is the total cost of the tenant key resource, may be determined from a preset cost information table, where the key resource refers to a preset type of resource.
S302: and determining the usage score of the user according to the total cost of the tenant key resources and the cost loss of the user.
In this embodiment, the usage score may characterize whether the resource optimization of the user is reasonable, and may be used to prompt the user to optimize the resource usage.
Optionally, a specific way of determining the usage score of the user is as follows:
wherein S is the usage score, L is the cost loss of the user, and F is the total cost of the key resources of the tenant.
In an embodiment provided by the present invention, based on the above scheme, optionally, after determining the usage score of the user according to the cost loss of the user, the method further includes:
receiving a capacity expansion request of the user, wherein the capacity expansion request comprises capacity expansion parameters;
judging whether the cloud resources distributed to the user meet preset capacity expansion conditions or not according to the capacity expansion parameters, the cost losses and the quota cost losses;
under the condition that the cloud resources meet the capacity expansion conditions, capacity expansion is carried out on the cloud resources;
outputting prompt information under the condition that the cloud resources do not meet the capacity expansion condition; the prompt message is used for prompting the user to optimize the use of resources.
In this embodiment, the capacity expansion request may include a capacity expansion parameter, and the capacity expansion parameter may include information of a product and a resource limit that the user requests capacity expansion.
Optionally, a feasible way of judging whether the cloud resources allocated to the user meet the capacity expansion condition according to the capacity expansion parameter, the cost loss and the quota cost loss is to compare the cost loss with the quota loss, prompt the user to optimize the resource configuration of the cloud resources when the cost loss is greater than the quota loss, judge whether the optimized resources are matched with the capacity expansion parameter after detecting that the user completes the resource configuration optimization of the cloud resources, and determine that the cloud resources do not meet the capacity expansion condition if the optimized resources are matched with the capacity expansion parameter; determining whether the unused resources and the unused quota of the cloud resources of the user meet the capacity expansion parameter under the condition that quota loss is greater than the cost loss; under the condition that the unused resources are matched with the unused quota which does not meet the capacity expansion parameter, determining that the cloud resources do not meet the capacity expansion condition; and under the condition that the unused resources and the unused quota do not meet the capacity expansion parameters, determining that the cloud resources meet the capacity expansion conditions.
Under the condition that the cloud resources meet the capacity expansion condition, determining a target capacity expansion parameter according to the capacity expansion parameter and the optimized resources, or determining the target capacity expansion parameter according to unused resources, unused quota and the capacity expansion parameter; and expanding the capacity of the cloud resources according to the determined target capacity expansion parameters.
Under the condition that the cloud resources do not meet the capacity expansion condition and the cost loss is greater than the limit loss, prompting the user to preferentially obtain the required resources from the unused resources; when the cloud resources do not meet the capacity expansion condition and the quota loss is greater than the cost loss, the user can be prompted to preferentially adjust the resource configuration of the cloud resources, and the resources recovered after adjustment are used to meet the resource change requirement.
In an embodiment provided by the present invention, based on the above scheme, optionally, after the monitoring the use state information of the cloud resource, the method further includes:
obtaining a recycling impact parameter from the usage status information of the cloud resource; the recycling impact parameter comprises at least one of idle time of unused resources and resource utilization rate;
judging whether the cloud resources meet preset recovery conditions or not according to the recovery influence parameters;
determining the recovery limit of the cloud resource under the condition that the cloud resource meets a preset recovery condition;
and recovering the cloud resources according to the recovery amount.
In this embodiment, when the idle duration of the unused resource is greater than a preset idle duration threshold or the resource utilization is less than a preset resource utilization threshold, it is determined that the cloud resource does not satisfy the recovery condition, otherwise, it is determined that the cloud resource satisfies the recovery condition.
In this embodiment, when the idle duration of the unused resource is greater than a preset idle duration threshold, determining a credit based on the unused resource; recovering the unused resource according to the recovery quota, wherein the unused resource is the total quota-used quota of the cloud resource allocated to the user; the recycling amount is a first recycling proportion preset for unused resources; the first recycling proportion can be 90%, and unused resources in the cloud resources are recycled according to the recycling amount.
In this embodiment, when the resource usage rate is lower than the preset usage rate threshold, the recycling amount is the total amount of the cloud resource and is a preset second recycling ratio, and the second recycling ratio may be 50%; and recovering the cloud resources according to the recovery limit.
By applying the method provided by the embodiment of the invention, the waste of cloud resources can be effectively avoided.
In an embodiment provided by the present invention, based on the above scheme, optionally, the allocating, to the user, a cloud resource corresponding to the cloud resource request includes:
acquiring resource parameters of the cloud resource request;
and distributing the cloud resources corresponding to the cloud resource request to the user according to the resource parameters.
In this embodiment, the resource parameters may include the requested product and the requested resource quota.
The method provided by the embodiment of the invention can be used for rapidly and accurately distributing the cloud resources to the user.
Corresponding to the method illustrated in fig. 1, an embodiment of the present invention further provides a cloud resource management apparatus, which is used for specifically implementing the method illustrated in fig. 1, where the cloud resource management apparatus provided in the embodiment of the present invention may be applied to an electronic device, and a schematic structural diagram of the cloud resource management apparatus is illustrated in fig. 4, and specifically includes:
a receiving unit 401, configured to receive a cloud resource request of a user, where the cloud resource request is used to request allocation of cloud resources;
an allocating unit 402, configured to, in response to the cloud resource request, allocate, to the user, a cloud resource corresponding to the cloud resource request when the user meets a preset allocation condition;
a monitoring unit 403, configured to monitor usage status information of the cloud resource;
a calculating unit 404, configured to calculate a cost loss of the user according to the usage state information of the cloud resource, and determine a usage score of the user according to the cost loss of the user;
an output unit 405, configured to generate a cloud resource usage evaluation result according to the cost loss and the usage score of the user, and output the cloud resource usage evaluation result; the cloud resource usage assessment result is used for indicating that the user optimizes the resource usage.
In an embodiment provided in the embodiment of the present invention, based on the above scheme, specifically, the calculating unit 404 includes:
the first determining subunit is used for determining a resource product unit price, a key index and an index unit price of the key index of the cloud resource;
the first calculating subunit is configured to calculate, according to the key index, the index unit price, a preset usage rate threshold, and a resource usage rate in the usage state information, a usage cost loss of the user;
the second calculating subunit is used for calculating the cost loss of the quota of the user according to the unused quota, the total quota and the unit price of the resource product, which are contained in the using state information;
and the third calculating subunit is used for calculating the cost loss of the user according to the use cost loss and the quota cost loss.
In an embodiment provided in the embodiment of the present invention, based on the above scheme, specifically, the calculating unit 404 includes:
the second determining subunit is used for determining the total cost of the key resources of the tenant;
and the third determining subunit is used for determining the usage score of the user according to the total cost of the tenant key resources and the cost loss of the user.
In an embodiment provided in the embodiment of the present invention, based on the above scheme, specifically, the cloud resource management apparatus further includes:
a first execution unit, configured to receive a capacity expansion request of the user; the capacity expansion request comprises capacity expansion parameters;
the first judgment unit is used for judging whether the cloud resources distributed to the user meet preset capacity expansion conditions or not according to the capacity expansion parameters, the cost loss and the quota cost loss;
the capacity expansion unit is used for expanding the capacity of the cloud resources under the condition that the cloud resources meet the capacity expansion condition;
the prompting unit is used for outputting prompting information under the condition that the cloud resources do not meet the capacity expansion condition; the prompt message is used for prompting the user to optimize the use of resources.
In an embodiment provided in the embodiment of the present invention, based on the above scheme, specifically, the cloud resource management apparatus further includes:
a second execution unit configured to obtain a recycling impact parameter from the usage state information of the cloud resource; the recycling impact parameter comprises at least one of idle time of unused resources and resource utilization rate;
the second judging unit is used for judging whether the cloud resources meet preset recovery conditions or not according to the recovery influence parameters;
the second determining unit is used for determining the recovery limit of the cloud resource under the condition that the cloud resource meets a preset recovery condition;
and the recovery unit is used for recovering the cloud resources according to the recovery limit.
In an embodiment provided in the embodiment of the present invention, based on the above scheme, specifically, the allocating unit 402 includes:
an obtaining subunit, configured to obtain a resource parameter of the cloud resource request;
and the allocation subunit is used for allocating the cloud resources corresponding to the cloud resource request to the user according to the resource parameters.
The specific principle and the execution process of each unit and each module in the cloud resource management device disclosed in the embodiment of the present invention are the same as those of the cloud resource management method disclosed in the embodiment of the present invention, and reference may be made to corresponding parts in the cloud resource management method provided in the embodiment of the present invention, which are not described herein again.
The embodiment of the invention also provides a storage medium, which comprises a stored instruction, wherein when the instruction runs, the device where the storage medium is located is controlled to execute the cloud resource management method.
An electronic device is provided in an embodiment of the present invention, and the structural diagram of the electronic device is shown in fig. 5, which specifically includes a memory 501 and one or more instructions 502, where the one or more instructions 502 are stored in the memory 501, and are configured to be executed by one or more processors 503 to perform the following operations according to the one or more instructions 502:
receiving a cloud resource request of a user, wherein the cloud resource request is used for requesting to allocate cloud resources;
responding to the cloud resource request, and distributing the cloud resources corresponding to the cloud resource request to the user under the condition that the user meets preset distribution conditions;
monitoring the use state information of the cloud resources;
calculating the cost loss of the user according to the use state information of the cloud resources, and determining the use score of the user according to the cost loss of the user;
generating a cloud resource use evaluation result according to the cost loss and the use score of the user, and outputting the cloud resource use evaluation result; the cloud resource usage assessment result is used for indicating that the user optimizes the resource usage.
In some embodiments, the cloud resource management method provided in the embodiments of the present invention may be applied to fine management of cloud resources of an enterprise, and performs management control from a full life cycle of the cloud resources to achieve maximum utilization of enterprise-level cloud platform resources, as shown in fig. 6, a flowchart of a cloud resource management process provided in the embodiments of the present invention specifically includes the following steps:
the method comprises the following steps: and applying for cloud resources.
The resource allocation method comprises the steps that the principle of 'allocation according to needs and elastic capacity expansion' is followed when the resources are allocated, so that a user is required to apply for the minimum configuration provided by a cloud platform when applying for the cloud resources, if the basis of providing a non-functional test report and the like according to the requirement of applying for larger configuration is required, the management personnel performs auditing, and the resources can be allocated after the auditing is passed.
Step two: cloud resource usage.
And designing a post-evaluation model aiming at the use condition of the tenant resources, so as to quantify the resource occupation and use condition and guide the platform to audit and manage the user resources.
The key product indicators of the post-evaluation model are shown in table 1:
TABLE 1
The post-evaluation model calculation method is as follows:
the cost loss I is calculated by the absolute value of the difference between the required utilization rate (20%) and the actual utilization rate Mi of the product instance, and the key index C of the product instance i And the sum of the multipliers of the index unit price P.
For example: service cost loss I of single cloud server cvm-i =|20%-Mi|*Ci*P。
The total use cost loss I ═ I of the user cvm +I cbs +I MySQL +I Redis +I Oracle +I net 。
The amount cost loss K is calculated in such a way that the amount C is not used in the account of the user q After 10% of the maneuvering quota space of the total quota Q is deducted, the product is multiplied by the unit price P of the product.
For example: quota cost loss K of cloud server product cvm =(C q-cvm -Q cvm *10%)*P。
The total cost loss K of the subscriber is K cvm +K cbs +K MySQL +K Redis +K Oracle +K net 。
The total cost loss L ═ I + K to the user.
The calculation mode of the post-user evaluation total score S is that the total cost loss L of the user is divided by the total cost F of the key resources of the tenants to obtain a proportion, 1 is used for subtracting the proportion, and then the proportion is multiplied by 100 to obtain the score of the tenants:
the model comprehensively evaluates the resource utilization condition of an evaluation user from two aspects of resource limit and resource utilization rate, and quantifies data by taking resource cost as a unified metering unit, so that the evaluation result is clearer. And visually displaying the excess application resources of the user and the low utilization rate. According to the two indexes, statistical reports of all users can be obtained, and the statistical reports can be used for restricting processes of resource application, change, recovery and the like of management users.
Step three: and (6) changing the cloud resources.
When a user applies for changes such as cloud resource expansion, a cloud platform side manager can master the current use situation of the cloud resources of the user by combining the statistical report in the step (2), and a related strategy is made for the user with lower score to check the change requirement:
the cost loss of the quota is high, resources are preferentially obtained from the resources allocated by the user, and the resources required by change are not additionally allocated.
The use cost loss is high, a user is preferentially urged to adjust the existing resource configuration to achieve a high utilization rate, and the resources recovered after adjustment can be used to meet the change requirement.
Step four: and (6) recovering cloud resources.
And combining the periodic post-evaluation work in the step two, organizing and urging the users with higher loss cost to perform resource recovery work:
recycling unused resources: unused within 45 days after the resource allocation, 90% of the unused resource (allocated resource-used resource) was recovered, and 10% of the mobile credit space remained.
Low recovery of resource utilization rate: if the utilization rate of each index of the resources is lower than 20%, the configuration is halved, and if the original configuration is the lowest configuration, the adjustment is not needed.
The embodiment of the invention has the following advantages: (1) the evaluation model specifies the standard and specification of resource use after use, and quantitatively counts and displays the use condition of the user resource, the model can respectively display the conditions of resource excess application and low use rate, and can also transversely compare and comprehensively master the overall conditions of all users to guide the enterprise to finely manage the cloud resource.
(2) In this embodiment, in resource application and change stages, user resource requirements are strictly controlled according to a policy, and allocated unused resources are timely recovered, which is beneficial to resource scheduling and allocation of the whole cloud platform.
(3) The method is characterized in that statistics and analysis are periodically carried out aiming at the phenomenon that resources used by a user are low in utilization rate, the user is supervised and urged to adjust resource allocation and recycle idle resources in time by using reports and ranks, the capability of flexibly adjusting the allocation in cloud computing is fully utilized, the resource utilization rate of the whole cloud platform is maximized, the cost of using the cloud resources by the user is effectively reduced, and the resource utilization efficiency is improved.
It should be noted that, in the present specification, the embodiments are all described in a progressive manner, each embodiment focuses on differences from other embodiments, and the same and similar parts among the embodiments may be referred to each other. For the device-like embodiment, since it is basically similar to the method embodiment, the description is simple, and for the relevant points, reference may be made to the partial description of the method embodiment.
Finally, it should also be noted that, herein, relational terms such as first and second, and the like may be used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other identical elements in the process, method, article, or apparatus that comprises the element.
For convenience of description, the above devices are described as being divided into various units by function, and are described separately. Of course, the functions of the units may be implemented in the same software and/or hardware or in a plurality of software and/or hardware when implementing the invention.
From the above description of the embodiments, it is clear to those skilled in the art that the present invention can be implemented by software plus necessary general hardware platform. Based on such understanding, the technical solutions of the present invention may be embodied in the form of a software product, which may be stored in a storage medium, such as ROM/RAM, magnetic disk, optical disk, etc., and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute the method according to the embodiments or some parts of the embodiments.
The cloud resource management method provided by the invention is described in detail above, and the principle and the implementation mode of the invention are explained by applying specific examples, and the description of the above examples is only used for helping to understand the method and the core idea of the invention; meanwhile, for a person skilled in the art, according to the idea of the present invention, there may be variations in the specific embodiments and the application scope, and in summary, the content of the present specification should not be construed as a limitation to the present invention.
Claims (10)
1. A cloud resource management method, comprising:
receiving a cloud resource request of a user, wherein the cloud resource request is used for requesting to allocate cloud resources;
responding to the cloud resource request, and distributing the cloud resources corresponding to the cloud resource request to the user under the condition that the user meets preset distribution conditions;
monitoring the use state information of the cloud resource;
calculating the cost loss of the user according to the use state information of the cloud resources, and determining the use score of the user according to the cost loss of the user;
generating a cloud resource use evaluation result according to the cost loss and the use score of the user, and outputting the cloud resource use evaluation result; the cloud resource usage assessment result is used for indicating that the user optimizes the resource usage.
2. The method according to claim 1, wherein the calculating the cost loss of the user according to the usage status information of the cloud resource comprises:
determining a resource product unit price, a key index and an index unit price of the key index of the cloud resource;
calculating the use cost loss of the user according to the key index, the index unit price, a preset use rate threshold value and the resource use rate in the use state information;
calculating the cost loss of the user's quota according to the unused quota, the total quota and the unit price of the resource product contained in the use state information;
and calculating the cost loss of the user according to the use cost loss and the quota cost loss.
3. The method of claim 1 or 2, wherein determining the usage score of the user based on the cost loss of the user comprises:
determining the total cost of the key resources of the tenant;
and determining the usage score of the user according to the total cost of the tenant key resources and the cost loss of the user.
4. The method of claim 2, wherein after determining the usage score for the user based on the cost loss for the user, further comprising:
receiving a capacity expansion request of the user; the capacity expansion request comprises capacity expansion parameters;
judging whether the cloud resources distributed to the user meet preset capacity expansion conditions or not according to the capacity expansion parameters, the cost loss and the quota cost loss;
under the condition that the cloud resources meet the capacity expansion conditions, capacity expansion is carried out on the cloud resources;
outputting prompt information under the condition that the cloud resources do not meet the capacity expansion condition; the prompt message is used for prompting the user to optimize the use of resources.
5. The method of claim 1, wherein after monitoring the usage status information of the cloud resource, further comprising:
obtaining a recycling impact parameter from the usage status information of the cloud resource; the recycling impact parameter comprises at least one of idle duration and resource utilization rate of unused resources;
judging whether the cloud resources meet preset recovery conditions or not according to the recovery influence parameters;
determining the recovery limit of the cloud resource under the condition that the cloud resource meets a preset recovery condition;
and recovering the cloud resources according to the recovery amount.
6. The method according to claim 1, wherein the allocating the cloud resource corresponding to the cloud resource request to the user comprises:
acquiring resource parameters of the cloud resource request;
and distributing the cloud resources corresponding to the cloud resource request for the user according to the resource parameters.
7. A cloud resource management apparatus, comprising:
the cloud resource allocation system comprises a receiving unit, a processing unit and a processing unit, wherein the receiving unit is used for receiving a cloud resource request of a user, and the cloud resource request is used for requesting to allocate cloud resources;
the allocation unit is used for responding to the cloud resource request, and allocating the cloud resources corresponding to the cloud resource request to the user under the condition that the user meets a preset allocation condition;
the monitoring unit is used for monitoring the use state information of the cloud resources;
the computing unit is used for computing the cost loss of the user according to the use state information of the cloud resources and determining the use score of the user according to the cost loss of the user;
the output unit is used for generating a cloud resource use evaluation result according to the cost loss and the use score of the user and outputting the cloud resource use evaluation result; the cloud resource usage assessment result is used for indicating that the user optimizes the resource usage.
8. The apparatus of claim 7, wherein the computing unit comprises:
the first determining subunit is used for determining a resource product unit price, a key index and an index unit price of the key index of the cloud resource;
the first calculating subunit is configured to calculate, according to the key index, the index unit price, a preset usage rate threshold, and a resource usage rate in the usage state information, a usage cost loss of the user;
the second calculating subunit is used for calculating the cost loss of the quota of the user according to the unused quota, the total quota and the unit price of the resource product, which are contained in the using state information;
and the third calculation subunit is used for calculating the cost loss of the user according to the use cost loss and the quota cost loss.
9. A storage medium, characterized in that the storage medium comprises a storage instruction, wherein when the instruction runs, a device on which the storage medium is located is controlled to execute the cloud resource management method according to any one of claims 1 to 6.
10. An electronic device comprising a memory, and one or more instructions, wherein the one or more instructions are stored in the memory and configured to be executed by the one or more processors to perform the cloud resource management method of any of claims 1-6.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202210724906.2A CN115118731B (en) | 2022-06-24 | 2022-06-24 | Cloud resource management method and device, storage medium and electronic equipment |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202210724906.2A CN115118731B (en) | 2022-06-24 | 2022-06-24 | Cloud resource management method and device, storage medium and electronic equipment |
Publications (2)
Publication Number | Publication Date |
---|---|
CN115118731A true CN115118731A (en) | 2022-09-27 |
CN115118731B CN115118731B (en) | 2024-02-27 |
Family
ID=83327417
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202210724906.2A Active CN115118731B (en) | 2022-06-24 | 2022-06-24 | Cloud resource management method and device, storage medium and electronic equipment |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN115118731B (en) |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103164279A (en) * | 2011-12-13 | 2013-06-19 | 中国电信股份有限公司 | Method and system for distributing cloud computing resources |
CN110913016A (en) * | 2019-12-13 | 2020-03-24 | 杭州城市大数据运营有限公司 | Resource management system for cloud resource platform and storage medium |
CN112884382A (en) * | 2021-04-14 | 2021-06-01 | 北京百度网讯科技有限公司 | Resource quota management method, device, equipment and storage medium of cloud platform |
KR20220006490A (en) * | 2021-12-29 | 2022-01-17 | 케이웨어 (주) | Hybrid cloud resource allocation method for workload dynamic resource placement and optimization performance management |
CN114629909A (en) * | 2022-03-28 | 2022-06-14 | 联通(广东)产业互联网有限公司 | Cloud resource cost analysis method |
-
2022
- 2022-06-24 CN CN202210724906.2A patent/CN115118731B/en active Active
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103164279A (en) * | 2011-12-13 | 2013-06-19 | 中国电信股份有限公司 | Method and system for distributing cloud computing resources |
CN110913016A (en) * | 2019-12-13 | 2020-03-24 | 杭州城市大数据运营有限公司 | Resource management system for cloud resource platform and storage medium |
CN112884382A (en) * | 2021-04-14 | 2021-06-01 | 北京百度网讯科技有限公司 | Resource quota management method, device, equipment and storage medium of cloud platform |
KR20220006490A (en) * | 2021-12-29 | 2022-01-17 | 케이웨어 (주) | Hybrid cloud resource allocation method for workload dynamic resource placement and optimization performance management |
CN114629909A (en) * | 2022-03-28 | 2022-06-14 | 联通(广东)产业互联网有限公司 | Cloud resource cost analysis method |
Also Published As
Publication number | Publication date |
---|---|
CN115118731B (en) | 2024-02-27 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN106681835B (en) | The method and resource manager of resource allocation | |
US10644966B2 (en) | Resource management for cloud computing platforms | |
CN108090225B (en) | Database instance running method, device and system and computer readable storage medium | |
US8583799B2 (en) | Dynamic cost model based resource scheduling in distributed compute farms | |
Jiang et al. | Self-adaptive cloud capacity planning | |
Niu et al. | Cost-effective cloud HPC resource provisioning by building semi-elastic virtual clusters | |
CN108874640A (en) | A kind of appraisal procedure and device of clustering performance | |
US20130290511A1 (en) | Managing a sustainable cloud computing service | |
CN111338791A (en) | Method, device and equipment for scheduling cluster queue resources and storage medium | |
CN112988390A (en) | Calculation power resource allocation method and device | |
CN103873528A (en) | Method and equipment for distributing system resources for user | |
Li et al. | Edge cloud resource expansion and shrinkage based on workload for minimizing the cost | |
CN110618867A (en) | Method and device for predicting resource usage amount | |
CN111080235B (en) | Data processing method, device, electronic equipment and computer readable medium | |
CN114860425A (en) | Service cloud platform based on cloud resources | |
Everman et al. | Evaluating and reducing cloud waste and cost—A data-driven case study from Azure workloads | |
Shen et al. | Stochastic modeling and approaches for managing energy footprints in cloud computing service | |
CN115118731B (en) | Cloud resource management method and device, storage medium and electronic equipment | |
CN108563504A (en) | A kind of resource management-control method and device | |
García | The impact of information and communication technologies on economic growth in Mexico | |
CN115952054A (en) | Simulation task resource management method, device, equipment and medium | |
CN111522843B (en) | Control method, system, equipment and storage medium of data platform | |
CN112685377B (en) | Detection processing method, device, server and medium based on historical object data | |
CN115330219A (en) | Resource scheduling method and device | |
CN115168042A (en) | Management method and device of monitoring cluster, computer storage medium and electronic equipment |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |