CLOUD COMPUTING TECHNIQUES -This course will enable the students to learn the concept of cloud computing and its various issues, emergence of cloud as the next generation computing paradigm and to set up a private cloud. Unit 2 -

PreethaV16 12 views 97 slides Mar 12, 2025
Slide 1
Slide 1 of 97
Slide 1
1
Slide 2
2
Slide 3
3
Slide 4
4
Slide 5
5
Slide 6
6
Slide 7
7
Slide 8
8
Slide 9
9
Slide 10
10
Slide 11
11
Slide 12
12
Slide 13
13
Slide 14
14
Slide 15
15
Slide 16
16
Slide 17
17
Slide 18
18
Slide 19
19
Slide 20
20
Slide 21
21
Slide 22
22
Slide 23
23
Slide 24
24
Slide 25
25
Slide 26
26
Slide 27
27
Slide 28
28
Slide 29
29
Slide 30
30
Slide 31
31
Slide 32
32
Slide 33
33
Slide 34
34
Slide 35
35
Slide 36
36
Slide 37
37
Slide 38
38
Slide 39
39
Slide 40
40
Slide 41
41
Slide 42
42
Slide 43
43
Slide 44
44
Slide 45
45
Slide 46
46
Slide 47
47
Slide 48
48
Slide 49
49
Slide 50
50
Slide 51
51
Slide 52
52
Slide 53
53
Slide 54
54
Slide 55
55
Slide 56
56
Slide 57
57
Slide 58
58
Slide 59
59
Slide 60
60
Slide 61
61
Slide 62
62
Slide 63
63
Slide 64
64
Slide 65
65
Slide 66
66
Slide 67
67
Slide 68
68
Slide 69
69
Slide 70
70
Slide 71
71
Slide 72
72
Slide 73
73
Slide 74
74
Slide 75
75
Slide 76
76
Slide 77
77
Slide 78
78
Slide 79
79
Slide 80
80
Slide 81
81
Slide 82
82
Slide 83
83
Slide 84
84
Slide 85
85
Slide 86
86
Slide 87
87
Slide 88
88
Slide 89
89
Slide 90
90
Slide 91
91
Slide 92
92
Slide 93
93
Slide 94
94
Slide 95
95
Slide 96
96
Slide 97
97

About This Presentation

Data Center Technology - Virtualization - Characteristics of Virtualized Environments – Taxonomy of Virtualization Techniques – Virtualization and Cloud Computing – Pros and Cons of Virtualization - Implementation Levels of Virtualization - Tools and Mechanisms: Xen, VMWare, Microsoft Hyper-V.


Slide Content

20CS016 - CLOUD COMPUTING TECHNIQUES Unit - 2 Virtualization Data Center Technology - Virtualization - Characteristics of Virtualized Environments – Taxonomy of Virtualization Techniques – Virtualization and Cloud Computing – Pros and Cons of Virtualization - Implementation Levels of Virtualization - Tools and Mechanisms: Xen, VMWare, Microsoft Hyper-V.

CHARACTERISTICS OF VIRTUALISATION 1. Increased Security –  The ability to control the execution of a guest program in a completely transparent manner opens new possibilities for delivering a secure, controlled execution environment. All the operations of the guest programs are generally performed against the virtual machine, which then translates and applies them to the host programs.  A virtual machine manager can control and filter the activity of the guest programs, thus preventing some harmful operations from being performed. Resources exposed by the host can then be hidden or simply protected from the guest. Increased security is a requirement when dealing with untrusted code.  Example-1:  Untrusted code can be analyzed in Cuckoo sandboxes environment.  The term sandbox identifies an isolated execution environment where instructions can be filtered and blocked before being translated and executed in the real execution environment.  Example-2:  The expression sandboxed version of the Java Virtual Machine (JVM) refers to a particular configuration of the JVM where, by means of security policy, instructions that are considered potentially harmful can be blocked. 

2. Managed Execution –  In particular, sharing, aggregation, emulation, and isolation are the most relevant features.  3. Sharing –  Virtualization allows the creation of a separate computing environment within the same host. This basic feature is used to reduce the number of active servers and limit power consumption.   4. Aggregation –  It is possible to share physical resources among several guests, but virtualization also allows aggregation, which is the opposite process. A group of separate hosts can be tied together and represented to guests as a single virtual host. This functionality is implemented with cluster management software, which harnesses the physical resources of a homogeneous group of machines and represents them as a single resource. 

5. Emulation –  Guest programs are executed within an environment that is controlled by the virtualization layer, which ultimately is a program. Also, a completely different environment with respect to the host can be emulated, thus allowing the execution of guest programs requiring specific characteristics that are not present in the physical host.   6. Isolation –  Virtualization allows providing guests—whether they are operating systems, applications, or other entities—with a completely separate environment, in which they are executed. The guest program performs its activity by interacting with an abstraction layer, which provides access to the underlying resources. The virtual machine can filter the activity of the guest and prevent harmful operations against the host.  Besides these characteristics, another important capability enabled by virtualization is performance tuning. This feature is a reality at present, given the considerable advances in hardware and software supporting virtualization. It becomes easier to control the performance of the guest by finely tuning the properties of the resources exposed through the virtual environment. This capability provides a means to effectively implement a quality-of-service ( QoS ) infrastructure. 

