2016 4th International Conference on Future Internet of Things and Cloud Workshops
A New Scalable and Energy Efficient Algorithm for VMs Reassignment in Cloud Data Centers Makhlouf Hadji1 , Nabila Djenane2 , Rachida Aoudjit2 and Samia Bouzefrane3 1
Technological Research Institute SystemX, Palaiseau, France
[email protected] 2 LARI Lab, University Mouloud Mameri of Tizi-Ouzou, Algeria 3 Conservatoire National des Arts et M´etiers, CEDRIC Lab, Paris, France
[email protected]
Abstract—To improve resource utilization in Cloud Data Centers and in order to reduce energy consumption at the same time, reassignment of services is required and leads to efficient operational costs. This paper presents a new and scalable algorithm based on b-matching theory to judiciously replace resources (considered as Virtual Machines in our work) according to energy consumption constraints. Our algorithm is benchmarked by an exact approach based on an Integer Linear Program (ILP) formulation of the Bin-Packing problem. The bMatching algorithm allows to find near-optimal solutions and scale for large problem instances.
It is important to mention that a smart placement of VMs is not enough even if we use an exact approach to reach the optimal placement solution. Thus, and after departure of certain VMs, the physical infrastructure suffers from wasted energy as some servers are under-used. To cope with this problem, we propose a new scalable approach that can attend near optimal/optimal solution in few seconds even for large problem instances. Our work focuses on optimizing two operations:
Index Terms—Cloud Data Centers, Energy, Migration, Scalability, Optimization
•
I. I NTRODUCTION •
This paper addresses data center resource reassignment to reduce efficiently energy consumption of used servers when guaranteeing an SLA and a QoS. Indeed, with the growing of requests and demands in virtual resources, cloud data centers suffer from higher energy consumption and an increasing carbon footprints. For these reasons, cloud providers require scalable and cost efficient solutions to reduce energy consumption when meeting end-users requests. There exists different solutions to cope with the problem of wasted energy and under-used servers. Some solutions resort to monitoring approaches which consists in supervising servers’ energy consumption and then take decisions when needed. Other solutions are based on renewable energy as solar and photovoltaic energies to reduce efficiently cooling fees. In our work, we propose algorithmic solutions leading to consolidate and shut down the under-used servers after a migration operation. This migration consists in moving certain VMs from sources to optimal destinations. Besides, we propose two approaches to reach optimal solutions of the VMs reassignment problem with a hard constraint of energy consumption.
978-1-5090-3946-3/16 /16 $31.00 © 2016 IEEE $31.00 © 2016 IEEE DOI 10.1109/W-FiCloud.2016.69
Integer Linear Program Formulation: that will describe the convex hull of the reassignment problem, and then reveal its NP-Hardness when addressing large problem instances; b-Matching Formulation Reassignment: By considering energy consumption constraints, we investigate rapid and convergent approach based on the b-Matching theory to achieve near-optimal/optimal resource utilization and energy consumption.
Section II of the paper presents related work on cloud data centers resource optimization taking into account energy consumption. The paper proposes in Section III, a Linear Integer Program followed by a new scalable algorithm based on a b-Matching theory. The b-Matching approach is then benchmarked by the Integer Linear Program formulation of the Bin-Packing problem. In Section IV, the two approaches are theoretically compared with a clear advantage of the bMatching approach. Conclusions and future work can be found in Section IV. II. R ELATED WORK To reduce power consumption and SLA violation in the cloud data centers, authors of [1] presented a dynamic consolidation method employing a reinforcement learning approach to learn the host power mode detection policy. Then, the proposed method can adapt the number of active hosts to meet end-users requests when minimizing energy costs.
310
Authors of [2] discussed the energy efficiency of cloud data centers with a focus on the Container as a Service (CaaS) environment. Thus, the authors proposed a framework to tackle the issue of energy efficiency in the context of CaaS through container consolidation and reduction in the number of active servers. Finally, a set of simulation experiments were carried out to evaluate the impact on system performance and data center energy consumption of the proposed algorithms for triggering migrations, selecting containers for migration, and selecting destinations. Another reference focusing on robustness and energy efficiency in cloud data centers can be found in [3]. Authors of this paper proposed a novel approach to the energy efficient VM consolidation problem by applying Robust Optimization Theory. A mathematical model is developed as a robust Mixed Integer Linear Program under the assumption that the input to the problem (e.g. resource demands of the VMs) is not known precisely, but varies within given bounds. The proposed solution is considered as a tradeoff between the power consumption and the protection from more severe and unlikely deviations of the uncertain input.
III. S YSTEM M ODEL We start the resources (i.e. VMs) reassignment problem from an initial placement solution that can be optimal and investigate new optimal or near-optimal solutions that indicate energy efficient solutions leading to migrate VMs in a judicious manner. Figure 1 depicts the VM reassignment problem within a cloud provider with a certain number of physical servers (ON and OFF servers, and stressed or not stressed servers). Cloud providers aim at proposing high QoS when reducing energy consumption at the same time. Thus, Figure 1 depicts a cloud provider’s data center with three collaborative mechanisms leading to reach optimal/near optimal solutions of the reassignment problem. These mechanisms are described as follows: •
•
Authors of reference [4] discussed dynamic optimization methods to address energy consumption for virtualized data centers. This optimization can reduce the operational costs of data centers. Authors proposed a dynamic and robust consolidation approach, which allows reducing energy consumption by hosts, the number of VMs migration, and the number of power state changes. The authors showed that the proposed approach realizes significant reduction in energy consumption of network infrastructure, which results from VM migration. Nevertheless, some constraints are not taken into account (VMs ping pong effect for instance).
•
Placement Engine: A smart solution that initially allows to select judiciously adequate servers according to the requests (VMs) in order to use a minimum number of servers. This leads to reduce energy consumption. Consolidation Engine: After VMs departures, some physical servers are under-used causing wasted energy. This entity proposes smart reassignment solutions that can consolidate the physical substrate in few seconds. This consolidation will reduce the number of used servers and the unused servers are shut down. This leads to minimize the energy consumption. The consolidation mechanism takes optimal decisions using the energy monitoring information. Energy Monitor: A mechanism or a tool used to gather servers’ energy consumption information that will be used to consider reassignment of resources which occurs from time to time (each 5 mn for example - see [7]). This is due to VMs departures for instance.
In reference [5], authors discussed how to reduce cloud data center energy consumption while meeting QoS requirements. The main idea of [5] consists in classifying under-loaded hosts into three further states, i.e., under-loaded, normal and critical by applying underload detection algorithms. Moreover, the authors designed an overload detection policy called Mn which uses the mean to predict the upper threshold and VM selection policy, called MBW, based on the maximum requested bandwidth. The closest reference to our work can be found in [6]. Authors of [6] described an exact mathematical model to cope with VMs placement as an initial optimal solution, and before departures of VMs. Another exact algorithm is described to deal with VMs consolidation when energy consumption constraints are taken into account. These models suffer from scalability issue and we propose in our work an alternative scalable and energy efficient solution for the reassignment/consolidation problem taking into account energy consumption constraints.
Fig. 1: Data-center resources consolidation: High level view In the following, we consider end-users requests of N VMs to be optimally placed within cloud provider’s data center illustrated in Figure 1. Each VM V Ma is characterized by:
311
• •
A lifetime ta : which represents the time duration before an automatic log-off from the server hosting it. A limit power consumption: According to VMs required capacity (CPU, memory, etc), we associate to each V Ma
a power consumption indicator to estimate its energy consumption limit, noted by la . A cloud provider (shown in Figure 1) data center disposes of certain number of various servers characterized by: • • •
A limit number of available servers. A power cap: which represents the maximum power consumption of a server s. This is noted by Cs . A current energy consumption: which represents the current server’s power consumption. This is noted by Cs,Current , for a server s.
To achieve energy efficiency, we propose to re-place virtual resources (VMs) by migrating them optimally when considering energy consumption constraints and satisfying end-users requests. Thus, we investigate new approaches that dynamically consolidate the physical infrastructures when some departures have occurred. In the following, we discuss the complexity of the reassignment problem and propose an exact method based on an Integer Linear Program to solve small and practical instances of the problem. To cope with problem scalability and to reach near-optimal solutions for large problem instances in few seconds, we propose a new algorithm based on the bMatching theory.
B. Integer Linear Program Formulation In this section, we propose an exact formulation of the reassignment problem based on an Integer Linear Program (ILP) as described in [6]. Indeed, this exact mathematical model can be used only for small problem instances and then suffers for scalability issues. Nevertheless, the aim of this paper is to propose a new and scalable algorithm to deal with large problem instances, and the search for another exact method is out of the scope of this paper. The mathematical model of [6] relies on linear programming in which the objective is to reduce the number of used servers and the power consumption caused by the migrations. This objective is given as follows: max Obj =
κ X
Pi,idle yi −
qi κ X κ X X
lv zijv
(1)
i=1 j=1 v=1
i=1
where yi is a bivalent variable associated to each server i. If yi = 1 then the server i is idle, elsewhere, it is not. Variable zijv is a bivalent variable indicating the migratiion of a VM v from a server i to a server j. Parameter qi indicates the number of available VMs in server i, and Pi,idle is the power consumed by idle servers. The objective function (1) is subject to a certain number of constraints that are summarized below. More details can be found in [6]. 1) Prevent backward migrations (ping-pong effect):
A. Problem Complexity
zijv + zjlv0 ≤ 1; ∀l 6= j As it is described above, the reassignment problem consists in migrating judiciously VMs from a selected set of servers to the optimal ones leading to reduce data center’s energy consumption.
(2)
2) Migration with a unique destination: κ X
zijv ≤ 1;
(3)
j=1,j6=i
3) Servers with power limit constraints:
We assume to have N VMs deployed on K available servers in the provider data center. The reassignment problem of certain VMs consists in moving or migrating them to other servers in order to shut down the initial servers hosting these VMs. We assume to have a set of VMs to be migrated, and noted by Tinit = {V M1 , V M2 , . . . V Mθ } with θ < N . Each VM in T is currently hosted by a set of servers noted by S = {S1 , S2 , . . . , Sκ } with κ < K. Thus, for sake of reducing the number of used servers (and their energy consumption), the reassignment problem consists in placing or hosting optimally θ VMs on κ available servers when using a minimal number of servers. Our problem is very similar to the well known NP-Hard problem of Bin-Packing in which VMs can be considered as items when the servers are the bins characterized by their power consumption. This allows us to construct in polynomial time an instance of the Bin-Packing problem and to deduce that our reassignment problem is also NP-Hard.
qi κ X X
lv zijv ≤ (Cj − Cj,Current ) (1 − yj )
(4)
i=1 v=1
4) Clean out source servers: qi κ X X
zijv = qi yi , ∀i = 1, . . . , κ, j 6= i
(5)
j=1 v=1
5) Lifetime migration constraints: zijv ∆tv ≥ T0 ,
(6)
where ∆tv = tv − CurrentT ime, CurrentT ime represents the current time of simulations, and T0 is the necessitated time to migrate VMs. This consolidation (reassignment) model allows to find optimal solutions as it guarantees the convergence to the optimum by exploring in a Branch and Bound manner all the feasible solutions. Nevertheless, this convergence can be time consuming for large problem instances, and we need scalable
312
algorithms that can find near-optimal/optimal solutions in few seconds. Thus, in the following we propose a heuristic approach to reassign VMs in negligible times to efficiently reduce energy consumption. C. b-Matching Formulation VMs reassignment resorts to consolidation by moving resources between available servers to maintain optimal energy resource consumption when dynamic changes are significant to require an adaptation. Indeed, we need to minimize servers energy consumption in a dynamic manner by investigating scalable and online solutions to repack VMs and shut down unused servers. We consider optimization techniques based on the theory of b-Matching that will be defined in the sequel. A repacking solution based on CPU available resources on servers can be found in [8]. Thus, we define Mvi as the migration cost to be considered if our optimization recommends to migrate a VM v to a server i. Two cases can be considered as follows: • •
The VM v is currently on server i: Then the migration cost Mvi = 0; The VM v is not currently on server i: This leads to consider migration costs Mvi > 0;
Based on this configuration, we construct a new bi-partite graph noted by G = (V1 ∪ V2 , E) where V1 is the set of vertices representing selected virtual machines to migrate and V2 is the set of servers hosting these VMs. E represents the set of weighted edges constructed as follows (see Figure 2 for more details): 1) if VM v is actually running on server i, then the edge (v, i) has a weight w(v,i) = l(v,i) , which represents energy consumption of VM v in server i. 2) if VM v is hosted in server i0 6= i, then we define a weight w(v,i) = l(v,i) + M(v,i) which considers energy consumption of VM v added to migration costs due to moving VM v from i0 to i.
cording to [9], we give the following definition of the bMatching problem : Definition Let G be an undirected graph with integral edge capacities: u : E(G) → N ∪ ∞ and numbers b : V (G) → N. Then a b-matching in G is a function f : E(G) → N with P f (e) ≤ u(e), ∀e ∈ E(G), and e∈δ(v) f (e) ≤ b(v) for all v ∈ V(G). where δ(v) represents the set of incident edges of v. From the definition, finding a minimum weight b-matching in a graph G can be solved in polynomial time since the full description of its convex hull is given in [9]. According to this definition, we propose the following result: Proposition 3.1: Let G = (V1 ∪ V2 , E) be a weighted complete bipartite graph built as described in Figure 2. Then, finding an optimal VM reassignment solution is equivalent to an incapacitated (u ≡ ∞) minimum weight b-matching solution, where b(v) v ∈ V1 (v is a VM) and n l = 1 if mo b(v) = min |V1 |; P Cv lI(e) if v ∈ V2 . e∈δ(v)
where I(e) represents the initial extremity of the edge e. In other words, solving the b-matching problem with the characterized parameters is equivalent to polynomially solve the reassignment problem. Nevertheless, some additional constraints will be added to completely describe the reassignment problem requirements. We start by setting the objective function according to the described costs (migration costs and power consumption). The objective is given as follows: X min ObjbM atching = (le + Me 1ij )xe (7) e∈E,e=(v,j)
1, if V Mv is not currently hosted in server j; 0, elsewhere. We define valid inequalities to address some required and useful constraints of the reassignment problem. For instance, all VMs should be considered to a reassignment, and each VM will be assigned to exactly one server. This is represented by formula (8): X xe = 1, ∀v ∈ V1 (8) where 1vj =
e∈δ(v)
Each server s has a power limit expressed by the upper bound given by formula (9) : X xe ≤ b(s), ∀s ∈ V2 (9) e∈δ(s)
Fig. 2: Bipartite graph construction At this stage, we introduce the minimum weight b-matching problem to be assimilated to the reassignment problem. Ac-
Using the b-Matching model with the described valid inequalities enables us to use the convex hull formulation of the b-matching and makes the reassignment problem easier to be solved. Thus, in order to get integer and optimal solution of the
313
problem, we add blossom inequalities given by the following: P X v∈A bv + |F | xe + x(F ) ≤ , ∀A ∈ V1 ∪ V2 , 2
optimal solutions compared to those provided by the exact algorithm (ILP). V. F UTURE W ORK
e∈E(G(A))
(10) P where P F ⊆ δ(A) and b + |F | is odd, and v v∈A δ(A) = i∈A,j∈A x(ij) . E(G(A)) represents a subset of edges of the subgraph G(A) generated by a subset of vertices A. More details concerning blossom inequalities as in formula (10) can be found in [10] for example.
Two approaches to solve VMs reassignment in cloud data centers in the presence of energy consumption constraints were presented and compared. An exact algorithm based on Integer Linear Programming approach is proposed to cope with small and practical problem instances. This exact approach guarantees the convergence to the optimal solution but suffers from scalability issues. Thus, to deal with the scalability problem and to treat large problem instances we proposed a heuristic approach based on the b-Matching theory to explore efficiently the space of all available solutions and then converge to near-optimal/optimal solutions in few seconds.
Based on the bipartite graph G, and according to all the defined constraints, we constructed a linear reduction of the resource reassignment problem to the b-matching problem. Finally the mathematical model of the reassignment problem is given by the following: P min Z = e∈E,e=(i,j) (le + Me uij )xe Future work will explore further the combination of the S.T. P: methods (Integer Linear Programming and b-Matching) by x = 1, ∀v ∈ V1 ; Pe∈δ(v) e using the b-Matching method as an upper bound to be added to ∀v ∈ V2 ; e∈δ(v) xe ≤ b(v), jP k the exact formulation. This leads to accelerate time resolution P v∈A bv +|F | x + x(F ) ≤ , ∀A ∈ V1 ∪ V2 ;and to guarantee a better QoS. e e∈E(G(A)) 2 P F ⊆ δ(A), v∈A bv + |F | is odd ; ACKNOWLEDGMENT x e ∈ R+ , ∀e ∈ E; (11) This research work has been carried out in the framework of the Technological Research Institute SystemX, and therefore IV. A LGORITHMS C OMPARISON granted with public funds within the scope of the French Program ”Investissements d’Avenir”. In this Section, we discuss briefly a performance comparison between the ILP algorithm and the b-Matching approach R EFERENCES according to : time convergence and then scalability issues. [1] F. F. et al., “Energy-aware dynamic VM consolidation in cloud data Thus, in our work, and to solve rapidly the reassignment centers using ant colony system,” in 2014 IEEE 7th International Conference on Cloud Computing, Anchorage, AK, USA, June 27 - July problem, we established clearly an alternative approach 2, 2014, 2014, pp. 104–111. based on the b-Matching theory by exploiting a linear and [2] S. F. Piraghaj, A. V. Dastjerdi, R. N. Calheiros, and R. Buyya, “A polynomial reduction of the reassignment problem to the framework and algorithm for energy efficient container consolidation in cloud data centers,” in 2015 IEEE International Conference on Data b-Matching convex hull problem which is easy to solve in Science and Data Intensive Systems, Dec 2015, pp. 368–375. terms of algorithmic complexity. Moreover, the mathematical formulation of the reassignment problem given using the b-Matching theory leads to a linear programming model with real variables. This leads to attend optimal/near optimal solutions in an easy way (few seconds can be sufficient to solve large problem instances). In addition, it is well known that the necessitated convergence time of an ILP model can take hours or days for some large problem instances. This is not acceptable in a Cloud data resource management context, and an alternative approach is then necessarily. It is important to investigate numerical results to better show the importance of the b-Matching solution when benchmarked by the exact approach. We will assess performance of the two algorithms according to various criteria as: the number of used servers, the amount of consumed energy, the number of necessitated migrations, etc. These simulations will confirm the rapid convergence of the b-Matching approach to the
[3] E. Zola and A. J. Kassler, “Energy efficient virtual machine consolidation under uncertain input parameters for green data centers,” in 2015 IEEE 7th International Conference on Cloud Computing Technology and Science (CloudCom), Nov 2015, pp. 436–439. [4] I. Takouna, E. Alzaghoul, and C. Meinel, “Robust virtual machine consolidation for efficient energy and performance in virtualized data centers,” in Internet of Things (iThings), 2014 IEEE International Conference on, and Green Computing and Communications (GreenCom), IEEE and Cyber, Physical and Social Computing(CPSCom), IEEE, Sept 2014, pp. 470–477. [5] D. A. Alboaneen, B. Pranggono, and H. Tianfield, “Energy-aware virtual machine consolidation for cloud data centers,” in Utility and Cloud Computing (UCC), 2014 IEEE/ACM 7th International Conference on, Dec 2014, pp. 1010–1015. [6] C. Ghribi, M. Hadji, and D. Zeghlache, “Energy efficient vm scheduling for cloud data centers: Exact allocation and migration algorithms,” in Cluster, Cloud and Grid Computing (CCGrid), 2013 13th IEEE/ACM International Symposium on, May 2013, pp. 671–678. [7] https://www.vmware.com/products/capacity planner/overview, 2016. [8] M. Hadji and P. Labrogre, “A virtual machine repacking in clouds: Faster live migration algorithms,” ACM SIGCOMM, vol. in Proceedings, 2014. [9] B. Korte and J. Vygen, Combinatorial Optimization: Theory and Algorithms, 4th ed. Springer Publishing Company, Incorporated, 2007. [10] M. Gr¨otschel, L. Lovsz, and A. Shrijver, “Geometric algorithms and combinatorial optimization,” Springer, 1985.
314