# Enhanced Virtualization-Based Dynamic Bin-Packing Optimized Energy Management Solution for Heterogeneous Clouds

Authors: Neha Gupta; Kamali Gupta; Deepali Gupta; Sapna Juneja; Hamza Turabieh; Gaurav Dhiman; Sandeep Kautish; Wattana Viriyasitavat
Journal: Mathematical Problems in Engineering
 (2022)

---

## Abstract

Cloud computing provides unprecedented advantages of using computing resources with very less efforts and cost. The energy utilization in cloud data centers has forced the cloud service providers to raise the expense of using its services and has increased the carbon footprints in the environment. Many static bin-packing algorithms exist which can reduce energy by some percentage, but with new era of digitization, advanced and dynamic techniques are required which can serve heterogeneous users and random users’ requests. Thus, in this paper, two new dynamic best-fit decreasing-based bin-packing algorithms are proposed wherein the first technique is for service providers and focuses on increasing server utilization and the second approach acts as a switcher to harness best results among all algorithms. Both techniques deliberately achieve high performance in terms of total energy consumption, resource utilization, and makespan along with serving continuous and varying requests from customers. The simulations are performed using Java. The results exhibited that DEE-BFD can escalate resource utilization by 96% and EM switcher can reduce total energy consumption by 49% and reduce makespan by 56%.


---

## Body

## 1. Introduction

Cloud computing is the trading of resources over the Internet with reliability and security of data [1, 2]. The ease of accessing computing resources has attracted big organizations to avail the services from cloud computing on pay-per-use model. As the demand of digitization in current scenario is increasing, more customers are linking with cloud computing technology to get the benefits. Due to this, the total energy consumption has become a challenge for service providers as the situation will get even worse with coming days in the absence of suitable solution. The increasing energy is affecting the environment by increasing carbon footprints. In this direction, service providers started using the concept of virtualization. It is not worth to dedicate all resources of a single server to customer for completing the task, so multiple virtual instances are created on each server and instead of providing the server, cloud service provider assigns virtual machines to the customer with CPU capacity depending on the task to be executed by the customer. This process of creating virtual machines on server is known as virtualization [2] as shown in Figure 1. All the virtual machines share the resources of host server and provide service to the user. The software which provisions and maintains the virtual machines is hypervisor which can operate on hardware level or operating system level depending upon the configuration done by cloud service provider.Figure 1
Server virtualization.It is necessary to assign the VM to the server in very efficient manner so that the overall energy consumption can be turned down along with proper resource utilization. To overcome this problem, a technique of bin-packing [3] came into existence. According to bin-packing, all incoming VM requests are assigned to the server according to the CPU capacity available in server and CPU capacity required by the virtual machine.The main role of bin-packing technique is to reduce number of active bins to lessen energy consumption. The basic heuristics of bin-packing technique which are prevalent in the cloud paradigm are as follows: (1) assigning VM to the first available physical host with required computing capacity (first-fit algorithm); (2) assigning the VM to the server such that after assignment, server has minimum available space (best-fit algorithm); and (3) assigning the VM to the server such that after assignment, server has maximum available space (worst-fit algorithm). Some other heuristics are also present like “first-fit decreasing (FFD),” “best-fit decreasing (BFD),” and “worst-fit decreasing (WFD)” which function like above-mentioned heuristics, but the difference is that all VMs are sorted in descending order of CPU capacity before allotting them to servers.Therefore, as the bin-packing has an imperative importance in energy management solutions, the contributions of this research work are as follows:(i)
A dynamic bin-packing energy-efficient solution is proposed that can increase resource utilization and thus assist service providers in extracting maximum cost benefit with the available resources.(ii)
A dynamic bin-packing switcher-based solution is proposed that can reduce energy consumption by switching among the proposed and existing techniques that are consuming least energy in every pivot run.(iii)
A detailed comparison study is done between proposed algorithms and existing algorithms.The organization of the paper is presented as follows. Section2 illustrates an intensive survey of cloud-based bin-packing heuristics. Section 3 discusses the proposed approaches. Section 4 exhibits results and discussion giving a comparative analysis of the proposed and existing approaches. Section 5 presents the conclusion.