7. Portability –  The concept of portability applies in different ways according to the specific type of virtualization considered. In the case of a hardware virtualization solution, the guest is packaged into a virtual image that, in most cases, can be safely moved and executed on top of different virtual machines.  In the case of programming-level virtualization, as implemented by the JVM or the .NET runtime, the binary code representing application components (jars or assemblies) can run without any recompilation on any implementation of the corresponding virtual machine. 

8.Resource sharing:  Virtualization allows multiple virtual machines to share the resources of a single physical machine, such as CPU, memory, storage, and network bandwidth. This improves hardware utilization and reduces the need for additional physical servers. 9.Flexibility:  Virtualization allows IT administrators to quickly and easily create, modify, or delete virtual machines as needed, without the need to purchase and configure additional physical hardware. 10.Hardware independence:  Virtual machines are hardware-independent, which means they can run on different types of physical hardware and can be easily moved between physical servers without needing to reconfigure the virtual machine.

11.Scalability:  Virtualization allows organizations to scale their computing resources up or down as needed, depending on changing business requirements. 12.Management:  Virtualization provides centralized management tools that allow IT administrators to monitor and manage multiple virtual machines from a single console, making it easier to troubleshoot and maintain the virtualized environment. virtualization provides a powerful and flexible technology that can help organizations maximize their hardware utilization, improve their IT infrastructure scalability, and simplify their IT management. 13.Disaster Recovery: Virtualization enables organizations to implement disaster recovery solutions more easily and cost-effectively. By replicating virtual machines to remote sites, organizations can quickly recover from a disaster and resume operations.

14.Testing and Development: Virtualization allows organizations to easily create test and development environments without the need for additional physical hardware. This enables developers to test new applications and configurations in a controlled environment before deploying them to production. 15.Energy Efficiency: Virtualization can help organizations reduce their energy consumption by consolidating multiple physical servers onto a single machine. This can result in lower electricity bills and a reduced carbon footprint. 16.Increased Uptime: Virtualization can help improve system uptime by enabling virtual machines to be migrated to different physical hosts in the event of a hardware failure. This can minimize downtime and prevent data loss.

17.Cost Savings: Virtualization can help organizations save money by reducing the need for additional physical hardware, lowering electricity bills, and streamlining IT operations. This can result in significant cost savings over time. 18.Improved Security Management: Virtualization can help organizations improve their security posture by isolating applications and workloads from each other. This can prevent security breaches from spreading to other parts of the environment and reduce the attack surface. 19 .Cloud Migration: Virtualization can be a stepping stone for organizations looking to migrate to the cloud. By virtualizing their existing infrastructure, organizations can make it easier to move workloads to the cloud and take advantage of cloud-based services.  

TAXONOMY OF VIRTUALISATION CLASSIFICATION/TYPES OF VIRTUALISATION

Emulation , in a software context, is  the use of an application program or device to imitate the behavior of another program or device . Common uses of emulation include: Running an operating system on a hardware platform for which it was not originally engineered . HL VMs are an important technology in cloud computing that enable the running of high-level programming languages in a virtualized environment, providing a layer of abstraction between the application and the underlying hardware, and allowing for portability and scalability of applications . Multiprogramming ,in which several programs run at the same time on a uniprocessor system. However, because there is only one processor, there is no true simultaneous execution of different programs .

Full virtualization is a virtualization technique used to provide a VME that completely simulates the underlying hardware . In this type of environment, any software capable of execution on the physical hardware can be run in the VM, and any OS supported by the underlying hardware can be run in each individual VM . Full virtualization offers the best isolation and security for virtual machines, and simplifies migration and portability as the same guest OS instance can run virtualized or on native hardware.  VMware's virtualization products and Microsoft Virtual Server are examples of full virtualization .

Overview of x86 Virtualization The term virtualization broadly describes the separation of a service request from the underlying physical delivery of that service. With x86 computer virtualization, a virtualization layer is added between the hardware and operating system as seen in Figure 2. This virtualization layer allows multiple operating system instances to run concurrently within virtual machines on a single computer, dynamically partitioning and sharing the available physical resources such as CPU, storage, memory and I/O devices. As desktop and server processing capacity has consistently increased year after year, virtualization has proved to be a powerful technology to simplify software development and testing, to enable server consolidation, and to enhance data center agility and business continuity .

