The present invention relates to a resource amount estimation device and a resource amount estimation method and program.
With the development of virtual machine technology and software defined network (SDN) technology, it has become possible to provide network services to service users by providing data processing functions on demand in the form of a virtual machine or a container when the users want to use them and dynamically setting a communication path between the functions. In response to such a situation, in the past, a serverless computing model which is charged only during the resource usage period has appeared as a service for low usage rate users who have paid a flat rate for each period regardless of the amount of usage to reduce service use costs.
In the serverless computing model, resources are allocated on demand and the resources are released after processing is completed. Therefore, it has a feature that resource allocation and communication between virtual machines occur in a burst.
One requirement for reducing the usage fee is to shorten the processing time. The processing time varies depending on the usage rate of physical calculation resources such as servers or links used by a calculation function and a communication function. The processing time can be shortened by allocating a calculation function and a communication function to an unoccupied device. In order to allocate calculation/communication functions to a device having a low resource usage rate, a technique of deriving an unoccupied device or a communication path and allocating calculation/communication functions for serverless computing processing while considering requirements such as a CPU and an estimated amount of communication data required for serverless computing processing and physical calculation resources for service has been studied for many years.
In the related art, when allocation locations of a calculation function and a communication function have been calculated, the allocation locations have been calculated by aggregating resource information such as the amount of data or the CPU usage rate from a server, a network switch, or the like into an allocation location calculation function and applying the aggregated resource information to an algorithm or the like.
Here, the point to be considered is the freshness of resource information used, that is, the amount of elapsed time from the measurement time of the resource information to the calculation point in time of the allocation location.
Usually, a time lag occurs due to the influence of data transfer delay, processing delay, or the like until measurement data arrives from the physical resource to the allocation location calculation function. Therefore, there is an error between resource information referred to by the allocation location calculation function at the calculation point in time and statistical information observed by a server or a switch that has transmitted the resource information at the calculation point in time.
Therefore, even though the allocation location calculation function calculates an optimum allocation location on the basis of the obtained resource information, there is a possibility that the situation will change when a path is actually allocated and an optimum solution will not be obtained.
The present invention was contrived in view of the above points, and an object thereof is to increase the possibility of resource allocation appropriate for a point in time when the resource is allocated being performed.
Consequently, in order to solve the above problem, there is provided a resource amount estimation device including: an acquisition unit configured to acquire, in response to a request for allocation of a resource, a measurement value of an amount of the resource, a measurement time of the measurement value, and statistical information relating to the resource; and a calculation unit configured to input a measurement value acquired by the acquisition unit and an elapsed time from the measurement time to a scheduled allocation time of the resource into a model that estimates the resource amount in the future on the basis of the statistical information and to calculate an estimation value of the resource amount at the scheduled allocation time.
It is possible to increase the possibility of resource allocation appropriate for a point in time when the resource is allocated being performed.
Hereinafter, embodiments of the present invention will be described with reference to the accompanying drawings.
The service platform P1 is a computer system that provides a predetermined service (for example, a network service) using a virtual machine technique, a software defined network (SDN) technique, or the like. Each service execution device 20 is a computer in which software (a virtual machine (VM) in the present embodiment) for executing processing related to a service is operated.
The client device 30 is a computer that requests the resource allocation device 10 to allocate a system resource (hereinafter simply referred to as a “resource”) required for a service.
The resource allocation device 10 is one or more computers that execute resource allocation according to a request from the client device 30 (hereinafter referred to as a “resource allocation request”) with respect to the service platform P1.
A program for realizing processing in the resource allocation device 10 is provided by a recording medium 101 such as a CD-ROM. When the recording medium 101 having a program stored thereon is set in the drive device 100, the program is installed in the auxiliary storage device 102 from the recording medium 101 through the drive device 100. However, the program does not necessarily have to be installed from the recording medium 101, and may be downloaded from other computers through a network. The auxiliary storage device 102 stores the installed program and stores necessary files, data, and the like.
When there is an instruction for starting a program, the memory device 103 reads out the program from the auxiliary storage device 102 and stores the program. The processor 104 is a CPU or a graphics processing unit (GPU), or a CPU and a GPU, and executes a function related to the resource allocation device 10 in accordance with the program stored in the memory device 103. The interface device 105 is used as an interface for connection to a network.
Meanwhile, the client device 30, the service execution device 20, and the like may also have a hardware configuration as shown in
Hereinafter, a processing procedure which is executed by the resource allocation device 10 will be described.
In step S101, the input reception unit 11 receives a resource allocation request from the client device 30. The resource allocation request includes, for example, information on a VM (hereinafter referred to as “VM information”) that needs to be allocated, a band (for example, 10 Mbps) required for communication between VMs, and the like. The VM information includes, for example, the type (that is, function) of execution processing of the VM, the execution order of each VM, and the like for each required VM.
Next, the measurement information acquisition unit 12 acquires statistical information relating to the amount of resources and the operating status or usage status of resources, or the like from each service execution device 20 and each link that connects the service execution devices 20 (S102). For example, the amount of resources related to calculation processing of a VM (hereinafter referred to as “the amount of calculation resources”) and statistical information (hereinafter referred to as “device statistical information”) such as the usage rate of a processor are acquired from each service execution device 20. For example, the amount of resources related to communication between VMs (hereinafter referred to as “the amount of communication resources”) and statistical information (hereinafter referred to as “link statistical information”) such as an unused band are acquired from each link. Examples of the device statistical information and the link statistical information include an average resource allocation occurrence rate, an average resource allocation time, and the like.
Regarding the service execution device 20, the average resource allocation occurrence rate is the number of VM allocations per unit time, and the average resource allocation time is the average VM operation time related to one allocation. The operation time is a period after a VM is allocated and before the VM is released.
Regarding the link, the average resource allocation occurrence rate is the number of occurrences of a flow per unit time, and the average resource allocation time is the average duration of one flow. Meanwhile, the term “flow” refers to a series of communications between the same communication partners.
Meanwhile, in the present embodiment, it is assumed that the average resource allocation time, average resource allocation occurrence rate, average resource usage amount, and burst traffic generation process of each resource are the same values for each resource allocation request.
The amount of calculation resources and the device statistical information are measured by the resource measurement unit 21 of each service execution device 20. In addition, the amount of communication resources and the link statistical information whose time at a point in time of measurement (measurement time) of the amount of calculation resources and the device statistical information is measured by the time measurement unit 22 of each service execution device 20, and the measurement time thereof is measured by, for example, a network device such as a switch constituting a link.
For example, the measurement information acquisition unit 12 requests each service execution device 20 and each switch to transmit the amount of resources and the statistical information. When the request is received, the resource measurement unit 21 of each service execution device 20 measures the amount of calculation resources at that point in time, and the time measurement unit 22 measures the time at that point in time. The measurement information notification unit 23 of each service execution device 20 transmits the amount of calculation resources and the measurement time of the amount of calculation resources and the device statistical information obtained from the measurement of the amount of resources or the like asynchronous to the request (for example, periodically) to the measurement information acquisition unit 12. In addition, when the request is received, each network device measures the amount of communication resources and the measurement time at that point in time. Each network device transmits the measurement time of the amount of communication resources and the amount of communication resources and the link statistical information obtained from the measurement asynchronous to the request (for example, periodically) to the measurement information acquisition unit 12.
Next, the estimation value calculation unit 13 calculates the estimation value of the future amount of resources, with respect to each resource amount (each amount of calculation resources and each amount of communication resources), by inputting the measurement value of the amount of resources acquired in step S102 and the elapsed time from the measurement time of the amount of resources to the scheduled resource allocation completion time into a model that performs estimation (hereinafter referred to as an “estimation model”) on the basis of each piece of statistical information acquired in step S102 (S103). In the first embodiment, the estimation model is constructed using queuing theory modeled at M/M/100/100. Here, in order to simplify the description, an example in which the amount of communication resources at the scheduled resource allocation completion time is estimated on the basis of the amount of communication resources and the link statistical information will be described. Meanwhile, M/M/100/100 means a model in which the amount of resources that can be allocated is 100 and the maximum value of the amount of resources that can be allocated is 100. For example, a case where a band per flow is 1 Mbps and the maximum value of a band that can be allocated is 100 Mbps corresponds to M/M/100/100.
Here, in a case where the amount of communication resources acquired in step S102 is B (Mbps), the average resource allocation occurrence rate is A, and the average resource allocation time is p, the probability for each band i after t seconds can be calculated on the basis of the following equation of state. Meanwhile, the value of t is the elapsed time from the measurement time of the amount of resources to the scheduled resource allocation completion time. The scheduled resource allocation completion time may be calculated by the estimation value calculation unit 13 on the basis of, for example, the past actual results or the like.
Here, P(i, t) the probability that the amount of communication resources at time t is i Mbps
Therefore, in step S103, the estimation value calculation unit 13 calculates Pj(tj) by substituting tj, λj, and μj for t, λ, and μ in Math (1) for each band I in 1 Mbps increments of 0 to 100 Mbps for each link. Meanwhile, tj is the elapsed time from the measurement time of the communication resource of the link j to the scheduled resource allocation completion time. λj is the average resource allocation occurrence rate of the link j. μj is the average resource allocation time of the link j. Pj(tj) is the probability distribution of each band after tj seconds of the link j. For example, when tj=100 msec, Math (1) represents a probability distribution as shown in
That is, for the link j where t: =100 msec, the estimation value calculation unit 13 calculates Pj(0.1)={Pj(0, 0.1), . . . , Pj(100, 0.1)} with respect to Math (1) to obtain the probability distribution of the band 100 msec after the measurement time.
Next, the estimation value calculation unit 13 calculates the estimation value cj of the band after tj seconds for each link j on the basis of the probability distribution of the band of the link j after tj seconds. As shown in the following Math (2), the expectation value (average value) of the probability distribution is calculated as the estimation value cj.
[Math 2]
c
j
=ΣiP
j(i,tj) (2)
As a result, each amount of communication resources used for path calculation is corrected, for example, as shown in
Meanwhile, although the amount of communication resources has been described above, each amount of calculation resources can also be corrected in the same way (the estimation value at the scheduled resource allocation completion time can be calculated).
Next, the resource allocation unit 14 calculates the service execution device 20 which is a resource allocation destination, a link for allocating a communication path between VMs, and the like on the basis of the estimation value calculated for each resource amount (S104).
Next, the resource allocation unit 14 executes resource allocation according to a resource allocation request on the basis of the calculation result in step S104 (S105).
Meanwhile, steps S104 and S105 may be performed on the basis of known techniques.
Next, a second embodiment will be described. In the second embodiment, differences from the first embodiment will be described. Points which are not particularly mentioned in the second embodiment may be the same as those in the first embodiment.
In the second embodiment, the content of steps S102 and S103 in
In step S102, the measurement information acquisition unit 12 acquires time-series data of each amount of resources (the amount of calculation resources, the amount of communication resources) from each service execution device 20 and each link. The time-series data is, for example, a history of the amount of resources measured periodically.
In the next step S103, the estimation value calculation unit 13 calculates the estimation value of the resource allocation completion time (t seconds after the measurement time) for each amount of resources using the estimation model based on statistical processing based on the time-series data.
The details of the statistical processing will be described. Here, a method of calculating an estimation value for the amount of calculation resources (CPU usage rate) will be described.
First, the estimation value calculation unit 13 acquires a measurement value r1 at the measurement time and a measurement value r2 t seconds after the measurement time for each measurement time of each measurement value of the time-series data, and generates a pair of measurement values of (r1, r2).
Next, the estimation value calculation unit 13 discretizes the measurement values r1 and r2 of each pair. Specifically, measurement values included in the same discrete section among discrete sections set in advance are discretized so as to have the same value. For example, discretization may be performed by rounding to the nearest whole number. The estimation value calculation unit 13 generates a graph showing a transition pattern from r1 to r2 on the basis of a discretized pair group.
Next, the estimation value calculation unit 13 calculates the occurrence probability (transition probability from each measurement value) by counting the number of occurrences of each transition pattern for each transition pattern having the same transition source node and dividing the number of occurrences by the total number of transition patterns related to the transition source node.
Next, for each calculation resource, the estimation value calculation unit 13 weights the transition probability of each transition pattern having the measurement value (value acquired in step S102) of the calculation resource as the transition source node, and calculates a weighted average of values of transition destination nodes (amounts of resources) of each transition pattern as the estimation value of the amount of resources at the scheduled allocation completion time.
Step S104 and subsequent steps in
Meanwhile, one transition graph may be generated on the basis of the time-series data from all the service execution devices 20, or may be generated for each service execution device 20. In the latter case, a transition graph based on the time-series data of the service execution device 20 related to a certain calculation resource may be used to calculate the estimation value of the resource amount of the calculation resource.
In addition, although the calculation resource has been described above for convenience, the estimation value calculation unit 13 similarly calculates the estimation value of the amount of resources t seconds after the measurement time for each communication resource.
Next, a third embodiment will be described. In the third embodiment, differences from the first embodiment will be described. Points which are not particularly mentioned in the third embodiment may be the same as those in the first embodiment.
In the third embodiment, an example in which a model based on machine learning is used as an estimation model will be described. Meanwhile, in the third embodiment, for convenience, a calculation resource will be described.
In the third embodiment, learning of the estimation model is executed in the following procedures (1) to (3) before the processing procedure of
(1) The measurement information acquisition unit 12 acquires statistical information (for example, the number of operating VMs and the type of execution processing of each VM) on the measurement time, the amount of calculation resources, and software (VM) that uses resources related to the amount of resources which are recorded by the resource measurement unit 21 of each service execution device 20 at the periodic measurement time, as learning data, from each service execution device 20. That is, time-series data including the measurement time, the amount of resources, and the statistical information at each measurement point in time is acquired.
(2) The estimation value calculation unit 13 used the time-series data as learning data and causes the estimation model to learn a transition relationship between the measurement time, the amount of resources, and the statistical information. For example, the transition pattern as described in the second embodiment is learned by the estimation model. In this case, the type of execution processing may be replaced with, for example, a numerical value indicating each type. Meanwhile, the estimation model is a function that uses time, the amount of resources, and the statistical information as inputs and outputs an estimation value of the amount of resources at the time.
(3) After a technician identifies outputs performed by the estimation model, an output determined to be significant may be input to the estimation model again and the estimation model may be relearned.
Meanwhile, as the estimation model, a model common to all the service execution devices 20 may be trained, or learning may be performed for each service execution device 20.
In the third embodiment, the processing procedure of
In step S102, the measurement information acquisition unit 12 acquires the calculation resource at the current point in time, the measurement time of the calculation resource, and the statistical information (for example, the number of operating VMs and the type of execution processing each VM) of the service execution device 20 at the current point in time from each service execution device 20.
In step S103, the estimation value calculation unit 13 inputs the calculation resource acquired from the service execution device 20, the time t seconds after the measurement time of the calculation resource (that is, the scheduled resource allocation completion time), and the statistical information of the service execution device 20 at the current point in time into a trained AI system for each service execution device 20, and calculates the estimation value of the calculation resource at the scheduled resource allocation completion time. Meanwhile, in a case where the estimation model is constructed for each service execution device 20, the estimation value calculation unit 13 uses an estimation model trained for the service execution device 20 for each service execution device 20.
Step S104 and subsequent steps in
Meanwhile, although the calculation resource has been described above for convenience, the estimation value calculation unit 13 similarly calculates the estimation value of the amount of resources t seconds after the measurement time for each communication resource.
As described above, according to each of the embodiments, the amount of resources at the measurement point in time is corrected to the estimation value at the scheduled resource allocation completion time on the basis of the model based on the statistical information relating to the resource. Therefore, even in a case where there is a time lag between a point in time when the resource amount is measured and a point in time when the resource is allocated, it is possible to increase the possibility of resource allocation appropriate to a point in time when the resource is allocated being performed. As a result, for example, the VM processing time and the VM communication time are reduced, and the reduction of service use costs can be expected.
Meanwhile, in each of the embodiments, the resource allocation device 10 is an example of a resource amount estimation device.
Although an embodiment of the present invention has been described in detail above, the present invention is not limited to the specific embodiment described above, and various modifications and changes can be made within the concept of the present invention described in the claims.
Filing Document | Filing Date | Country | Kind |
---|---|---|---|
PCT/JP2020/032029 | 8/25/2020 | WO |