A Virtual Machine Repacking in Clouds: Faster Live ...

23 downloads 40450 Views 203KB Size Report
improve utilization and find the best tradeoffs between these ... by a server k. The hosting of V Mi ... if our optimization recommends to move V Mi from server.

A Virtual Machine Repacking in Clouds: Faster Live Migration Algorithms ∗

Makhlouf Hadji


Technological Research Institute SystemX 8, Avenue de la Vauve 91120, Palaiseau, France

Technological Research Institute SystemX 8, Avenue de la Vauve 91120, Palaiseau, France

[email protected]

[email protected]


This paper focuses on optimal VM repacking algorithms in physical infrastructures of Clouds to reduce overall cost and improve utilization and find the best tradeoffs between these conflicting goals. We investigate algorithms that scale well, minimize SLA violations, converge reasonably fast and provide the best possible tradeoffs between the number of used servers and migrations. These goals lead us to b-matching algorithms and a greedy algorithm resolution of a graphic matroid representation [2] of the repacking problem. A traditional Bin-Packing algorithm [1] is used for comparison and benchmarks since it provides an upper bound on performance, but it does not scale with problem size.


Paul Labrogere


We start the repacking problem from an initial VM placement solution and search for an optimal consolidation (minimal amount of used resources) via migrations of virtual resources in the physical infrastructure. This also provides the opportunity of shutting down emptied hosts to reduce energy consumption whenever appropriate.


b−Matching formulation The VMs’ placement needs to be dynamically updated to remain optimal. This is also needed to minimize hosting costs, energy consumption and operations costs. We focus in this paper on east-west migrations (i.e. horizontal elasticity) in a system of already instantiated VMs on a physical infrastructure. We consider a hosting cost, noted by He = Hik , when a V Mi is currently hosted by a server k. The hosting of V Mi by server k is represented as an edge e = (i, k). Furthermore, if our optimization recommends to move V Mi from server k0 to another server k, we include a reconfiguration cost Re = Rik . Based on this configuration, one can construct a new weighted bipartite graph G = (V ∪ S, E), where V is the set of vertices representing virtual machines actually hosted, and S is the set of all available servers. E is the set of weighted edges between V and S. We associate to each edge e = (i, k), a decision variable xe = 1 if V Mi will

Permission to make digital or hard copies of part or all of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage, and that copies bear this notice and the full citation on the first page. Copyrights for third-party components of this work must be honored. For all other uses, contact the owner/author(s). Copyright is held by the author/owner(s). DCC’14, August 18, 2014, Chicago, Illinois, USA. ACM 978-1-4503-2992-7/14/08. http://dx.doi.org/10.1145/2627566.2627580.

be hosted by server k after reconfiguration (xe = 0 if not). We also consider resource limitation constraints in terms of maximum available CPU, . . . capacity in servers. We prove in this paper that finding an optimal VM repacking solution is equivalent to a minimum weight b-matching solution [1]. Thus, we propose the following mathematical model to solve the repacking problem: P min Z = e∈E,e=(i,j) (He + Re uij )xe S.T.P:   Pe∈δ(v) xe = 1,    e∈δ(v) xe ≤ b(v),  k jP P v∈A bv +|F | , xe + x(F ) ≤ e∈E(G(A)) 2  P     F ⊆ δ(A), v∈A bv + |F | is odd xe ∈ R+ ,

∀v ∈ V; ∀v ∈ S ; ∀A ∈ V ∪ S; ; ∀e ∈ E;

The b-matching solution leads to an optimal solution with negligible SLA violations defined as the percentage of overused servers (servers that run out of space) in terms of resources (CPU for example).


Graphic matroid and greedy algorithm

In addition to the exact linear program based on the bmatching approach, we propose a polynomial algorithm that can scale to thousands of VMs and servers without SLA violations. We propose a new algorithm that solves the repacking problem based on matroid theory. Thus, we prove that if F = {I ⊆ E, I is a forest of trees} then M = (E, F) is a matroid. This allows to construct a greedy algorithm of the repacking problem without SLA violations. The algorithms are compared in terms of convergence times to find their respective solutions. The found results show clearly the known scalability problem of the Bin-Packing algorithm. Our algorithms, b-matching and greedy find optimal and perform much better in terms of convergence time-optimality tradeoff. The greedy solution has comparable convergence speed for up to 1000 VMs hosted in 200, 400 and 700 servers. The greedy algorithm has lower convergence times (order of minutes) beyond these values but remains valuable since it always finds the optimal solution with no SLA violation. The b-matching algorithm provides the best tradeoff between convergence time, optimality, scalability and cost. It converges in few seconds for large instances of the problem (scenario with 3000 VMs and 900 servers in 3.2s compared to 10mn of greedy and the times exceeding 4 hours of Bin-Packing).



[1] B. Korte and J. Vygen. Combinatorial optimization: theory and algorithms. Springer, 2001. [2] J. Oxley. Matroid Theory. Oxford University Press, 1992.

Suggest Documents