For example, servers can now run in extremely fault tolerant configurations on virtual infrastructure 24x7x365 with no downtime needed for backups or hardware maintenance. VMware has customers with production servers that have been running without downtime for over three years. For industry standard x86 systems, virtualization approaches use either a hosted or a hypervisor architecture . A hosted architecture installs and runs the virtualization layer as an application on top of an operating system and supports the broadest range of hardware configurations . In contrast, a hypervisor (bare-metal) architecture installs the virtualization layer directly on a clean x86-based system . Since it has direct access to the hardware resources rather than going through an operating system, a hypervisor is more efficient than a hosted architecture and delivers greater scalability, robustness and performance. VMware Player, ACE, Workstation and Server employ a hosted architecture for flexibility.

To better understand the techniques employed for x86 virtualization, a brief background on the component parts is useful. The virtualization layer is the software responsible for hosting and managing all virtual machines on virtual machine monitors (VMMs ). As depicted in Figure 3, the virtualization layer is a hypervisor running directly on VMware Understanding Full Virtualization, Paravirtualization, and Hardware Assist Virtualization 3 Figure 4 – x86 privilege level architecture without virtualization the hardware. The functionality of the hypervisor varies greatly based on architecture and implementation . Each VMM running on the hypervisor implements the virtual machine hardware abstraction and is responsible for running a guest OS. Each VMM has to partition and share the CPU, memory and I/O devices to successfully virtualize the system.

The Challenges of x86 Hardware Virtualization X86 operating systems are designed to run directly on the bare-metal hardware, so they naturally assume they fully ‘own’ the computer hardware. As shown in Figure 4, the x86 architecture offers four levels of privilege known as Ring 0, 1, 2 and 3 to operating systems and applications to manage access to the computer hardware. While user level applications typically run in Ring 3, the operating system needs to have direct access to the memory and hardware and must execute its privileged instructions in Ring 0 . Virtualizing the x86 architecture requires placing a virtualization layer under the operating system (which expects to be in the most privileged Ring 0) to create and manage the virtual machines that deliver shared resources. Further complicating the situation, some sensitive instructions can’t effectively be virtualized as they have different semantics when they are not executed in Ring 0. The difficulty in trapping and translating these sensitive and privileged instruction requests at runtime was the challenge that originally made x86 architecture virtualization look impossible

Three alternative techniques now exist for handling sensitive and privileged instructions to virtualize the CPU on the x86 architecture: • Full virtualization using binary translation • OS assisted virtualization or paravirtualization • Hardware assisted virtualization (first generation ) VMware can virtualize any x86 operating system using a combination of binary translation and direct execution techniques . This approach, depicted in Figure 5, translates kernel code to replace nonvirtualizable instructions with new sequences of instructions that have the intended effect on the virtual hardware . Meanwhile, user level code is directly executed on the processor for high performance virtualization . Each virtual machine monitor provides each Virtual Machine with all the services of the physical system, including a virtual BIOS ,(( BIOS (basic input/output system) is the program a computer's microprocessor uses to start the computer system after it is powered on. It also manages data flow between the computer's operating system (OS) and attached devices, such as the hard disk, video adapter, keyboard, mouse and printer. )) virtual devices and virtualized memory management . This combination of binary translation and direct execution provides Full Virtualization as the guest OS is fully abstracted (completely decoupled) from the underlying hardware by the virtualization layer . The guest OS is not aware it is being virtualized and requires no modification. Full virtualization is the only option that requires no hardware assist or operating system assist to virtualize sensitive and privileged instructions.

The hypervisor translates all operating system instructions and caches the results for future use, while user level instructions run unmodified at native speed . Full virtualization offers the best isolation and security for virtual machines, and simplifies migration and portability as the same guest OS instance can run virtualized or on native hardware . VMware’s virtualization products and Microsoft Virtual Server are examples of full virtualization. Para virtualisation Paravirtualization is a type of virtualization where software instructions from the guest operating system running inside a virtual machine can use “hypercalls” that communicate directly with the hypervisor . The hypervisor provides a calling mechanism for guests. Such calls are referred to as hypercalls. Each hypercall defines a set of input and/or output parameters. These parameters are specified in terms of a memory-based data structure.

Para virtualisation “ Para-“ is an English affix of Greek origin that means "beside," "with," or "alongside.” Given the meaning “alongside virtualization,” paravirtualization refers to communication between the guest OS and the hypervisor to improve performance and efficiency. Paravirtualization, as shown in Figure 6, involves modifying the OS kernel to replace nonvirtualizable instructions with hypercalls that communicate directly with the virtualization layer hypervisor. The hypervisor also provides hypercall interfaces for other critical kernel operations such as memory management, interrupt handling and time keeping. Paravirtualization is different from full virtualization , where the unmodified OS does not know it is virtualized and sensitive OS calls are trapped using binary translation. The value proposition of paravirtualization is in lower virtualization overhead, but the performance advantage of paravirtualization over full virtualization can vary greatly depending on the workload . As paravirtualization cannot support unmodified operating systems (e.g. Windows 2000/XP), its compatibility and portability is poor . Paravirtualization can also introduce significant support and maintainability issues in production environments as it requires deep OS kernel modifications.

