Virtualization History and Future Trends

Similar documents
OS Virtualization. Why Virtualize? Introduction. Virtualization Basics 12/10/2012. Motivation. Types of Virtualization.

Virtualization. Pradipta De

COMPUTER ARCHITECTURE. Virtualization and Memory Hierarchy

Virtualization and memory hierarchy

The Architecture of Virtual Machines Lecture for the Embedded Systems Course CSD, University of Crete (April 29, 2014)

24-vm.txt Mon Nov 21 22:13: Notes on Virtual Machines , Fall 2011 Carnegie Mellon University Randal E. Bryant.

Virtual Machines. Part 2: starting 19 years ago. Operating Systems In Depth IX 1 Copyright 2018 Thomas W. Doeppner. All rights reserved.

CS 550 Operating Systems Spring Introduction to Virtual Machines

CS5460: Operating Systems. Lecture: Virtualization. Anton Burtsev March, 2013

Virtualization. Starting Point: A Physical Machine. What is a Virtual Machine? Virtualization Properties. Types of Virtualization

Virtualization. ! Physical Hardware Processors, memory, chipset, I/O devices, etc. Resources often grossly underutilized

Virtualization. Operating Systems, 2016, Meni Adler, Danny Hendler & Amnon Meisels

Virtual Virtual Memory

Virtualization and Virtual Machines. CS522 Principles of Computer Systems Dr. Edouard Bugnion

Cloud Computing Virtualization

What is KVM? KVM patch. Modern hypervisors must do many things that are already done by OSs Scheduler, Memory management, I/O stacks

CS370 Operating Systems

VIRTUALIZATION: IBM VM/370 AND XEN

Lecture 5. KVM for ARM. Christoffer Dall and Jason Nieh. 5 November, Operating Systems Practical. OSP Lecture 5, KVM for ARM 1/42

Module 1: Virtualization. Types of Interfaces

Advanced Operating Systems (CS 202) Virtualization

Spring 2017 :: CSE 506. Introduction to. Virtual Machines. Nima Honarmand

Lecture 7. Xen and the Art of Virtualization. Paul Braham, Boris Dragovic, Keir Fraser et al. 16 November, Advanced Operating Systems

On the DMA Mapping Problem in Direct Device Assignment

Introduction to Virtual Machines. Carl Waldspurger (SB SM 89 PhD 95) VMware R&D

Knut Omang Ifi/Oracle 6 Nov, 2017

DISCO and Virtualization

COS 318: Operating Systems. Virtual Machine Monitors

CSE 120 Principles of Operating Systems

Xen is not just paravirtualization

The Challenges of X86 Hardware Virtualization. GCC- Virtualization: Rajeev Wankar 36

Chapter 5 C. Virtual machines

Virtual Machines. Jinkyu Jeong Computer Systems Laboratory Sungkyunkwan University

BUD17-301: KVM/ARM Nested Virtualization. Christoffer Dall

A Survey on Virtualization Technologies

Operating Systems 4/27/2015

Virtualisation: The KVM Way. Amit Shah

CS 350 Winter 2011 Current Topics: Virtual Machines + Solid State Drives

Virtual machine architecture and KVM analysis D 陳彥霖 B 郭宗倫

Advanced Systems Security: Virtual Machine Systems

Learning Outcomes. Extended OS. Observations Operating systems provide well defined interfaces. Virtual Machines. Interface Levels

Virtual machines are an interesting extension of the virtual-memory concept: not only do we give processes the illusion that they have all of memory

Advanced Systems Security: Virtual Machine Systems

Virtual Machines Disco and Xen (Lecture 10, cs262a) Ion Stoica & Ali Ghodsi UC Berkeley February 26, 2018

references Virtualization services Topics Virtualization

To EL2, and Beyond! connect.linaro.org. Optimizing the Design and Implementation of KVM/ARM

Virtualization. Adam Belay

VIRTUALIZATION. Dresden, 2011/12/6. Julian Stecklina

Virtualization. Virtualization

Bare-Metal Performance for x86 Virtualization

Hypervisor security. Evgeny Yakovlev, DEFCON NN, 2017

Nested Virtualization and Server Consolidation

Intel s Virtualization Extensions (VT-x) So you want to build a hypervisor?

