Unit-4 L-16 VS
Subject: - Cloud Computing
Unit: - Virtualization Technology
Unit: - 4
VIRTUAL CLUSTERS AND RESOURCE MANAGEMENT
A physical cluster is a collection of servers interconnected by a physical network
such as a LAN
Virtual clusters are built with VMs installed at distributed servers
Virtual clusters have VMs that are interconnected logically by a virtual network
across several physical networks.
We will study three critical design issues of virtual clusters:
1. Live migration of VMs
2. Memory and file migrations,
3. Dynamic deployment of virtual cluster
1. The different node colors in above diagram refer to different virtual clusters.
2. Three physical clusters are shown .
3. Four virtual clusters are created over the physical clusters.
4. The physical machines are also called host systems.
Cloud Computing (6CS4-06) Page 1
Unit-4 L-16 VS
5. In contrast, the VMs are guest systems.
6. The host and guest systems may run with different operating systems.
7. Each VM can be installed on a remote server or replicated on multiple servers belonging to the same or
different physical clusters.
8. The boundary of a virtual cluster can change as VM nodes are added, removed, or migrated dynamically
over time.
VMs in virtual cluster have the following interesting properties:
1. The virtual cluster nodes can be either physical or virtual machines. Multiple VMs running with different
OSes can be deployed on the same physical node.
2. A VM runs with a guest OS, which is often different from the host OS, that manages the resources in the
physical machine, where the VM is implemented.
3. The purpose of using VMs is to consolidate multiple functionalities on the same server. This will greatly
enhance server utilization and application flexibility.
4. VMs can be replicated in multiple servers for the purpose of promoting distributed parallelism, fault
tolerance, and disaster recovery.
5. The size (number of nodes) of a virtual cluster can grow or shrink dynamically.
6. The failure of any physical nodes may disable some VMs installed on the failing nodes. But the failure
of VMs will not pull down the host system.
Cloud Computing (6CS4-06) Page 2
Unit-4 L-16 VS
1. The concept of a virtual cluster based on application partitioning or customization.
2. The different colors in the figure represent the nodes in different virtual clusters.
3. As a large number of VM images might be present, the most important thing is to determine how to store
those images in the system efficiently.
4. There are common installations for most users or applications, such as operating systems or user-level
programming libraries.
5. These software packages can be preinstalled as templates (called template VMs).
6. With these templates, users can build their own software stacks.
7. New OS instances can be copied from the template VM.
8. User-specific components such as programming libraries and applications can be installed to those
instances.
Fast Deployment and Effective Scheduling:
Deployment means two things:
1. To construct and distribute software stacks (OS, libraries, applications) to a physical node inside clusters
as fast as possible
2. To quickly switch runtime environments from one user’s virtual cluster to another user’s virtual cluster.
If one user finishes using his system, the corresponding virtual cluster should shut down or suspend quickly
to save the resources to run other VMs for other users
The live migration of VMs allows workloads of one node to transfer to another node. The advantage of
virtualization is load balancing of applications in a virtual cluster. Load balancing can be achieved using
the load index and frequency of user logins. The automatic scale-up and scale-down mechanism of a virtual
cluster can be implemented based on this model. Consequently, we can increase the resource utilization of
nodes and shorten the response time of systems. Mapping VMs onto the most appropriate physical node
should promote performance. Dynamically adjusting loads among nodes by live migration of VMs is
desired, when the loads on cluster nodes become quite unbalanced.
High-Performance Virtual Storage
Cloud Computing (6CS4-06) Page 3
Unit-4 L-16 VS
The template VM can be distributed to several physical hosts in the cluster to customize the VMs.
The existing software packages reduce the time for customization as well as switching virtual
environments.
Basically, there are four steps to deploy a group of VMs onto a target cluster:
1. preparing the disk image,
2. configuring the VMs,
3. choosing the destination nodes,
4. and executing the VM deployment command on every host.
Many systems use templates to simplify the disk image preparation process.
A template is a disk image that includes a preinstalled operating system with or without certain
application software.
Users choose a proper template according to their requirements and make a duplicate of it as their
own disk image.
Templates could implement the COW (Copy on Write) format.
A new COW backup file is very small and easy to create and transfer.
Every VM is configured with a name, disk image, network setting, and allocated CPU and memory.
One needs to record each VM configuration into a file.
However, this method is inefficient when managing a large group of VMs.
VMs with the same configurations could use preedited profiles to simplify the process.
The system configures the VMs according to the chosen pro-file.
A strategy to choose the proper destination host for any VM is needed.
The deployment principle is to fulfill the VM requirement and to balance workloads among the
whole host network.
Live VM Migration Steps:
In a cluster built with mixed nodes of host and guest systems, the normal method of operation is to
run everything on the physical machine.
When a VM fails, its role could be replaced by another VM on a different node, as long as they both
run with the same guest OS.
The potential drawback is that a VM must stop playing its role if its residing host node fails.
However, this problem can be mitigated with VM life migration.
There are four ways to manage a virtual cluster.
1. Guest-based manager
2. Host-based manager
3. Independent cluster manager
Cloud Computing (6CS4-06) Page 4
Unit-4 L-16 VS
4. Integrated cluster
In case of failure, VMs can be live-migrated from one physical machine to another; one VM can be replaced
by another VM.
The major attraction of this scenario is that virtual clustering provides dynamic resources that can be quickly
put together upon user demand or after a node failure.
When a VM runs a live service, it is necessary to ensure that the migration occurs in a manner that minimizes
all three metrics:
1. Negligible downtime
2. The lowest network bandwidth consumption possible
3. A reasonable total migration time
4. Ensure that the migration will not disrupt other active services residing in the same host
A VM can be in one of the following four states:
1. An inactive state is defined by the virtualization platform, under which the VM is not enabled.
2. An active state refers to a VM that has been instantiated at the virtualization platform to perform a real task.
3. A paused state corresponds to a VM that has been instantiated but disabled to process a task or paused in a
waiting state.
4. A VM enters the suspended state if its machine file and virtual resources are stored back to the disk.
Cloud Computing (6CS4-06) Page 5
Unit-4 L-16 VS
Live migration of a VM from one machine to another consists of the following six steps:
Steps 0 and 1:
Start migration This step makes preparations for the migration, including determining the migrating VM and
the destination host
Steps 2:
Transfer memory Since the whole execution state of the VM is stored in memory, sending the VM’s memory
to the destination node ensures continuity of the service provided by the VM. All of the memory data is
transferred
Step 3:
Suspend the VM and copy the last portion of the data. The migrating VM’s execution is suspended when the
last round’s memory data is transferred. During this step, the VM is stopped and its applications will no longer
run. This “service unavailable” time is called the “downtime” of migration, which should be as short as
possible so that it can be negligible to users.
Steps 4 and 5:
Commit and activate the new host. After all the needed data is copied, on the destination host, the VM reloads
the states and recovers the execution of programs in it, and the service provided by this VM continues. Then
Cloud Computing (6CS4-06) Page 6
Unit-4 L-16 VS
the network connection is redirected to the new VM and the dependency to the source host is cleared. The
whole migration process finishes by removing the original VM from the source host.
Memory Migration
This is one of the most important aspects of VM migration. Moving the memory instance of a VM from one
physical host to another. Memory migration can be in a range of hundreds of megabytes to a few gigabytes in a
typical system today, and it needs to be done in an efficient manner.
The Internet Suspend-Resume (ISR) technique exploits temporal locality as memory states are likely to have
considerable overlap in the suspended and the resumed instances of a VM.
Temporal locality refers to the fact that the memory states differ only by the amount of work done since a VM
was last suspended before being initiated for migration.
To exploit temporal locality, each file in the file system is represented as a tree of small subfiles. A copy of this
tree exists in both the suspended and resumed VM instances.
The advantage of using a tree-based representation of files is that the caching ensures the transmission of only
those files which have been changed.
The ISR technique deals with situations where the migration of live machines is not a necessity.
File System Migration
To support VM migration, a system must provide each VM with a consistent, location-independent view of the
file system that is available on all hosts.
A simple way to achieve this is to provide each VM with its own virtual disk which the file system is mapped
to and transport the contents of this virtual disk along with the other states of the VM.
However, due to the current trend of high-capacity disks, migration of the contents of an entire disk over a
network is not a viable solution.
Another way is to have a global file system across all machines where a VM could be located. This way
removes the need to copy files from one machine to another because all files are network-accessible.
A distributed file system is used in ISR serving as a transport mechanism.
The VMM only accesses its local file system.
The relevant VM files are explicitly copied into the local file system for a resume operation and taken out of
the local file system for a suspend operation.
File System Migration
This approach relieves developers from the complexities of implementing several different file system calls for
different distributed file systems.
It also essentially disassociates the VMM from any particular distributed file system semantics.
However, this decoupling means that the VMM has to store the contents of each VM’s virtual disks in its local
files, which have to be moved around with the other state information of that VM.
Cloud Computing (6CS4-06) Page 7