The open source Xen project is an example of paravirtualization that virtualizes the processor and memory using a modified Linux kernel and virtualizes the I/O using custom guest OS device drivers . While it is very difficult to build the more sophisticated binary translation support necessary for full virtualization, modifying the guest OS to enable paravirtualization is relatively easy. VMware has used certain aspects of paravirtualization techniques across the VMware product line for years in the form of VMware tools and optimized virtual device drivers . The VMware tools service provides a backdoor to the VMM Hypervisor used for services such as time synchronization, logging and guest shutdown . Vmxnet is a paravirtualized I/O device driver that shares data structures with the hypervisor . It can take advantage of host device capabilities to offer improved throughput and reduced CPU utilization . It is important to note for clarity that the VMware tools service and the vmxnet device driver are not CPU paravirtualization solutions. They are minimal, non-intrusive changes installed into the guest OS that do not require OS kernel modification.

HARDWARE ASSISTED VIRTUALISATION Hardware vendors are rapidly embracing virtualization and developing new features to simplify virtualization techniques . First generation enhancements include Intel Virtualization Technology (VT-x) and AMD’s AMD-V which both target privileged instructions with a new CPU execution mode feature that allows the VMM to run in a new root mode below ring 0. As depicted in Figure 7, privileged and sensitive calls are set to automatically trap to the hypervisor, removing the need for either binary translation or paravirtualization. The guest state is stored in Virtual Machine Control Structures (VT-x) or Virtual Machine Control Blocks (AMD-V ). Processors with Intel VT and AMD-V became available in 2006, so only newer systems contain these hardware assist features.

PARTIAL VIRTUALISATION When entire operating systems cannot run in the virtual machine, but some or many applications can , it is known as Partial Virtualization. Basically, it partially simulates the physical hardware of a system. This type of virtualization is far easier to execute than full virtualization . An example of partial virtualization is address space virtualization used in time-sharing systems; this allows multiple applications and users to run concurrently in a separate memory space, but they still share the same hardware resources (disk, processor, and network).

S.No . Full Virtualization Paravirtualization 1. In Full virtualization, virtual machines permit the execution of the instructions with the running of unmodified OS in an entirely isolated way. In paravirtualization, a virtual machine does not implement full isolation of OS but rather provides a different API which is utilized when OS is subjected to alteration. 2. Full Virtualization is less secure. While the Paravirtualization is more secure than the Full Virtualization. 3. Full Virtualization uses binary translation and a direct approach as a technique for operations. While Paravirtualization uses hypercalls at compile time for operations. 4. Full Virtualization is slow than paravirtualization in operation. Paravirtualization is faster in operation as compared to full virtualization. 5. Full Virtualization is more portable and compatible. Paravirtualization is less portable and compatible.

6. Examples of full virtualization are Microsoft and Parallels systems. Examples of paravirtualization are Microsoft Hyper-V, Citrix Xen, etc. 7. It supports all guest operating systems without modification. The guest operating system has to be modified and only a few operating systems support it. 8. The guest operating system will issue hardware calls. Using the drivers, the guest operating system will directly communicate with the hypervisor. 9. It is less streamlined compared to para-virtualization. It is more streamlined. 10. It provides the best isolation. It provides less isolation compared to full virtualization.

Virtualization   is the creation of Virtual Version of something such as server, desktop, storage device, operating system etc.. Thus, Virtualization is a technique which allows us to share a single physical instance of a resource or an application among multiple customers and an organization. Virtualization often creates many virtual resources from one physical resource.   Host Machine – The machine on which virtual machine is going to create is known as Host Machine.      Guest Machine –   The virtual machines which are created on Host Machine is called Guest Machine. Why Virtualization in Cloud Computing ? Virtualization is very important concept in cloud computing. In cloud computing, a cloud vendor who will provide cloud services have all physical resources like server, storage device, network device etc. and these physical services are rented by cloud vendors so that user’s will not worry about these physical services.

Pros of Virtualization in Cloud Computing :   Utilization of Hardware Efficiently – With the help of Virtualization, Hardware is Efficiently used by user as well as Cloud Service Provider. In this, the need of Physical Hardware System for the User is decreases and this results in less costly. In Service Provider point of View , the Hardware using Hardware Virtualization which decrease the Hardware requirement from Vendor side which are provided to User is decreased. Before Virtualization , Companies and organizations have to set up their own Server which require extra space for placing them, engineer’s to check its performance and require extra hardware cost but with the help of Virtualization the all these limitations are removed by Cloud vendor’s who provide Physical Services without setting up any Physical Hardware system.

Availability increases with Virtualization – One of the main benefit of Virtualization is that it provides advance features which allow virtual instances to be available all the times. It also has capability to move virtual instance from one virtual Server another Server which is very tedious and risky task in Server Based System. During migration of Data from one server to another it ensures its safety. Also, we can access information from any location and any time from any device.

