An Optimization Problem in Adaptive Virtual Environments
Ananth I. Sundararaj
Manan Sanghi
Jack R. Lange
Peter A. Dinda
Prescience Lab
Department of Computer Science
Northwestern University
http://virtuoso.cs.northwestern.edu
2
Summary
• Virtual execution environments provide opportunities for dynamic adaptation
• Important components are– Resource monitoring and inference– Application independent adaptation mechanisms– Efficient adaptation algorithms
• Previously proposed simple heuristics– Significant scope for improvement
• In this work– Formalize the adaptation problem– Show that it is NP-hard– Propose future research directions
3
Outline• Virtual execution environments – An example• Virtuoso system – Introduction• Virtual networks
– Measurement and inference (VTTIF)– Adaptation mechanisms (VNET)
• Problem formalization• A special case of the adaptation problem• Analysis• Status • Summary
4
Aim
Grid Computing
New Paradigm
Traditional Paradigm
Deliver arbitrary amounts of computational power to perform distributed and parallel computations
Problem1:
Grid Computing using virtual machines
Problem2:
Solution
How to leverage them?
Virtual Machines What are they?
6b
6a
5
4
3b3a
2
1
Resource multiplexing using OS level mechanism
Complexity from resource user’s perspective
Complexity from resource owner’s perspective
Virtual Machine Grid Computing
5
Virtual Machines
Virtual machine monitors (VMMs)
•Raw machine is the abstraction
•VM represented by a single image
•VMware GSX Server
6
The Simplified Virtuoso Model
Orders a raw machine
User
Specific hardware and performance
Basic software installation available
User’s LAN
VM
Virtual networking ties the machine back to user’s home network
Virtuoso continuously monitors and adapts
7
Outline• Virtual execution environments – An example• Virtuoso system – Introduction• Virtual networks
– Measurement and inference– Adaptation mechanisms
• Problem formalization• A special case of the adaptation problem• Analysis• Status • Summary
8
User’s friendlyLAN
Foreign hostile LAN
Virtual Machine
VNET: A bridge with long wires
Host
Proxy
X
Virtual NetworksVM traffic going out on foreign LAN
IP network
A machine is suddenly plugged into a foreign network. What happens?
• Does it get an IP address?• Is it a routeable address?• Does firewall let its traffic through? To any port?
9
Measurement and Inference
Application (VTTIF)• Topology
• Traffic load
Underlying network layer Physical hosts
Virtual network layerVNET daemons
Application layerVM layer
Host and VM • Size and compute capacities
• Size and compute demands
• Topology
• Bandwidth
• Latency
Underlying network
[Gupta et al. LNCS 05]
[Gupta et al. In submission]
10
Adaptation Mechanisms
Resource reservation• Network
• CPU
Resource reservationPhysical hosts
Topology changesVNET daemons
VM MigrationVM layer
Topology changes • Overlay links
• Overlay forwarding rules
VM Migration• Third party migration schemes
X
XX
[Sundararaj et al. LCR 04, HPDC 05]
[Lange et al. HPDC 05]
[Lin et al. GRID 2004]
11
Outline• Virtual execution environments – An example• Virtuoso system – Introduction• Virtual networks
– Measurement and inference (VTTIF)– Adaptation mechanisms (VNET)
• Problem formalization• A special case of the adaptation problem• Analysis• Status • Summary
12
bw12
H3
H2
H1H4
VM1 VM2 b1 l1
VM1 VM3 b2 l2
VM2 VM3 b3 l3
VM3 VM1 b4 l4
A set of ordered 4-tuples, “A”
disi bi
Generic Adaptation Problem In Virtual Execution Environments (GAPVEE)
bw24
bw14
bw13
bw34
lat12
lat13
lat34
lat24
lat14compute4
compute1
compute2
compute3
size4size1
size2
size3
VM1
vm_compute1
vm_size1
VM2vm_compute2
vm_size2
VM3
vm_compute3
vm_size3
liA1
A2
A3
A4
Input:1.
2. 3.
13
Generic Adaptation Problem In Virtual Execution Environments
Output:
H3
H2
H1H4
VM1
vm_compute1
vm_size1
VM1
vm_compute3
vm_size3VM1
vm_compute2
vm_size2
map
ped
map
ped
mapped
A mapping from VMs to Hosts
• Size and compute demands of VMs must be met within host constraints
VM demands
compute4 size4
Host constraints
14
Generic Adaptation Problem In Virtual Execution Environments
Output:
H3
H2
H1H4
A mapping from 4-tuples to Paths
• Bandwidth and latency demands of 4-tuples must be met within constraints
compute4 size4
Host constraints
VM1 VM2 b1 l1
VM1 VM3 b2 l2
VM2 VM3 b3 l3
VM3 VM1 b4 l4
A set of ordered 4-tuples, “A”
disi bi liA1
A2
A3
A4
VM1
VM2 VM3
bw13
lat13
Hence
b1 + b2 <= bw13
l1 , l2 >= lat13
15
Generic Adaptation Problem In Virtual Execution Environments
Output:
H3
H2
H1H4
compute4 size4
Host constraints
VM1 VM2 b1 l1
VM1 VM3 b2 l2
VM2 VM3 b3 l3
VM3 VM1 b4 l4
A set of ordered 4-tuples, “A”
disi bi liA1
A2
A3
A4
VM1
VM2 VM3
bw13
lat13
H1
H3
bw13
A1 (b1)
A2 (b2)
bw13 – (b1+b2) is the residual capacity of the edge
Bottleneck bandwidth: min residual capacity along a path
16
Generic Adaptation Problem In Virtual Execution Environments
• Goal: – VMs to Hosts mapping
– Path to each 4-tuple
– Meeting all demands within constraints
– Such that• Sum of residual bottleneck bandwidth over
each mapped path is maximized
17
Optimizing Objective functions
• Many possibilities
• Maximizing sum of residual bottleneck bandwidths over each mapped path– Intuition:
• Leave the most room for application to increase performance
• Minimizing the residual bottleneck capacity– Intuition:
• Increase room for other applications to enter system
18
Outline• Virtual execution environments – An example• Virtuoso system – Introduction• Virtual networks
– Measurement and inference (VTTIF)– Adaptation mechanisms (VNET)
• Problem formalization• A special case of the adaptation problem• Analysis• Status • Summary
19
bw12
H3
H2
H1H4
H1 H3 b1
H1 H3 b2
H2 H3 b3
H3 H4 b4
A set of ordered 3-tuples, “A”
disi bi
Special Case of GAPVEE: Routing Problem In Virtual Execution Environments (RPVEE)
bw24
bw14
bw13
bw34
A1
A2
A3
A4
Input:1.
2.
20
Special Case of GAPVEE: Routing Problem In Virtual Execution Environments (RPVEE)
Output:
H3
H2
H1H4
A mapping from 3-tuples to Paths
• Bandwidth demands of 3-tuples must be met within constraints
•Sum of residual bottleneck bandwidth is maximized over each path
bw13
H1 H3 b1
H1 H3 b2
H2 H3 b3
H3 H4 b4
A set of ordered 3-tuples, “A”
disi bi
A1
A2
A3
A4
21
Analysis• Theorem 1: RPVEE is NP-hard
• Edge Disjoint Path Problem (EDPP)– Arbitrary instance of EDPP
– Convert to an instance of RPVEED
– A “Yes” solution for RPVEED implies a “Yes” solution for EDPP
– A “No” solution for RPVEED implies a “No” solution for EDPP
22
Edge Disjoint Path Problem (EDPP)
• A well known NP-complete problem• Input
– A graph G = (H,E)– A set of ordered 2-tuples S = {(si,di), where si, di
in H}
• Output– “Yes” if for all (si,di) in S, there exist edge
disjoint paths from si to di in G = (H,E)– “No” otherwise
23
Decision version of RPVEE (RPVEED)
• Input– A graph G = (H,E)– A function bw: E -> R– A set of ordered 3-tuples S = {(si,di,bi), where si, di
in H, bi in R, i = 1,…k}
• Output– “Yes” if for all (si,di,bi) in S, there exist paths from
si to di in G = (H,E), such that sum of bottleneck bandwidth = k*ε
– “No” otherwise
24
H3
H2
H1H4
1+ε
H3
H2
H1H4
1+ ε
1+ ε 1+ ε
1+ ε
1
11
1
1
1 1
H1 H2
H1 H4
H2 H4
H1 H3
A set of ordered 2-tuples
H1 H2 1
H1 H4 1
H2 H4 1
H1 H3 1
A set of ordered 3-tuples
si di
disi bi
Given an arbitrary instance of EDPP
Converted to a particular instance of RPVEED
A directed graph G = (H,E)
A complete directed graph G = (H,E)
A function bw : E -> R
25
Outline• Virtual execution environments – An example• Virtuoso system – Introduction• Virtual networks
– Measurement and inference (VTTIF)– Adaptation mechanisms (VNET)
• Problem formalization• A special case of the adaptation problem• Analysis• Status • Summary
26
Status• Previously developed a variety of heuristics
(Greedy and Simulated annealing)
• Effective in improving performance– Significant scope for improvement
• Formalization and analysis, first steps
• Generic incarnation hard, focus on special cases
• Currently researching the well studied variants of our problem (such as un-splittable flows)
27
Summary
• Virtual execution environments provide opportunities for dynamic adaptation
• Important components are– Resource monitoring and inference– Application independent adaptation mechanisms– Efficient adaptation algorithms
• Previously proposed simple heuristics– Significant scope for improvement
• In this work– Formalize the adaptation problem– Show that it is NP-hard– Propose future research directions
28
• For More Information– Prescience Lab (Northwestern University)
• http://plab.cs.northwestern.edu
– Virtuoso: Resource Management and Prediction for Distributed Computing using Virtual Machines
• http://virtuoso.cs.northwestern.edu
• VNET is publicly available from• http://virtuoso.cs.northwestern.edu