Cloud Operating System Unit 09 Cloud OS Core Technology M. C. Chiang Department of Computer Science and Engineering National Sun Yat-sen University Kaohsiung,

Slides:



Advertisements
Similar presentations
Virtualization Dr. Michael L. Collard
Advertisements

Virtualization Technology
Bart Miller. Outline Definition and goals Paravirtualization System Architecture The Virtual Machine Interface Memory Management CPU Device I/O Network,
Virtualization and Cloud Computing
Network Implementation for Xen and KVM Class project for E : Network System Design and Implantation 12 Apr 2010 Kangkook Jee (kj2181)
Virtualization Techniques for Cloud Computing
1 Disco: Running Commodity Operating Systems on Scalable Multiprocessors Edouard Bugnion, Scott Devine, and Mendel Rosenblum, Stanford University, 1997.
Cloud Computing and Virtualization Sorav Bansal CloudCamp 2010 IIT Delhi.
Virtualization and the Cloud
A. Frank - P. Weisberg Operating Systems Structure of Operating Systems.
November 1, 2004Introduction to Computer Security ©2004 Matt Bishop Slide #29-1 Chapter 33: Virtual Machines Virtual Machine Structure Virtual Machine.
Virtual Machines. Virtualization Virtualization deals with “extending or replacing an existing interface so as to mimic the behavior of another system”
Virtualization for Cloud Computing
Virtual Machine Monitors CSE451 Andrew Whitaker. Hardware Virtualization Running multiple operating systems on a single physical machine Examples:  VMWare,
LINUX Virtualization Running other code under LINUX.
虛擬化技術 Virtualization and Virtual Machines
Introduction to Virtual Machines. Administration Presentation and class participation: 40% –Each student will present two and a half times this semester.
Virtualization-optimized architectures
Tanenbaum 8.3 See references
Zen and the Art of Virtualization Paul Barham, et al. University of Cambridge, Microsoft Research Cambridge Published by ACM SOSP’03 Presented by Tina.
CS 149: Operating Systems April 21 Class Meeting
Microkernels, virtualization, exokernels Tutorial 1 – CSC469.
SAIGONTECH COPPERATIVE EDUCATION NETWORKING Spring 2010 Seminar #1 VIRTUALIZATION EVERYWHERE.
SAIGONTECH COPPERATIVE EDUCATION NETWORKING Spring 2009 Seminar #1 VIRTUALIZATION EVERYWHERE.
Virtualization Concepts Presented by: Mariano Diaz.
Xen I/O Overview. Xen is a popular open-source x86 virtual machine monitor – full-virtualization – para-virtualization para-virtualization as a more efficient.
Virtualization Paul Krzyzanowski Distributed Systems Except as otherwise noted, the content of this presentation is licensed.
Virtual Machine and its Role in Distributed Systems.
CS533 Concepts of Operating Systems Jonathan Walpole.
 Virtual machine systems: simulators for multiple copies of a machine on itself.  Virtual machine (VM): the simulated machine.  Virtual machine monitor.