Disaster Recovery is efficient and easy – With the help of virtualization Data Recovery, Backup, Duplication becomes very easy. In traditional method , if somehow due to some disaster if Server system Damaged then the surety of Data Recovery is very less. But with the tools of Virtualization real time data backup recovery and mirroring become easy task and provide surety of zero percent data loss. Virtualization saves Energy – Virtualization will help to save Energy because while moving from physical Servers to Virtual Server’s, the number of Server’s decreases due to this monthly power and cooling cost decreases which will Save Money as well. As cooling cost reduces it means carbon production by devices  also decreases which results in Fresh and pollution free environment.

Quick and Easy Set up – In traditional methods , Setting up physical system and servers are very time-consuming. Firstly Purchase them in bulk after that wait for shipment. When Shipment is done then wait for Setting up and after that again spend time in installing required software etc. Which will consume very much time. But with the help of virtualization the entire process is done in very less time which results in productive setup. Cloud Migration becomes easy – Most of the companies those who already have spent a lot in the server have a doubt of Shifting to Cloud. But it is more cost-effective to shift to cloud services because all the data that is present in their server’s can be easily migrated into the cloud server and save something from maintenance charge, power consumption, cooling cost, cost to Server Maintenance Engineer etc.

Cons of Virtualization : Data can be at Risk – Working on virtual instances on shared resources means that our data is hosted on third party resource which put’s our data in vulnerable condition. Any hacker can attack on our data or try to perform unauthorized access. Without Security solution our data is in threaten situation . Learning New Infrastructure – As Organization shifted from Servers to Cloud. They required skilled staff who can work with cloud easily. Either they hire new IT staff with relevant skill or provide training on that skill which increase the cost of company. High Initial Investment – It is true that Virtualization will reduce the cost of companies but also it is truth that Cloud have high initial investment. It provides numerous services which are not required and when unskilled organization will try to set up in cloud they purchase unnecessary services which are not even required to them.

IMPLEMENTATION LEVELS OF VIRTUALISATION The virtualization software creates the abstraction ((is  the process of taking away or removing characteristics from something in order to reduce it to a set of essential characteristics)) of VMs by interposing a virtualization layer at various levels of a computer system. Common virtualization layers include : The instruction set architecture (ISA) level, Hardware level, Operating system level, Library support level, and Application level

Virtualization Ranging from Hardware to Applications in Five Abstraction Levels

- JVM: A Java virtual machine is an abstract computing machine that enables a computer to run a Java program. There are three notions of the JVM: specification, implementation, and instance. - .NET CLR: The Common Language Runtime, the virtual machine component of Microsoft's .NET framework, manages the execution of .NET programs. - WINE: Wine (recursive backronym for Wine Is Not an Emulator) is a free and open-source compatibility ..... product that uses some Wine code for its DirectX handling. VirtualBox, a virtual machine that uses some Wine code for its Direct3D handling. .

, - WABI : Sun used Windows Application Binary Interface to make Solaris more appealing to those needing Windows applications. The WABI software sits between an application and the operating system, intercepts the applications Windows calls, and translates them to "equivalent" Unix calls. On x86, the guest instructions were run directly on the processor, while they were emulated and/or binary translated on SPARC. WABI can also use an optional DOS emulator to run DOS applications. - Lxrun is software for executing Linux a.out and ELF binaries (x86 only) on x86 Unix systems such as SCO OpenServer, SCO UnixWare, and later, Solaris. This is achieved by "remapping" Linux system calls on the fly. You need the Linux shared libraries that the application requires, as well as the Linux dynamic loader. Lxrun is thus a system call emulator. There are various caveats as to what kind of applications will not run, etc. - MainWin: Microsoft had versions of Internet Explorer and Outlook Express for Solaris (SPARC). This was achieved not by porting them to Solaris, but by using API emulation. Mainsoft, the software company behind that effort, now has a product called Visual MainWin that allows for applications developed on Windows using Visual Studio to be run on Solaris, Linux

- vCuda : vCUDA is a general-purpose graphics processing unit (GPGPU) computing solution for virtual machines (VMs). - Jail: The FreeBSD jail mechanism is an implementation of operating system-level virtualization that allows system administrators to partition a FreeBSD-based computer system into several independent mini-systems called jails. - A Virtual Environment, put simply, is an isolated working copy of Python which allows you to work on a specific project without worry of affecting other projects It enables multiple side-by-side installations of Python, one for each project. -

Ensim VPS solution virtualizes a server's native OS so it can be partitioned into isolated computing environments which operate independently of each other, just like a dedicated server. - Featherweight Virtual Machine (FVM) is an OS-level virtual machine for Windows XP and Windows. - VMware , Inc. is a subsidiary of Dell Technologies that provides cloud computing and platform virtualization. - Windows Virtual PC is a virtualization program for Microsoft Windows. In July 2006 Microsoft released the Windows version as a free product. - The Denali project seeks to enable an array of new networking and distributed middleware applications by designing and implementing lightweight protection domains, focusing in particular on the use of lightweight virtual machines and monitors. A virtual machine monitor (VMM) is a thin virtualization layer between hardware and ``guest'' operating systems, enabling hosts to safely execute untrusted applications and guest OS's inside a VM.