Virtual Machines. To do. q VM over time q Implementation methods q Hardware features supporting VM q Next time: Midterm?

CSC 5930/9010 Cloud S & P: Virtualization

Virtualization. Dr. Yingwu Zhu

Xen and the Art of Virtualization

System Virtual Machines

Virtual Machine Monitors (VMMs) are a hot topic in

Virtualization. Part 1 Concepts & XEN

Background. IBM sold expensive mainframes to large organizations. Monitor sits between one or more OSes and HW

Concepts. Virtualization

Virtualization technology

Linux and Xen. Andrea Sarro. andrea.sarro(at)quadrics.it. Linux Kernel Hacking Free Course IV Edition

MOS - VIRTUALIZATION. Tobias Stumpf, Marcus Hähnel WS 2015/16

We ve seen lots of examples of virtualization. This is another: a virtual machine monitor. A VMM virtualizes an entire hardware machine.

CS-580K/480K Advanced Topics in Cloud Computing. VM Virtualization II

Performance of Kernels in Virtual Machines: An Introduction to KVM Hypervisor

System Virtual Machines

CHAPTER 16 - VIRTUAL MACHINES

Mach External pager. IPC Costs. Why the difference? Example of IPC Performance. First generation microkernels were slow Mach, Chorus, Amoeba

Advanced Operating Systems

Faithful Virtualization on a Real-Time Operating System

CLOUD COMPUTING IT0530. G.JEYA BHARATHI Asst.Prof.(O.G) Department of IT SRM University

NON SCHOLAE, SED VITAE

MASSACHUSETTS INSTITUTE OF TECHNOLOGY Computer Systems Engineering: Spring Quiz I Solutions

Scalable I/O A Well-Architected Way to Do Scalable, Secure and Virtualized I/O

Xen and the Art of Virtualization. Nikola Gvozdiev Georgian Mihaila

Virtualization. Guillaume Urvoy-Keller UNS/I3S

Virtualization, Xen and Denali

Today s Papers. Virtual Machines Background. Why Virtualize? EECS 262a Advanced Topics in Computer Systems Lecture 19

CS370: Operating Systems [Spring 2017] Dept. Of Computer Science, Colorado State University

CS370: Operating Systems [Spring 2016] Dept. Of Computer Science, Colorado State University

IBM Research Report. The Turtles Project: Design and Implementation of Nested Virtualization

CSCI 8530 Advanced Operating Systems. Part 19 Virtualization

VIRTUALIZATION. Dresden, 2011/6/23. Julian Stecklina

Virtualization (II) SPD Course 17/03/2010 Massimo Coppola

Virtual Memory. Lecture for CPSC 5155 Edward Bosworth, Ph.D. Computer Science Department Columbus State University

Virtual Machine Security

Multiprocessor Scheduling. Multiprocessor Scheduling

IBM Research Report. Direct Device Assignment for Untrusted Fully-Virtualized Virtual Machines

KVM/ARM. Linux Symposium Christoffer Dall and Jason Nieh

IBM Research Report. The Turtles Project: Design and Implementation of Nested Virtualization

1 Virtualization Recap

Virtual Machines. Part 1: 54 years ago. Operating Systems In Depth VIII 1 Copyright 2018 Thomas W. Doeppner. All rights reserved.

Interrupt Coalescing in Xen

Introduction to Cloud Computing and Virtualization. Mayank Mishra Sujesha Sudevalayam PhD Students CSE, IIT Bombay

VIRTUALIZATION. Dresden, 2013/12/3. Julian Stecklina

CS370 Operating Systems

Faculty of Computer Science Institute for System Architecture, Operating Systems Group. Virtualization. Henning Schild. Dresden,

Transcription:

Virtualization History and Future Trends Christoffer Dall - Candidacy Exam - January 2013 Columbia University - Computer Science Department

IBM Mainframe VMs VMware Workstation x86 Hardware Support Virtual Power I/O and Device Assignments 70s 99 03 05... 12 Paravirtualization Xen CPU and Memory Optimizations Virtual Interrupts Historical Overview