## 2. Literature Review

The review of current state of research with respect to bin-packing mechanisms is presented below.Kumaraswamy S. et al. in [5] presented bin-packing-based virtual machine placement (VMP) methods for cloud data centers in terms of heuristics used, energy awareness, bandwidth awareness, and QoS awareness factors. The paper also explained resource-aware VMP scheme, power-aware VMP scheme, network-aware VMP scheme, and cost-aware VMP scheme. Bin-packing heuristics are very effective in reducing energy. Gbaguidi et al. in [6] presented an algorithm to handle initial assignment of VM to physical servers using Vmware hypervisor ESXi 5.5. The algorithm is based on first-fit decreasing algorithm of bin-packing and is compared with manual and brute force method of placement. Li et al. in [7] proposed a variant of dynamic bin-packing named as “MinTotal DBP” problem to decrease the cost of servers. Competitive ratio of all packing algorithms (first-fit, best-fit, and any-fit) is analyzed for the problem. The paper also proposed a new algorithm, hybrid-first fit, with better competitive ratio.Fatima et al. in [8] focused on virtual machine placement problem and proposed “particle swarm optimization algorithm with variable sized bin-packing.” Simulation was done on MATLAB. The given algorithm was compared with earlier existing “particle swarm optimization” and a hybrid of “Lévy flight and particle swarm optimization” and showed good performance by decreasing number of active servers. Baker et al. in [9] presented a novel multi-cloud service computing approach, i.e., “Cloud-SEnergy.” The experiments were stimulated using Java EE8. The experiment was conducted to compare Cloud-SEnergy’s efficiency with multi-cloud environments. Tantawi and Steinder in [10] introduced “adaptive bin-packing” algorithm which used the variable demand and resources in cloud data center to provide optimized results in C language.Karwayun in [11] discussed dynamic resource allocation scheme based on the bin-packing approach. Three algorithms, first fit bin-packing resource allocation algorithm, energy consumption calculator, dynamic VM reallocation, were proposed for which simulation was done on CloudSim. These algorithms combined the allocation and migration algorithms and were found to be efficient. Gupta and Katiyar in [12] proposed a new static bin-packing algorithm EU-BFD to minimize the energy consumption. The algorithm was compared with “low perturbation bin-packing algorithm,” “best-fit decreasing,” and “power and computing capacity-aware best-fit decreasing” algorithms and proved to be more energy-efficient algorithm.Ali et al. in [13] described all the energy-efficient techniques like virtual machine selection methods, virtual machine placement methods, virtual machine migration methods, virtual machine scheduling methods, and virtual machine allocation methods with their pros and cons. Berndt et al. in [14] considered fully dynamic bin-packing problem by calculating the amount of repacking by the term “migration factor.” The paper also explained the methods to handle large and small size items in dynamic environment. Kumaraswamy and Nair in [15] discussed virtual machine placement problem and proposed three algorithms—“3-slot first-fit decreasing algorithm, PTAS-3-slot algorithm, and 3-slot random fit algorithm,” in which virtual machines were divided into three classes. The paper showed that three algorithms are optimal solutions for virtual machine placement problem. Guo and others in [16] focused on reducing the number of active servers and proposed “multi-dimensional cloud resource dynamic allocation model (MDCRA)” based on VBPP (vector bin-packing problem) which had significantly reduced the number of used servers.Gupta and Katiyar in [17] proposed a framework for calculation of energy used for scheduling resources on physical machines. The framework was tested for existing bin-packing techniques. Aydın et al. in [18] worked on virtual machine placement problem where start time and end time were considered. The paper worked on binary programming approach to develop different policies by improved heuristic. The proposed heuristics can solve large-scale problems with minimum optimality gaps. Kaaouache and Bouamama in [19] proposed a hybrid genetic algorithm “hybrid genetic best fit (HGBF_BP)” based on best-fit decreasing bin-packing algorithm for infeasible chromosomes. It was proved to be an effective virtual placement technique. Tang et al. in [20] discussed new approach to solve MinUsageTime problem using first fit packing algorithm and established a new upper bound. Ghaderi et al. in [21] worked on the asymptotic best-fit algorithm and showed that it minimizes the number of servers asymptotically.Azar and Shepherd in [22] discussed “d-dimensional bin-packing problem” and proposed virtual VBP algorithm and load balancing VBP algorithm. Mohiuddin et al. in [23] discussed basic bin-packing algorithm like first fit and best fit and proposed “secure distributed adaptive bin-packing algorithm” for better storage and time requirement. Wang and Liu in [24] proposed a new energy-efficient model considering energy efficiency in cloud computing environment to improve the bin-packing algorithm. Komarasamy and Muthuswamy in [25] proposed a new approach “dynamic load balancing with effective bin-packing and VM reconfiguration” which used the deadline-based job scheduler of jobs and stored them in other data structure. After differentiation, the jobs are prioritized using various parameters. Sharma and Saini in [26] proposed a VM placement system based on genetic properties and compared it with other existing VM placement techniques based on bin-packing and found genetic algorithm more useful in VM placement.