- Xen Project is a hypervisor using a microkernel design, providing services that allow multiple computer operating systems to execute on the same computer hardware concurrently. It was developed by the University of Cambridge and is now being developed by the Linux Foundation with support from Intel. - The L4 Runtime Environment (L4Re) provides a basic set of services and abstractions, which are useful to implement and run user-level applications on top of the Fiasco.OC microkernel. - Plex86 is a very lightweight Virtual Machine (VM) for running Linux/x86. - User-Mode Linux is a safe, secure way of running Linux versions and Linux processes. Run buggy software, experiment with new Linux kernels or distributions, and poke around in the internals of Linux, all without risking your main Linux setup. - Bochs is a portable x86 PC emulation software package that emulates enough of the x86 CPU, related AT hardware, and BIOS to run Windows, Linux, *BSD, Minix, and other OS's, all on your workstation.

- The Crusoe is a family of x86-compatible microprocessors developed by Transmeta and introduced in 2000. Crusoe was notable for its method of achieving x86 compatibility. Instead of the instruction set architecture being implemented in hardware, or translated by specialized hardware, the Crusoe runs a software abstraction layer, or a virtual machine, known as the Code Morphing Software (CMS). The CMS translates machine code instructions received from programs into native instructions for the microprocessor. In this way, the Crusoe can emulate other instruction set architectures (ISAs). - QEMU is a hosted virtual machine monitor: it emulates CPUs through dynamic binary translation and provides a set of device models, enabling it to run a variety of unmodified guest operating systems. It also can be used with KVM to run virtual machines at near-native speed (requiring hardware virtualization extensions on x86 machines). QEMU can also do CPU emulation for user-level processes, allowing applications compiled for one architecture to run on another. - Dynamo is an experimental web framework that runs on Elixir. It leverages the power of the Erlang VM to build highly performant and concurrent web applications. Dynamo's goals are performance, robustness and simplicity.

Million instructions per second (MIPS ) is an approximate measure of a computer's raw processing power . All MIPS instructions are encoded in binary. All MIPS instructions are 32 bits long. MIPS instructions are encoded in binary, as 32-bit instruction words, called machine code. The layout of an instruction is called the instruction format. T arget address fields need to be shifted left 2 bits to correctly represent a valid instruction address (32-bits aligned).

Code interpretation means  a formal statement regarding the meaning or requirements of a particular provision How does code interpretation work? An Interpreter directly executes instructions written in a programming or scripting language without previously converting them to an object code or machine code. Examples of interpreted languages are Perl, Python and Matlab . What is compile vs interpret code? A compiled language is converted into machine code so that the processor can execute it. An interpreted language is a language in which the implementations execute instructions directly without earlier compiling a program into machine language. The compiled programs run faster than interpreted programs.

OS-level virtualization is  a technology that partitions the operating system to create multiple isolated Virtual Machines (VM) . An OS-level VM is a virtual execution environment that can be forked instantly from the base operating environment . What is virtualization in OS example? Virtualization improves hardware resources used in your data center. For example, instead of running one server on one computer system, you can create a virtual server pool on the same computer system by using and returning servers to the pool as required . Why docker is called OS-level virtualization ? Docker is a software platform that allows you to build, test, and deploy applications quickly. Docker packages software into standardized units called containers that have everything the software needs to run including libraries, system tools, code, and runtime. Docker can be considered an alternative to virtualization, as it allows applications and services to run in isolated environments on a single host, similar to how virtualization allows multiple virtual machines to run on a single physical server . Operating System Virtualization uses to integrate server hardware by moving services on separate servers. It provides security to the hardware resources which harm by distrusting users. OS Virtualization uses for virtual hosting environment. It can separate several applications into containers.

It is also called OS-level virtualization is a type of virtualization technology which work on OS layer. Here the kernel of an OS allows more than one isolated user-space instances to exist. Such instances are called containers/software containers or virtualization engines. In other words, OS kernel will run a single operating system & provide that operating system's functionality to replicate on each of the isolated partitions. Uses of OS Virtualization Used for virtual hosting environment. Used for securely allocation of finite hardware resources among a large number of distrusting users. System administrator uses it to integrate server hardware by moving services on separate hosts. To improvised security by separating several applications to several containers. These forms of virtualization don't require hardware to work efficiently.