Taxonomy Virtualization Software [Sugerman 01] [Kivity 09] [Bugnion 12] [Barham 03] [Popek 74] Hardware Support [Gum 83] [Adams 06] [Agesen 12] [Colp 11] [Bugnion 97] [Uhlig 05] [Bhargava 08] [Ben-Yehuda 10] [LeVasseur 04] [Wang 11] Optimizations Power [Waldspurger 02] [Liu 06] [Willmann 08] [Gordon 12] [Stoess 07] [Nathuji 07] [Hwang 12] [Amit 11] [Ye 10] [Krishnan 11] [Russell 08] [Ahmad 11] [Tian 10] [Andrus 11]

Virtualization Virtualization Software [Sugerman 01] [Kivity 09] [Bugnion 12] [Barham 03] [Popek 74] Hardware Support [Gum 83] [Adams 06] [Agesen 12] [Colp 11] [Bugnion 97] [Uhlig 05] [Bhargava 08] [Ben-Yehuda 10] [LeVasseur 04] [Wang 11] Optimizations Power [Waldspurger 02] [Liu 06] [Willmann 08] [Gordon 12] [Stoess 07] [Nathuji 07] [Hwang 12] [Amit 11] [Ye 10] [Krishnan 11] [Russell 08] [Ahmad 11] [Tian 10] [Andrus 11]

Virtualization [Popek 74] The mechanism through which we facilitate Virtual Machines Defined intuitively by Popek and Goldberg [Popek 74] to be:...an efficient, isolated duplicate of the real machine.

VMMs [Popek 74] Virtual Machine Monitor (VMM) Three properties VM VM 1. Efficiency 2. Resource control VMM Hardware 3. Equivalence

Virtualizable [Popek 74] Theorem: For any conventional third generation computer, a virtual machine monitor may be constructed if the set of sensitive instructions for that computer is a subset of the set of privileged instructions All sensitive instructions trap to the VMM Allows for trap-and-emulate

Revitalization in the nineties User vmx VM VMware workstation in 99 [Sugerman 01; Bugnion 12] Kernel vmm driver VMM Hardware

New Directions Xen and the art of Virtualization [Barham 03] Kernel-Based VM (KVM) [Kivity 09] Dom0 (QEMU) Dom1 Dom2 User QEMU VM Xen Kernel KVM Hardware Hardware

Hardware Support Virtualization Software [Sugerman 01] [Kivity 09] [Bugnion 12] [Barham 03] [Popek 74] Hardware Support [Gum 83] [Adams 06] [Agesen 12] [Colp 11] [Bugnion 97] [Uhlig 05] [Bhargava 08] [Ben-Yehuda 10] [LeVasseur 04] [Wang 11] Optimizations Power [Waldspurger 02] [Liu 06] [Willmann 08] [Gordon 12] [Stoess 07] [Nathuji 07] [Hwang 12] [Amit 11] [Ye 10] [Krishnan 11] [Russell 08] [Ahmad 11] [Tian 10] [Andrus 11]

Hardware Support Outline Intel VT-x and AMD-V Hardware vs. Software Hardware Memory Virtualization

Intel VT-x Non-Root traps sensitive instructions VM ENTRY VM EXIT Root Non-Root (VM)

Intel VT-x Nested Page Tables (NPT) Page Tables Guest Virtual Address MMU Guest Physical Address Nested Page Tables Host Physical Address

Hardware Support Not a new idea [Gum 83]

Hardware vs. Software Benefits not clear cut Comparison with software [Adams 06] show that especially IO-bound workloads are actually faster. example: in/out instruction sequences rewritten to single exit

Hardware vs. Software Hardware extensions have matured But, exits are still expensive... Still uses combination of hardware/software approach in commercial VMware products [Agesen 12]. Software methods still useful for nested virtualization [Ben-Yehuda 10]

Nested Page Tables gva gcr3 Nested page table gl 4 gva[47:39] GPA nl 4 1 SPA nl 3 SPA nl 2 SPA nl 1 SPA gl 4 GPA 2 3 4 5 gl 3 gl 2 gva[38:30] gva[29:21] nl 4 6 nl 4 11 nl 3 7 nl 3 12 nl 2 8 nl 2 13 nl 1 9 nl 1 14 gl 3 10 gl 2 15 Guest page table gl 1 gva[20:12] nl 4 16 nl 3 17 nl 2 18 nl 1 19 gl 1 20 gpa gva[11:0] ncr3 nl 4 21 nl 3 22 nl 2 23 nl 1 24 TLB Entry Value nl 4 nl 3 nl 2 nl 1 G SPA (b) Some concerning results [Bhargava 08]