### 2.1. Summary

Based on exploration done in the field of bin-packing with a vision to discover solutions for energy mitigation, following are the observations on the survey conducted:(i)
Efficient bin-packing technique plays a vital role in reducing the total energy consumption in cloud data centers.(ii)
The four basic heuristics for static bin-packing are LPBP, BFD, PCA-BFD, and EU-BFD.(iii)
Out of the four static algorithms, BFD utilizes server efficiently as it chooses the server in which the vacant space left after assignment of VM is least.(iv)
Some dynamic bin-packing algorithms are already proposed that can reduce more energy than static algorithms but with the growth in technology, more efficacious dynamic heuristics are required which can work on multiple parameters like energy, resource utilization, makespan, and so on, while reducing energy to a better extent.The observations laid down above has arisen a need to transform existing static solutions which becomes a base for energy mitigation initiative into Dynamic one and should also possess characteristics of quality improvement. The need for this switch is presented as follows:(i)
Nowadays, every organization is shifting towards digitization and their requirements have become heterogeneous and dynamic. The ever-increasing user requests across geographical boundaries have restricted these static algorithms in the current scenario and have forced the cloud management system to shift to dynamic approaches for each individual process. Though a number of dynamic solutions have been proposed in recent years, each solution was inclined towards reducing energy to some extent and was overlooking the performance of the cloud system as a whole.(ii)
As energy consumption has increased, it has led to a global impact resulting in high global warming, which has thus put extra overhead of escalated cost of service offering on service providers resulting in high cost on customers for service extraction. As the cloud is not comprised of a single user but has been implanted via a number of entities in form of both service providers and customers, it becomes imperative to address the solutions that can provide monetary benefits to both the participating entities. Reduced energy consumption can be achieved with newer solutions that can turn off servers by shifting their load on other operational servers.Therefore, dynamic energy management solutions are essentially required and are of utmost importance to cater to the ever-changing and escalating customer requirements without compromising the quality-of-service delivery in order to retain trust of user on automated systems. Thus, next section explains the contributions of the present research in the form of proposed approaches or heuristics.


## 2.1. Summary

Based on exploration done in the field of bin-packing with a vision to discover solutions for energy mitigation, following are the observations on the survey conducted:(i)
Efficient bin-packing technique plays a vital role in reducing the total energy consumption in cloud data centers.(ii)
The four basic heuristics for static bin-packing are LPBP, BFD, PCA-BFD, and EU-BFD.(iii)
Out of the four static algorithms, BFD utilizes server efficiently as it chooses the server in which the vacant space left after assignment of VM is least.(iv)
Some dynamic bin-packing algorithms are already proposed that can reduce more energy than static algorithms but with the growth in technology, more efficacious dynamic heuristics are required which can work on multiple parameters like energy, resource utilization, makespan, and so on, while reducing energy to a better extent.The observations laid down above has arisen a need to transform existing static solutions which becomes a base for energy mitigation initiative into Dynamic one and should also possess characteristics of quality improvement. The need for this switch is presented as follows:(i)
Nowadays, every organization is shifting towards digitization and their requirements have become heterogeneous and dynamic. The ever-increasing user requests across geographical boundaries have restricted these static algorithms in the current scenario and have forced the cloud management system to shift to dynamic approaches for each individual process. Though a number of dynamic solutions have been proposed in recent years, each solution was inclined towards reducing energy to some extent and was overlooking the performance of the cloud system as a whole.(ii)
As energy consumption has increased, it has led to a global impact resulting in high global warming, which has thus put extra overhead of escalated cost of service offering on service providers resulting in high cost on customers for service extraction. As the cloud is not comprised of a single user but has been implanted via a number of entities in form of both service providers and customers, it becomes imperative to address the solutions that can provide monetary benefits to both the participating entities. Reduced energy consumption can be achieved with newer solutions that can turn off servers by shifting their load on other operational servers.Therefore, dynamic energy management solutions are essentially required and are of utmost importance to cater to the ever-changing and escalating customer requirements without compromising the quality-of-service delivery in order to retain trust of user on automated systems. Thus, next section explains the contributions of the present research in the form of proposed approaches or heuristics.