How OS Virtualization Works The steps for how these virtualization works are listed below: Connect to OS Virtualization Server Connect to virtual disk Then connect this virtual disk to the client OS is streamed to the client If further additional streaming is required, it is done TYPES:LINUX OS,WINDOWS OS VIRTUAL DISK OS The client will be connected via the network to the virtual disk & will boot the OS installed on virtual disk. Two types of virtual disks are there for implementation. These are: Private Virtual Disk: is used by one client only like that of a local hard disk. Users can save information on the virtual disk based on the rights assigned. So as the client restart the system, the settings are retained just like working with physical local hard disk. Shared/Common Virtual Disk: It is used by multiple clients at the same time. The changes are saved in a special cache & these caches gets cleaned as the user restarts or shutdowns the system. In other words, when a client is booting up, it will use the default configuration available on the virtual disk.

8/9/2024 76 Advantages of OS Extension for Virtualization VMs at OS level has minimum startup/shutdown costs OS-level VM can easily synchronize with its environment Disadvantage of OS Extension for Virtualization All VMs in the same OS container must have the same or similar guest OS, which restrict application flexibility of different VMs on the same physical machine.

4.Library Support level: 8/9/2024 77 Virtualization with library interfaces is possible by controlling the communication link between applications and the rest of a system through API hooks. The software tool WINE has implemented this approach to support Windows applications on top of UNIX hosts. Advantage : It has very low implementation effort Shortcoming & limitation: poor application flexibility and isolation

5.User-Application Level 8/9/2024 78 Virtualization at the application level virtualizes an application as a VM. On a traditional OS, an application often runs as a process. Therefore, application-level virtualization is also known as process-level virtualization. The most popular approach is to deploy high level language (HLL) VMs. In this scenario, the virtualization layer sits as an application program on top of the operating system, and the layer exports an abstraction of a VM that can run programs written and compiled to a particular abstract machine definition. Other forms of application-level virtualization are known as application isolation, application sandboxing, or application streaming. Advantage: has the best application isolation Shortcoming & limitation: low performance, low application flexibility and high implementation complexity.

User-Application Level Virtualization 8/9/2024 79

Virtualization Structures/Tools and Mechanisms 8/9/2024 80 In general, there are three typical classes of VM architecture. Before virtualization , the operating system manages the hardware. After virtualization , a virtualization layer is inserted between the hardware and the operating system. In such a case, the virtualization layer is responsible for converting portions of the real hardware into virtual hardware. Therefore, different operating systems such as Linux and Windows can run on the same physical machine, simultaneously. Depending on the position of the virtualization layer, there are several classes of VM architectures, namely the hypervisor architecture , para-virtualization , and host-based virtualization . The hypervisor is also known as the VMM (Virtual Machine Monitor). They both perform the same virtualization operations.

Hypervisor 8/9/2024 81 A hypervisor is a hardware virtualization technique allowing multiple operating systems, called guests to run on a host machine. This is also called the Virtual Machine Monitor (VMM). Type 1: bare metal hypervisor sits on the bare metal computer hardware like the CPU, memory, etc. All guest operating systems are a layer above the hypervisor. The original CP/CMS hypervisor developed by IBM was of this kind. Type 2: hosted hypervisor Run over a host operating system. Hypervisor is the second layer over the hardware. Guest operating systems run a layer over the hypervisor. The OS is usually unaware of the virtualization

Full Binary Translation and Host-based Virtualization 8/9/2024 82 Depending on implementation technologies, hardware virtualization VM architectures can be classified into two categories: F ull virtualization and H ost-based virtualization. Full virtualization does not need to modify the host OS. It relies on binary translation to trap and to virtualize the execution of certain sensitive, non virtualizable instructions. In a host-based system, both a host OS and a guest OS are used. A virtualization software layer is built between the host OS and guest OS.

Binary Translation of Guest OS Requests Using a VMM 8/9/2024 83 This approach was implemented by VMware and many other software companies. VMware puts the VMM at Ring 0 and the guest OS at Ring 1. The VMM scans the instruction stream and identified the privileged, control- and behavior sensitive instructions. When these instructions are identified, they are trapped into the VMM, which emulates the behavior of these instructions. The method used in this emulation is called binary translation. Therefore, full virtualization combines binary translation and direct execution.

Host-Based Virtualization 8/9/2024 84 An alternative VM architecture is to install a virtualization layer on top of the host OS. This host OS is still responsible for managing the hardware. This host-based architecture has some distinct advantages. First, the user can install this VM architecture without modifying the host OS. The virtualizing software can rely on the host OS to provide device drivers and other low-level services. This will simplify the VM design and ease its deployment. Second, the host-based approach appeals to many host machine configurations. Compared to the hypervisor/VMM architecture, the performance of the host-based architecture may also be low .

Para-virtualization 8/9/2024 85 Para-virtualization needs to modify the guest operating systems. A para-virtualized VM provides special APIs requiring substantial OS modifications in user applications. Performance degradation is a critical issue of a virtualized system.

