Virtual Machines Flashcards
Virtual Machine
A virtual machine is a software program or operating system that not only exhibits the behaviour of a separate computer but is also capable of performing tasks such as running and programs like a separate computer.
Virtualisations
Virtualisation is an abstraction layer that decouples the physical hardware from operating system to deliver greater IT resource utilisation and flexibility
It allows multiple virtual machines with different operating systems to run in isolation, side by side on the same physical machine
Virtual Machines
Very bottom we have the hardware – the machine that running the software
OS – installed on the machine
Then the virtual machine itself – you could have a different machine for different OS
Then you have Windows, Linux, Mac OS
A software implementation of a workstation executing programs like a physical workstation
Supports the implementation and execution of a complete operating system
Multiple OS environments can co-exist on the same hard drive and run simultaneously
Emulate hardware environments
Virtual Machine Basics
The VM sits between the machine and conventional OS
The virtualisation process involves:
Mapping of virtual resources to the actual hardware resources
Using the actual machine instructions to carry out the actions specified by the virtual machine instructions
Brief History of Virtual Machines
First appeared in IBM mainframe computers in 1972
Divided a mainframe computer into multiple virtual machines
Allowed multiple users to share a batch-oriented system and run multiple OS or software on the machine
Formal definition of virtualization helped move it beyond IBM.
A virtual Machine provides an environment for programs that is essentially identical to the original machine
Programs running within that environment show only a minor performance decrease
The virtual machine is in complete control of system resources
In late 90s, computer hardware was fast enough to allow virtualisation for general purposes on normal PCs
Xen, VMWare, VirtualBox
Implementation of VMM’s
Type 1 hypervisors:
Operating-system-like software built to provide virtualisation
These hypervisors run directly on the host’s hardware to control the hardware and to manage guest operating systems
VMware ESX, Joyent SmartOS, and Citrix XenServer
Also includes general-purpose operating systems that provide standard functions as well as VMM functions
Microsoft Windows Server with HyperV, RedHat Linux with KVM
You cannot use this for normal type of computing
Businesses would set this up, purposefully this type of virtual machine so that they can run machines on several different types of OS
Implementations of VMM’S
Type 2 hypervisors:
Applications that run on standard operating systems but provide VMM features to guest operation systems
VMware Workstation and Fusion, Parallels Desktop, and Oracle VirtualBox
Additional Variations
Paravirtualisation
Technique in which the guest OS is tailored to work in cooperation with the VMM to optimize performance
Programming environment virtualisation:
VMMs do not virtualise real hardware but instead create an optimised virtual system – i.e. Java and .NET framework
Emulators:
Allows applications written for one hardware environment to run on a very different hardware environment such as different type of CPU.
Application containment:
Not virtualisation – provides virtualisation- like features by segregating applications from the operating system, making them more secure, manageable
VM Advantages
OS availability
Cross platform compatibility
Flexibility
Scalability
Allocation of resources
Disaster Recovery
Increase Security
Enhance Performance
Simplify software migration
Cloning
Reducing dependency on additional hardware
Legacy code on non-legacy hardware
VM Disadvantages
Less efficient
Sharing resources / Performance drop
RAM and network performance reduction
Unstable performance
Not that efficient as a real machine when accessing the hardware
System/Process Virtual Machines
Can view virtual machine as: System Virtual Machine
Basically designed to support a complete system platform
Full execution environment that can support multiple processes (i.e. VMware, Xen).
Support I/O devices
Support GUI
Process virtual machine:
Process virtual machines are designed to execute computer programs in a platform-independent environment
Virtual machines can be instantiated for a single program (i.e. Java VM, .NET VM)
Virtual machine terminates when process terminates
Process Virtual Machine example: Java
Sun Microsystems in 1995
“Write once, run anywhere”
Includes:
Language specification (Java)
API library
Java virtual machine
Main Tasks:
Search and locate the required files
Convert byte code into executable code
Allocate memory into RAM
Code execution
Delete the execution code
Process Virtual Machine other examples
• Wine ( recursive acronym for Wine is not an Emulator)
Free open-source compatibility layer
Allows computer programs developed for Microsoft Windows to run on Unix-like operating systems
CrossOver
Microsoft Windows compatibility layer
Enables many Windows-based applications to run on Linux operating systems; macOS or chrome OS
Commercial license
PlayOnLinux & PlayOnMac
Graphical front-end for Wine compatibility layer
Simplifies the installation of Windows apps (esp.games) on GNU/Linux and Mac OS respectively.
It provides a wrapper shell scripts to specify the configuration of Wine
System Virtual Machine example - Vmware
Vmware Workstation runs on any computer
Provides a VM environment for many users
Type 2 VM.
Runs as application and is installed on the host operating system
Support popular OS and can do it concurrently so side by side
Concurreny as (resources allow)
Virtualization layer
Configure guest OS with is own virtual CPUs, memory, disk drives, network interfaces, etc.
Works with both Physical/ Virtual Disk Support
Common Use of Virtual Machine
Run legacy software on non-legacy hardware – means old software on hardware that is more modern
Run multiple operating systems on the same hardware
Create a manageable upgrade path
Security
Cost Reduction – Consolidation
Test and Development
Enterprise Desktop – a lot of organisations use it as their main desktop within their business