Hardware Support Virtualization Software [Sugerman 01] [Kivity 09] [Bugnion 12] [Barham 03] [Popek 74] Hardware Support [Gum 83] [Adams 06] [Agesen 12] [Colp 11] [Bugnion 97] [Uhlig 05] [Bhargava 08] [Ben-Yehuda 10] [LeVasseur 04] [Wang 11] Optimizations Power [Waldspurger 02] [Liu 06] [Willmann 08] [Gordon 12] [Stoess 07] [Nathuji 07] [Hwang 12] [Amit 11] [Ye 10] [Krishnan 11] [Russell 08] [Ahmad 11] [Tian 10] [Andrus 11]

Optimizations Memory Consumption Paravirtualized drivers Direct Device Assignment Virtual Interrupts

Direct Device Assignment One major bottleneck is I/O Still far from bare metal Direct Device Assignment is a potential solution

Direct Device Assignment Liu et al. [Liu 06] propose to simply assign a device directly to a VM VM Driver VM Requires device support VMM Control messages trap to VMM IOMMUs can help [Willmann 08; Amit 11] Device Hardware

Virtual Interrupts Interrupts can limit CPU performance and I/O throughput Worse in VMs due to VMEXITs Especially bad on systems with high IRQ frequency

Virtual Interrupts IRQ Device NP Handler Host Device 1 Host Device 1 Host Device 1 Guest Device 0 handle_disk_irq() Host Device 1 Guest Device 0 handle_nic_irq() ELI [Gordon 12]: VMs handle interrupts for certain devices ELI uses a shadow Interrupt Descriptor Table (IDT) to let guest handle interrupts directly, while remaining in control of host devices

Virtual Interrupts

Hardware Support Virtualization Software [Sugerman 01] [Kivity 09] [Bugnion 12] [Barham 03] [Popek 74] Hardware Support [Gum 83] [Adams 06] [Agesen 12] [Colp 11] [Bugnion 97] [Uhlig 05] [Bhargava 08] [Ben-Yehuda 10] [LeVasseur 04] [Wang 11] Optimizations Power [Waldspurger 02] [Liu 06] [Willmann 08] [Gordon 12] [Stoess 07] [Nathuji 07] [Hwang 12] [Amit 11] [Ye 10] [Krishnan 11] [Russell 08] [Ahmad 11] [Tian 10] [Andrus 11]

Data Centers Amazon AWS hosts 46,000 servers 8 MW power consumption at $88 million / year

Power Architecture for VMs with different scopes. energy accounting Client Client Client Energy manager energy allocation Resource driver 1 Energy consuming resource 1 Resource driver 2 Energy consuming resource 2 Accounting model [Stoess 07] Problem is that VMMs are uninformed about VMs and VMs don t know their real power consumption (VMEXITs) Accounting model suggests passing allocation hints up the stack, and statistics down the stack

VirtualPower [Nathuji 07] Main idea: Present virtual ACPI states to VMs How does virtual ACPI states map to hardware states? Soft Scaling Information from ACPI can be aggregated in data centers with heterogenous hardware

CPU Consolidation The Effectiveness of CPU Consolidation [Hwang 12] Interesting related observation about exclusive caches in [Krishnan 2011]

Conclusion IBM Mainframe VMs VMware Workstation x86 Hardware Support Virtual Power I/O and Device Assignments?? 70s 99 03 05... 12 Paravirtualization Xen CPU and Memory Optimizations Virtual Interrupts ARM?

VM Power Metering Model: Upper and lower bounds on CPU and on Memory [Krishnan 11] Power consumption depends on how memory bound Depends on cache structures, L1 snooping wakes up other cores

I/O Power Savings Prolong sleep periods of mechanical disks [Ye10] Early flushes, and buffering writes Expose virtual per-device power state agents to VMs [Tian 10]

vic [Ahmad 11] Virtual Interrupt Coalescing Balance coalescing with latency Define a ratio R = Virtual IRQs / Hardware IRQs The lower R, the more coalescing Dynamically determine R based on Commands-In-Flight (CIF) and estimated IOPS