Virtualisation Front Side Buses SMP systems COMP Jamie Curtis.
Introduction to virtualization
Full and Para Virtualization
Lecture 26 Virtual Machine Monitors. Virtual Machines Goal: run an guest OS over an host OS Who has done this? Why might it be useful? Examples: Vmware,
Lecture 12 Virtualization Overview 1 Dec. 1, 2015 Prof. Kyu Ho Park “Understanding Full Virtualization, Paravirtualization, and Hardware Assist”, White.
Operating-System Structures
Protection of Processes Security and privacy of data is challenging currently. Protecting information – Not limited to hardware. – Depends on innovation.
CSE 451: Operating Systems Winter 2015 Module 25 Virtual Machine Monitors Mark Zbikowski Allen Center 476 © 2013 Gribble, Lazowska,
Extending Xen * with Intel ® Virtualization Technology Mobile Embedded System Choi, Jin-yong
Virtualizing a Multiprocessor Machine on a Network of Computers Easy & efficient utilization of distributed resources Goal Kenji KanedaYoshihiro OyamaAkinori.
Unit 2 VIRTUALISATION. Unit 2 - Syllabus Basics of Virtualization Types of Virtualization Implementation Levels of Virtualization Virtualization Structures.
CLUG TALK Virtualbox Tuesday, 29 September 2009 One of the Jonathans.
1 Virtualization "Virtualization software makes it possible to run multiple operating systems and multiple applications on the same server at the same.
CS 695 Topics in Virtualization and Cloud Computing, Autumn 2012 CS 695 Topics in Virtualization and Cloud Computing More Introduction + Processor Virtualization.
Virtualization-optimized architectures
Virtualization for Cloud Computing
A move towards Greener Planet
Introduction to Virtualization
Virtualization.
Virtual Machine Monitors
Virtualization Technology
Virtual machines and containers
L2- Virtualization Technology
Virtualization Dr. Michael L. Collard
Prepared by: Assistant prof. Aslamzai
Lecture 24 Virtual Machine Monitors
Virtual Servers.
Disco: Running Commodity Operating Systems on Scalable Multiprocessors
Running other code under LINUX
Group 8 Virtualization of the Cloud
OS Virtualization.
Virtualization Techniques
A Survey on Virtualization Technologies
Computer Security: Art and Science, 2nd Edition
Full and Para Virtualization
CSE 451: Operating Systems Autumn Module 24 Virtual Machine Monitors
Virtualization Dr. S. R. Ahmed.
CSE 451: Operating Systems Autumn Module 24 Virtual Machine Monitors
System Virtualization
CS295: Modern Systems Virtualization
Presentation transcript:

Cloud Operating System Unit 09 Cloud OS Core Technology M. C. Chiang Department of Computer Science and Engineering National Sun Yat-sen University Kaohsiung, Taiwan, ROC Cloud Operating System

Outline  Main Characteristics of Cloud Computing  Why Virtualization?  Hardware Virtualization  Full virtualization  Paravirtualiztion  Hardware-assisted virtualization  Device Driver Virtualization  Memory Virtualization  Local vs. Distributed 2015/11/15 Cloud Operating System - Uint 09: Core Technique U01-2

Main Characteristics of Cloud Computing  On-demand self-service  Broad network access  Resource pooling  Rapid elasticity  Measured service 2015/11/15 Cloud Operating System - Uint 09: Core Technique U01-3

Main Characteristics of Cloud Computing  On-demand self-service  System demands resource automatically  Broad network access  Resource pooling  Virtualizing resources such as memory, storage, CPU into pools.  Rapid elasticity  Provisioning or releasing resources at anytime  Measured service 2015/11/15 Cloud Operating System - Uint 09: Core Technique U01-4

History of Virtualization (1)  1964 – IBM CP-40.  1965 – IBM System/360-67, with virtual memory hardware.  1999 – Full Virtualization. VMware.  2003 – Para-Virtualization. Xen.  2005 – HW-Assisted Virtualization. Intel VT-x, AMD-V.  2006 – QEMU.  2007 – KVM (Kernel-based Virtual Machine). Linux /11/15 Cloud Operating System - Uint 09: Core Technique U01-5

History of Virtualization (2)  From another perspective, the development of virtualization can be divided into the following stages:  Mainframe Virtualization  Desktop Virtualization  Server Virtualization  Cloud Computing  Nowadays.  Mobile Virtualization  On the way. 2015/11/15 Cloud Operating System - Uint 09: Core Technique U01-6

History of Virtualization (3)  The reasons of x86 virtualization:  Low infrastructure utilization.  Increasing physical infrastructure costs.  Increasing IT management costs.  Insufficient failover and disaster protection.  High maintenance end-user desktop.  x86 is widespread. 2015/11/15 Cloud Operating System - Uint 09: Core Technique U01-7