## 3. Proposed Approaches

The increased energy usage by the cloud data centers has increased the effect of global warming [29] and the calculated cost of using computing resources online [30, 31]. The inclination of bin-packing heuristics is towards reducing number of active servers for energy mitigation [4] in heterogeneous environment. In inception, the existing basic static algorithms [12]—low perturbation bin-packing (LPBP), best-fit decreasing (BFD), power and computing aware-BFD (PCA-BFD), and energy utilized-BFD (EU-BFD)—are converted into dynamic algorithms (dynamic LPBP, dynamic BFD, dynamic PCA-BFD, and dynamic EU-BFD) by adding the following values as additional inputs:(i)
Time period after which new virtual machine requests can enter data center.(ii)
Execution time of each virtual machine.(iii)
Technique to dissolve virtual machine on its completion instead of using hypervisor.To give better results in terms of energy consumption, two dynamic algorithms—dynamic energy efficient-best-fit decreasing (DEE-BFD) and EM switcher (energy mitigation switcher)—are proposed. The proposed approaches have the following characteristics:(i)
Virtual machine is dedicated for one task only.(ii)
Execution time of VM is taken to determine the lifetime of VM and algorithm itself removes the VM from server on its completion.(iii)
After a specified time interval, VMs waiting for execution are allotted to the servers and energy consumption is calculated for each run.(iv)
Once all VMs complete the tasks, resource utilization and makespan [28] value are calculated and can be used for improving the performance of servers.(v)
EM switcher algorithm has the extra property of checking all other dynamic algorithms for list of VMs and implementing the algorithm which uses minimum energy.The terminologies used in algorithms are explained in terms of definition and corresponding equations in Table1.Table 1
List of abbreviations.
AbbreviationDefinitionEquations (if any)PiPower value of server i—CPUiComputing value of server i—CPUvjComputing value of VM j—Ui(F,t)Computing capacity utilization factor of serveri as a function of placement “F” and time “t”Ui(F,t) = (CPU_utili)/(CPUi) [27]Pi(F,t)Utilized power of ith serverTotal power consumption = ∑Pi(F,t)for i = 1 to N,where Pi(F,t) = 0.7 ∗Pi + (0.3 ∗Pi∗Ui(F,t)) for ith server [27]TvmjExecution time by jth VMs—Res_utilAverage resource utilization of data centerRes_util = ∑Res_utili for i = 1 to N [27]Res_utili =∑j=1M/makespan∗MSFixed interval of time, whereS = 10 s—Tvm_maxiMaximum time used by any VM in ith run—MakespanDuration between first job submission and last job completionMakespani =∑i=1R [27]After detailed discussion on the mathematical equations, the bin-packing algorithms are explained below.


### 3.1. Dynamic Energy Efficient-Best-Fit Decreasing (DEE-BFD) Algorithm