Full Virtualization vs. Para-Virtualization 8/9/2024 86 Full virtualization Does not need to modify guest OS, and critical instructions are emulated by software through the use of binary translation. VMware Workstation applies full virtualization , which uses binary translation to automatically modify x86 software on-the-fly to replace critical instructions. Advantage: no need to modify OS. Disadvantage: binary translation slows down the performance. Para virtualization Reduces the overhead, but cost of maintaining a paravirtualized OS is high. The improvement depends on the workload. Para virtualization must modify guest OS, non-virtualizable instructions are replaced by hyper calls that communicate directly with the hypervisor or VMM. Para virtualization is supported by Xen, Denali and VMware ESX.

The XEN Architecture 8/9/2024 87 Xen is an open source hypervisor program developed by Cambridge University. Xen is a micro-kernel hypervisor, which separates the policy from the mechanism. Xen does not include any device drivers natively . It just provides a mechanism by which a guest OS can have direct access to the physical devices. As a result, the size of the Xen hypervisor is kept rather small. Xen provides a virtual environment located between the hardware and the OS.

CPU Virtualization 8/9/2024 88 A VM is a duplicate of an existing computer system in which a majority of the VM instructions are executed on the host processor in native mode. Thus, unprivileged instructions of VMs run directly on the host machine for higher efficiency. Other critical instructions should be handled carefully for correctness and stability. The critical instructions are divided into three categories: privileged instructions, control–sensitive instructions, and behavior-sensitive instructions. Privileged instructions execute in a privileged mode and will be trapped if executed outside this mode. Control-sensitive instructions attempt to change the configuration of resources used. Behavior-sensitive instructions have different behaviors depending on the configuration of resources, including the load and store operations over the virtual memory. Virtualization of CPU, Memory, and I/O Devices

8/9/2024 89 A CPU architecture is virtualizable if it supports the ability to run the VM’s privileged and unprivileged instructions in the CPU’s user mode while the VMM runs in supervisor mode. When the privileged instructions including control- and behavior-sensitive instructions of a VM are executed, they are trapped in the VMM. In this case, the VMM acts as a unified mediator for hardware access from different VMs to guarantee the correctness and stability of the whole system. However, not all CPU architectures are virtualizable. RI SC CPU architectures can be naturally virtualized because all control and behavior-sensitive instructions are privileged instructions. On the contrary, x86 CPU architectures are not primarily designed to support virtualization.

Memory Virtualization 8/9/2024 90 Virtual memory virtualization is similar to the virtual memory support provided by modern operating systems. I n a traditional execution environment, the operating system maintains mappings of virtual memory to ma chine memory using page tables, which is a one-stage mapping from virtual memory to machine memory. However, in a virtual execution environment, virtual memory virtualization involves sharing the physical system memory in RAM and dynamically allocating it to the physical memory of the VMs. That means a two-stage mapping process should be maintained by the guest OS and the VMM, respectively: virtual memory to physical memory and physical memory to machine memory.

I/O Virtualization 8/9/2024 91 there are three ways to implement I/O virtualization: full device emulation, para-virtualization, and direct I/O . I/O virtualization. Generally, this approach emulates well-known, real-world devices. All the functions of a device or bus infrastructure, such as device enumeration, identification, interrupts, and DMA, are replicated in software. This software is located in the VMM and acts as a virtual device. The para-virtualization method of I/O virtualization is typically used in Xen. It is also known as the split driver model consisting of a frontend driver and a backend driver. It achieves beer device performance than full device emulation, it comes with a higher CPU overhead Direct I/O virtualization lets the VM access devices directly. It can achieve close-to native performance without high CPU costs.

Diskless Beowulf Cluster - PelicanHPC PelicanHPC is a rapid (around 5 minutes, when you know what you're doing) means of setting up a high performance computing (HPC) cluster for parallel computing using MPI. We will see what PelicanHPC does, how to use the released CD images to set up a HPC cluster, and some basic examples of usage. 8/9/2024 92

8/9/2024 93

PelicanHPC Installation PelicanHPC is a distribution of GNU/Linux that runs as a "live CD" (or as a virtualization appliance). If the ISO image file is burnt to a CD /Flash Disk , the resulting CD /Flash Disk can be used to boot a computer. The computer on which PelicanHPC is booted is referred to as the "frontend node", which is the computer that the user interacts with. 8/9/2024 94

Runing the PelicanHPC Cluster Once PelicanHPC is running, a script ­ " pelican_setup " ­ may be run. This script configures the frontend node as a netboot server. After this has been done, other computers can boot copies of PelicanHPC over the network. These other computers are referred to as "compute nodes". PelicanHPC configures the cluster made up of the frontend node and the compute nodes so that MPI­based parallel computing may be done. 8/9/2024 95

PelicanHPC Advantages A "live CD" such as PelicanHPC does not use the hard disk of any of the nodes, so it will not destroy or alter your installed operating system. When the PelicanHPC cluster is shut down, all of the computers are in their original state, and will boot back into whatever operating system is installed. 8/9/2024 96

END OF UNIT - 2