Applying Virtualization to Cloud  With virtualizing resources, they can easily be put into pools.  Virtualized CPU and memories can be distributed dynamically to virtual machines in real time.  Leads to Rapid elasticity and On-demand self- service  Imagine ‘hot plug memories/CPU’ into machines. 2015/11/15 Cloud Operating System - Uint 09: Core Technique U01-8

Hardware Virtualization (1)  How to realize x86 virtualization?  What’s the problem encountered?  How to deal with the problem? 2015/11/15 Cloud Operating System - Uint 09: Core Technique U01-9

Hardware Virtualization (2)  How to realize x86 virtualization?  What’s the problem encountered?  How to deal with the problem? 2015/11/15 Cloud Operating System - Uint 09: Core Technique U01-10

Hardware Virtualization (2) 2015/11/15 Cloud Operating System - Uint 09: Core Technique  Traditionally, OS is at Ring 0 for hardware resource management.  When realizing virtualization, VMM is at Ring 0, and OS is downgraded to Ring 1. U01-11

Hardware Virtualization (2)  According to Popek and Goldberg, CPU instructions can be classified into three sets.  Privileged instructions.  Sensitive instructions.  Critical instructions. *1: GJ Popek and RP Goldberg, “Formal requirements for virtualizable third generation architectures”, Communication of the ACM, vol 17, pp , July, /11/15 Cloud Operating System - Uint 09: Core Technique U01-12

Hardware Virtualization (3)  How to realize x86 virtualization?  What’s the problem encountered?  How to deal with the problem? 2015/11/15 Cloud Operating System - Uint 09: Core Technique U01-13

Hardware Virtualization (3)  Instruction which will modify the configuration of resources should either be executed in Ring 0 (privileged mode) or trap.  There are 17 instructions in x86 architecture may cause problem. Why?  They are unprivileged. Won’t cause trap when execution.  They expose physical processor state. Reveal some details which shouldn’t be. 2015/11/15 Cloud Operating System - Uint 09: Core Technique U01-14

Hardware Virtualization (4)  How to realize x86 virtualization?  What’s the problem encountered?  How to deal with the problem? 2015/11/15 Cloud Operating System - Uint 09: Core Technique U01-15

Hardware Virtualization (4)  There are three approaches for virtualization available nowadays.  Full Virtualization.  ParaVirtualization.  Hardware-Assisted Virtualization. 2015/11/15 Cloud Operating System - Uint 09: Core Technique U01-16

Full Virtualization  Binary Translation.  Replace nonvirtualizable instructions with new sequences of instructions which have the same effect as original on the virtual hardware.  Many instructions replace one, so if the instruction is frequently used, the overhead is huge.  Huge cost on resources.  Better compatibility.  VMware, QEMU. 2015/11/15 Cloud Operating System - Uint 09: Core Technique U01-17

ParaVirtualization (1)  Also named OS-assisted virtualization.  OS kernel adaptation.  Performing corresponding hypercalls instead of the original privileged instructions.  Low cost of CPU and I/O.  Compatibility worse than Full Virtualization.  Meet problems when the kernel is not open.  Citrix Xenserver, Microsoft hyper-V. 2015/11/15 Cloud Operating System - Uint 09: Core Technique U01-18

ParaVirtualization (2)  Hypercall is quite similar to system call.  Implementation of Xen.  System call: an interrupt (0x80) from user space to kernel space.  Hypercall: an interrupt (0x82) from guest domain (Ring 1) to hypervisor (Ring 0).  Both system call table and hypercall table are defined in file “arch/x86/kernel/entry_64.S”. 2015/11/15 Cloud Operating System - Uint 09: Core Technique U01-19

Hardware-Assisted Virtualization (1)  Re-design the hardware architecture.  Add new instruction sets for x86 architecture to trap those nonvirtualizable instructions.  Conceptually, hypervisor stays at “Ring -1”.  No need to de-privilege the guest OS.  AMD AMD-V, Intel VT-x. 2015/11/15 Cloud Operating System - Uint 09: Core Technique U01-20

