Dynamic Virtual Machine Management via Approximate Markov Decision Process

Zhenhua Han, Haisheng Tan, Guihai Chen, Rui Wang, Yifan Chen, Francis C. M. Lau

This paper presents MadVM, a novel framework for dynamic virtual machine (VM) management in data centers. By modeling VM allocation as a large-scale Markov Decision Process (MDP), the authors move beyond simple heuristics to provide a mathematically grounded approach that balances energy efficiency with resource availability.

TL;DR

MadVM uses an approximate Markov Decision Process to dynamically manage virtual machine placement, reducing data center energy consumption by up to 47% compared to state-of-the-art heuristics. By decomposing a complex global optimization problem into per-VM utility functions, it provides theoretical performance guarantees and supports distributed implementation in large-scale systems.

What Problem Does This Paper Address?

Data centers are massive energy consumers, and virtualization is a key tool for efficiency. By consolidating multiple VMs onto a single physical machine (PM), operators can power down underutilized servers. However, VM resource demands (like CPU usage) are highly dynamic.

Existing solutions generally fall into two camps:

  1. Static Approaches: Treat demands as constant, leading to poor resource utilization.
  2. Heuristic Dynamic Approaches: Use "rules of thumb" to migrate VMs when servers become overloaded. These often lack theoretical guarantees, struggle with the "curse of dimensionality" in large systems, and rely on centralized controllers that represent a single point of failure.

The authors seek a management policy that is proactive rather than reactive, theoretically sound, and computationally feasible for thousands of VMs.

Methods

The authors formulate the problem as an infinite horizon average MDP. The goal is to minimize a long-term average cost function that weights two factors: total power consumption and resource shortage (SLA violations).

The "MadVM" Approach:

  • Markov Modeling: They model VM CPU demands as a finite-state stationary Markov chain. Analysis of real-world traces (see Figure 2) justifies this, showing that transition probabilities are "quasi-static"—stable enough over several days to be predictable.
  • Linear Utility Approximation: To solve the "curse of dimensionality," they approximate the global utility function as a linear sum of per-VM utility functions. This reduces the state space from exponential to polynomial.
  • Feature States: Instead of tracking every VM's exact state, each VM makes decisions based on its own state and the "feature state" (expected demand) of others.
  • Distributed Implementation: The algorithm can be implemented as a distributed auction. Each VM calculates its own "control utility" locally and submits it to a manager. The manager then selects the top $T_m$ VMs for migration based on these bids.

![Fig.

  1. Illustration of convergence: Per-VM utility function versus the number of iterations.](/figures/art_081d0db7be4b4e5f8e6aaeee66090d39)

Datasets

The authors evaluated MadVM using two prominent real-world workload traces:

  1. Google Cluster Data: A 26-day trace representing a large-scale industrial environment.
  2. PlanetLab: A trace characterized by more intensely fluctuating resource demands, used to test the algorithm's robustness under high volatility.

Key Insights and Ideas

  • Proactive vs. Reactive: Unlike heuristics that trigger migrations only when a resource shortage occurs, MadVM views migration as a continuous optimization tool. It may migrate a VM even if there is no immediate shortage if doing so improves long-term energy efficiency.
  • Temporal Correlation Matters: The paper demonstrates that CPU demands are not random; they have strong temporal correlations. Capturing these via Markov chains allows the system to "look ahead" and avoid future shortages.
  • Decomposition is Key: The most significant "aha moment" is that a global optimization problem can be effectively approximated by letting VMs optimize their local utility functions using limited global "feature" information.

Key Results

In simulations against two baselines—CloudScale (a well-known predictive heuristic) and CompVM (a recent pattern-matching approach)—MadVM showed superior performance:

  • Energy Savings: MadVM reduced power consumption by an average of 19% compared to CompVM and 42% compared to CloudScale while maintaining near-zero resource shortages.
  • Resource Utilization: MadVM consistently used fewer physical servers to host the same workload (see Figure 4b).
  • Robustness to Volatility: In the highly fluctuating PlanetLab trace, MadVM actually required fewer migrations than the baselines to maintain the same service level, proving it makes "smarter" moves.
  • Shortage Mitigation: When physical resources were intentionally limited, MadVM's resource shortage was 34% lower than the baselines because it could better predict and avoid "panic" situations.
Fig. 4b. Average number of PMs used in the Google Cluster Trace.

Limitations and Future Work

  • Resource Dimensions: The current study focuses primarily on CPU time. While the authors note the state space $Q$ can be extended to include memory and network bandwidth, they did not provide experimental results for multi-resource scenarios.
  • Migration Overhead: While the number of migrations is constrained, the specific energy and latency costs of the migration process itself are not explicitly part of the MDP's cost function.
  • Future Directions: The authors suggest moving toward a "joint multi-level optimization" that integrates VM allocation with lower-level hardware tasks like CPU scheduling.

For more details, see the full paper: "Dynamic Virtual Machine Management via Approximate Markov Decision Process" by Han et al.

Summary updated

BibTeX
@inproceedings{han2016dynamic,
  author = {Zhenhua Han and Haisheng Tan and Guihai Chen and Rui Wang and Yifan Chen and Francis C. M. Lau},
  title = {{Dynamic Virtual Machine Management via Approximate Markov Decision Process}},
  booktitle = {INFOCOM},
  year = {2016},
  doi = {10.1109/infocom.2016.7524384},
}
Figure