Initially, the CPU capacity and power requirement of N servers andM virtual machines are entered as input. Firstly, servers are sorted based on power capacity and virtual machines are sorted in decreasing order of CPU capacity. Then, M VMs are allotted to N servers. After every S seconds, new VM requests are allotted to server and energy consumption is calculated. After all runs, resource utilization and makespan are calculated to examine the overall data center’s performance as shown in Figure 2. The algorithmic approach is presented below.Figure 2
Workflow of DEE-BFD.Algorithm 1: DEE-BFD.
(i)
Enter CPU capacity and power requirement for N servers.Servers are sorted based on power capacityVirtual machines are sorted in decreasing order of CPU capacityWhile trueIf VMs are waiting in job after S secondsEnter CPU capacity and execution time frame forM virtual machinesAllot VM to the server with required computing capacity and create a data structureCompute total energy consumed by current configurationEnd IfEnd WhileEvaluate the total resource utilization and makespan of servers.


### 3.2. EM Switcher

All the bin-packing algorithms can reduce the energy consumption depending on the user’s request and available resources present in the cloud data centers. Any one algorithm cannot be considered as the best algorithm which can reduce the energy consumption in all situations, so a new algorithm is proposed which switches between the algorithms and implements the algorithm which uses least energy for the complete assignment. The detailed working of EM switcher algorithm is shown in Figure3 which starts from data generation by different sectors followed by storage and processing of data at cloud data centers with the aim to complete the tasks with minimum energy consumption and better resource utilization.Figure 3
Workflow of EM switcher algorithm.Algorithm 2: EM switcher (energy mitigation switcher).
Enter CPU capacity and power requirement for N servers.While trueIf VMs are waiting in jobEnter CPU capacity and execution time frame forM virtual machinesApply algorithms dynamic low perturbation bin-packing, dynamic best-fit decreasing, dynamic power and computing capacity aware best-fit decreasing, dynamic energy utilized best-fit decreasing, and dynamic energy efficient-best-fit decreasing on the current configuration of servers and virtual machinesCompute total energy/power utilized by data center using utilization factor in all algorithms.Compare the energy consumption value for individual algorithm.Implement the algorithm with minimum energy for current run.End IfEnd WhileEvaluate the total resource utilization and makespan of servers.The next section presents the detailed analysis of the proposed approaches followed by discussion on the results.


## 3.1. Dynamic Energy Efficient-Best-Fit Decreasing (DEE-BFD) Algorithm

Initially, the CPU capacity and power requirement of N servers andM virtual machines are entered as input. Firstly, servers are sorted based on power capacity and virtual machines are sorted in decreasing order of CPU capacity. Then, M VMs are allotted to N servers. After every S seconds, new VM requests are allotted to server and energy consumption is calculated. After all runs, resource utilization and makespan are calculated to examine the overall data center’s performance as shown in Figure 2. The algorithmic approach is presented below.Figure 2
Workflow of DEE-BFD.Algorithm 1: DEE-BFD.
(i)
Enter CPU capacity and power requirement for N servers.Servers are sorted based on power capacityVirtual machines are sorted in decreasing order of CPU capacityWhile trueIf VMs are waiting in job after S secondsEnter CPU capacity and execution time frame forM virtual machinesAllot VM to the server with required computing capacity and create a data structureCompute total energy consumed by current configurationEnd IfEnd WhileEvaluate the total resource utilization and makespan of servers.


## 3.2. EM Switcher

All the bin-packing algorithms can reduce the energy consumption depending on the user’s request and available resources present in the cloud data centers. Any one algorithm cannot be considered as the best algorithm which can reduce the energy consumption in all situations, so a new algorithm is proposed which switches between the algorithms and implements the algorithm which uses least energy for the complete assignment. The detailed working of EM switcher algorithm is shown in Figure3 which starts from data generation by different sectors followed by storage and processing of data at cloud data centers with the aim to complete the tasks with minimum energy consumption and better resource utilization.Figure 3
Workflow of EM switcher algorithm.Algorithm 2: EM switcher (energy mitigation switcher).
Enter CPU capacity and power requirement for N servers.While trueIf VMs are waiting in jobEnter CPU capacity and execution time frame forM virtual machinesApply algorithms dynamic low perturbation bin-packing, dynamic best-fit decreasing, dynamic power and computing capacity aware best-fit decreasing, dynamic energy utilized best-fit decreasing, and dynamic energy efficient-best-fit decreasing on the current configuration of servers and virtual machinesCompute total energy/power utilized by data center using utilization factor in all algorithms.Compare the energy consumption value for individual algorithm.Implement the algorithm with minimum energy for current run.End IfEnd WhileEvaluate the total resource utilization and makespan of servers.The next section presents the detailed analysis of the proposed approaches followed by discussion on the results.


