Sunday, December 14, 2014

What is KVM virtualization?



KVM(Kernel Virtual machine) is an inbuilt virtualization software available in Linux(Have to select it when installing OS Or can be installed when ever its required). Up to recent years virtualization software are installed as stand alone software in Linux. But to make things more reliable, fast and virtualization is becoming a part of Kernel activities, this software is bundled along Linux OS which can be installed as a part of Kernel. There are many advantages of this KVM when compared to other virtualization software’s available in Linux.
  • Can interact directly with the Kernel
  • Default virtualization in leading Linux Distributions
  • One of the Linux software developed aggressively.
  • Almost becoming competitor to VMware by implementing technologies such as v2v, p2v, and many open source tools to manage VM’s
  • Number of open source cloud automation software’s use KVM as default hyperviser.
How KVM virtualization works?
Once we install KVM on a Linux box a hardware file /dev/kvm is created which will act as interpreter between actual hardware and hypervisor manager Virt-manager). When ever a request for hardware changes/additions comes from hypervisor manager, your  KVM software starts allocating those resources virtually by interacting with real hardware. Suppose we want to change RAM on a virtual machine, this is communicated by your hypervisor manager to KVM for allocating the resource. Then KVM interacts with hardware and reserves that RAM from real RAM for that particular VM. This happens for the other resources as well. To make it simple I did not explain the concept of ballooning and other things.


(KVM)Virtualization terminology
VT(Virtualization Technology) enabled: If a hardware supports virtualization directly without any third-party software to simulate then that hardware is called as VT enabled processor. This is denoted by VTx in Intel processors and AMD-v For AMD processors. So if you want to install KVM on your machine your processor should support one of them.

Guest OS: Guest OS is the OS you are going to install on a Virtual machine which guest to the Host/base OS. You can install number of guest Operating systems on a host machine.

HOST OS: This is the OS where you are going to install your hypervisor software like KVM and virtual manager etc. This base OS so that you hypervisor start running as KVM is not an OS it should run on a OS to get things done.

Hyperviser: Hyperviser is a software which will help us in implementing virtualization. KVM, Vmware ESX and Xen are some examples of Hypervisors.

Virtual machine: Virtual machine is a virtual hardware allocated by Hypervisor for installing Guest OS on it so that it can run as separate machine.

libvirt: A toolkit to interact with the virtualization capabilities of recent versions of Linux (and other OSes). This is a building block to KVM.

virsh(Virtualization Shell): Virsh is a shell for managing hypervisors and VM’s directly from Host OS terminal. We cover this virsh extensively in our coming posts.

Cloning: Cloning is a concept to replicate a VM state/data etc so that we no need to install a new OS. After cloning we can use the cloned machine as we use normal VM.

p2v: This type of converting a machine from one state to other. In this we can convert a physical machine to virtual machine to consolidate a hardware machine.

v2v: This is the concept of migrating virtual machine to other virtual machine at the time of maintenance etc.

Hyper-threading(HT): This is Intel’s proprietary simultaneous multithreading (SMT) implementation used to improve parallelization of computations (doing multiple tasks at once) performed on PC microprocessors.

Overcommit: This is concept of committing resource more than available at HOST OS resources such as RAM, CPU and harddisk. We should be very much cautious when dealing with over commit.




No comments:

Post a Comment