Hardware-Assisted Virtualization (2)  Intel VT-x:  First supported by Pentium 4 (Model 662 and 672) on  Two operating mode: VMX Root Operation (for VMM). Non-Root Operation (for Guest OS).  Extented Page Tables. 2015/11/15 Cloud Operating System - Uint 09: Core Technique U01-21

Hardware-Assisted Virtualization (3)  AMD AMD-V:  On 2006, first supported by Athlon 64, Athlon 64 X2 and Athlon 64 FX.  Two modes for hypervisor to handle memory partitioning: Shadow Page Tables. Nested Page Tables. 2015/11/15 Cloud Operating System - Uint 09: Core Technique U01-22

Device Driver Virtualization – the Idea  Virtual machines need their own device drivers.  For guest OSs to communicate with physical hardware.  Most virtualization solutions emulated simple devices that the drivers already existed. Like IDE interface and NE2000 (a very old nic). 2015/11/15 Cloud Operating System - Uint 09: Core Technique U01-23

Device Driver Virtualization – in Practice  Xen Hypervisor’s paravirtulization solution:  Requests from front-end drivers in DomU writes into a ring-buffer shared with Dom0.  Dom0 handles the request by the back-end drivers in kernel, and access the hardware by real drivers.  Then back-end write response back and consumed by guest. 2015/11/15 Cloud Operating System - Uint 09: Core Technique U01-24

Device Driver Virtualization  The Split Driver 2015/11/15 Cloud Operating System - Uint 09: Core Technique U01-25

Memory Virtualization  Modern Operating system and x86 hardware mostly support memory virtualization.  In user-space applications access to virtual memory with paging mechanism.  VM instance hosts with a OS support virtual memory means an addition layers of memory mapping.  Newer CPUs have optimizations for addition layers of mapping.  Additional Tagged TLBs in case that when switching VMs the TLB will be flushed. 2015/11/15 Cloud Operating System - Uint 09: Core Technique U01-26

Memory Virtualization – in Practice  In full virtualization, hypervisor traps every action try to update page table.  At once hypervisor traps the action, hypervisor can take over.  In Xen paravirtualization, para-virtualized OS directly invoke hypercalls to ask hypervisor update the page table.  Much faster. 2015/11/15 Cloud Operating System - Uint 09: Core Technique U01-27

Distributed Memory Virtualization – the Idea  Pooling the virtualized memory  We can add nodes into our cloud to extend the memory capacity.  Breaking the bound of physical machines  If an VM instance in a node need more memories, it can get memories from other nodes. 2015/11/15 Cloud Operating System - Uint 09: Core Technique U01-28

Distributed Memory Virtualization – in Practice  Performance issue. Relatively very very high latency compare to local memories.  Latency of Infiniband or 10G Ethernet : 1.07 ~ 2.6 µs.  Latency of DDR3 SDRAM: 10.5 ns.  Page table for distributed environment adds even more overhead.  Therefore, mainstream hypervisors don’t support distributed memory virtualization, for now. 2015/11/15 Cloud Operating System - Uint 09: Core Technique U01-29

Summary  Some characteristics of cloud computing need virtualization to achieve.  Virtualization technology leads to better utilization and elastic deployment. It also leads to better business model. 2015/11/15 Cloud Operating System - Uint 09: Core Technique U01-30

Summary  Virtualization Approaches  Full Virtualization : High compatibility, low performance.  Para-Virtualization : Need OS modified for VMM, best performance.  HAV : Need newer hardware, good compatibility, good performance 2015/11/15 Cloud Operating System - Uint 09: Core Technique U01-31

Summary  Device Drivers needs virtualization as well.  Rather than emulation a whole device, we can implement a simple front-end in guest, and communicate with back-end device driver.  Memory Virtualization  Performance critical.  Lot’s new designs in CPU in order to optimization memory related operations. 2015/11/15 Cloud Operating System - Uint 09: Core Technique U01-32