## 4. Results and Discussion

The bin-packing approach revolves around the implementation of 4 prime techniques, namely, LPBP, BFD, PCA-BFD, and EU-BFD [12]. The techniques are static in nature as indicated above and have been converted into dynamic one for comparison with the proposed approaches DEE-BFD and EM switcher. Simulation is done on Java programming language with considered configuration as follows: upper limit for computing capacity of a server is 5000, computing capacity of a virtual machine is 1500, and power capacity of a server is 450. The assumptions for the simulation are as follows. (1) Sufficient servers are available in cloud data center. (2) Servers are compatible to provide required computing power to the VMs. For the simulation, 10 servers were taken with following configuration as presented in Table 2.Table 2
Server configuration.
Server no.12345678910CPU capacity2526324515151015124633392040169022904530Power capacity200150400330450220150200250300A finite number of VM requests were sent on servers to analyze the energy usage, resource utilization, and makespan of servers for mentioned algorithms. The VM configurations entered for two such pivot runs are presented in Tables3 and 4.Table 3
VM configuration for first run.
VM no.123456789101112CPU capacity120010005006001220102052062012401040540640Duration (seconds)805077908050779080507790Table 4
VM configuration for second run.
VM no.123456789101112CPU capacity8805001200100055059088250212021002552592Duration (seconds)20355034801002035503480100Considering the above-mentioned server and VM configuration, two consecutive runs were conducted, and energy consumption is calculated for each run along with resource utilization and makespan at the end of second run. The results of the simulation runs are presented in Table5. The abbreviations used in Table 5 are as follows: E1—energy consumption after first run, E2—energy consumption after second run, RU—resource utilization after both runs, and MS—makespan after both runs.Table 5
Results.
DLPBPDBFDDPCA-BFDDEU-BFDDEE-BFDEM switcherEnergy 11636.141567.471221.591146.091166.261146.09Energy 22507.232825.802779.812749.462655.601403.61Total energy4143.374393.274001.43821.863821.862549.7% energy reduction171220242449Resource utilization0.72760.75380.75850.75080.78260.4941% resource utilization increment828890889624Makespan810.0781.0659.0690.0595.0440.0% makespan reduction192234314156According to Table5, graphs are plotted for each parameter to study the comparative analysis of all dynamic bin-packing algorithms in terms of energy consumption, makespan, and resource utilization as shown in Figures 4–9.Figure 4
Energy consumption.Figure 5
Energy consumption analysis.Figure 6
Makespan.Figure 7
Makespan Analysis.Figure 8
Resource utilization.Figure 9
Resource utilization analysis.According to Figures4–9, EM switcher provides maximum energy reduction among all dynamic algorithms and DEE-BFD provides maximum reduction in makespan and maximum increment in resource utilization. The overall performance can be improved by working on individual parameters like energy consumption, makespan, and resource utilization.


## 5. Conclusion

Virtualization and bin-packing are key techniques used to reduce energy by creating multiple virtual machines and turning down the number of active bins in data centers. In this paper, the two new bin-packing algorithms are proposed, DEE-BFD and EM switcher. The performance of these algorithms is compared with other existing algorithms on same input values in Java. After execution of each slot of VMs, energy is computed to get the performance matrix of data center, and at any moment, cloud service provider can calculate the resource utilization and makespan for further improvement in resource efficiency. After the analysis, it has been observed that the DEE-BFD provides the best resource utilization and EM switcher provides reduced energy consumption and makespan. Though the algorithms are proficient in their working and are giving better results in comparison to the existing techniques, still shifting or balancing of load is required considering the situations of failure of server irresponsiveness due to heavy load.Thus, as a future work, subsequent to implementation of above approaches, strategies for live migration need to be explored and solutions should be proposed to avoid problems of server irresponsiveness.



---

*Source: 8734198-2022-01-30.xml*