SlideShare a Scribd company logo
Virtualization
Concepts
CS5204 –
Operating Systems
Virtualization
2
Concepts
 James Smith, Ravi Nair, “The Architectures of Virtual Machines,” IEEE Computer, May 2005, pp. 32-38.
 Mendel Rosenblum, Tal Garfinkel, “Virtual Machine Monitors: Current Technology and Future Trends,” IEEE Computer, May 2005, pp. 39-47.
 L.H. Seawright, R.A. MacKinnon, “VM/370 – a study of multiplicity and usefulness,” IBM Systems Journal, vol. 18, no. 1, 1979, pp. 4-17.
 S.T. King, G.W. Dunlap, P.M. Chen, “Operating System Support for Virtual Machines,” Proceedings of the 2003 USENIX Technical Conference,
June 9-14, 2003, San Antonio TX, pp. 71-84.
 A. Whitaker, R.S. Cox, M. Shaw, S.D. Gribble, “Rethinking the Design of Virtual Machine Monitors,” IEEE Computer, May 2005, pp. 57-62.
 G.J. Popek, and R.P. Goldberg, “Formal requirements for virtualizable third generation architectures,” CACM, vol. 17 no. 7, 1974, pp. 412-421.
References and Sources
CS5204 –
Operating Systems
Virtualization
3
Definitions
 Virtualization
 A layer mapping its visible interface and resources onto the
interface and resources of the underlying layer or system on
which it is implemented
 Purposes
 Abstraction – to simplify the use of the underlying resource (e.g., by
removing details of the resource’s structure)
 Replication – to create multiple instances of the resource (e.g., to simplify
management or allocation)
 Isolation – to separate the uses which clients make of the underlying
resources (e.g., to improve security)
 Virtual Machine Monitor (VMM)
 A virtualization system that partitions a single physical
“machine” into multiple virtual machines.
 Terminology
 Host – the machine and/or software on which the VMM is implemented
 Guest – the OS which executes under the control of the VMM
CS5204 –
Operating Systems
Virtualization
4
Origins - Principles
 Efficiency
 Innocuous instructions should
execute directly on the hardware
 Resource control
 Executed programs may not affect
the system resources
 Equivalence
 The behavior of a program executing
under the VMM should be the same as
if the program were executed directly
on the hardware (except possibly for
timing and resource availability) Communications of the ACM, vol 17, no 7, 1974, pp.412-421
“an efficient, isolated duplicate of the real machine”
CS5204 –
Operating Systems
Virtualization
5
Origins - Principles
Instruction types
 Privileged
an instruction traps in unprivileged (user) mode but not in privileged (supervisor) mode.
 Sensitive
Control sensitive –
attempts to change the memory allocation or privilege mode
Behavior sensitive
 Location sensitive – execution behavior depends on location in memory
 Mode sensitive – execution behavior depends on the privilege mode
 Innocuous – an instruction that is not sensitive
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.
Signficance
The IA-32/x86 architecture is not virtualizable.
CS5204 –
Operating Systems
Virtualization
6
Origins - Technology
 Concurrent execution of multiple production operating systems
 Testing and development of experimental systems
 Adoption of new systems with continued use of legacy systems
 Ability to accommodate applications requiring special-purpose OS
 Introduced notions of “handshake” and “virtual-equals-real mode” to allow
sharing of resource control information with CP
 Leveraged ability to co-design hardware, VMM, and guestOS
IBM Systems Journal, vol. 18, no. 1, 1979, pp. 4-17.
CS5204 –
Operating Systems
Virtualization
7
VMMs Rediscovered
 Server/workload consolidation (reduces “server sprawl”)
 Compatible with evolving multi-core architectures
 Simplifies software distributions for complex environments
 “Whole system” (workload) migration
 Improved data-center management and efficiency
 Additional services (workload isolation) added “underneath” the OS
 security (intrusion detection, sandboxing,…)
 fault-tolerance (checkpointing, roll-back/recovery)
VMM
VirtualVirtual
MachineMachine
Guest OS
Application
VirtualVirtual
MachineMachine
Guest OS
Application
VirtualVirtual
MachineMachine
Guest OS
Application
Real
Machine
CS5204 –
Operating Systems
Virtualization
8
Architecture & Interfaces
 Architecture: formal specification of a system’s interface and the logical
behavior of its visible resources.
Hardware
System ISA User ISA
Operating
System
System Calls
Libraries
Applications
ISA
ABI
API
 API – application binary interface
 ABI – application binary interface
 ISA – instruction set architecture
CS5204 –
Operating Systems
Virtualization
9
VMM Types
 System
 Process
 Provides ABI interface
 Efficient execution
 Can add OS-independent
services (e.g., migration,
intrustion detection)
 Provdes API interface
 Easier installation
 Leverage OS services (e.g.,
device drivers)
 Execution overhead (possibly
mitigated by just-in-time
compilation)
CS5204 –
Operating Systems
Virtualization
10
System-level Design Approaches
 Full virtualization (direct execution)
 Exact hardware exposed to OS
 Efficient execution
 OS runs unchanged
 Requires a “virtualizable” architecture
 Example: VMWare
 Paravirtualization
 OS modified to execute under VMM
 Requires porting OS code
 Execution overhead
 Necessary for some (popular) architectures (e.g., x86)
 Examples: Xen, Denali
CS5204 –
Operating Systems
Virtualization
11
Design Space (level vs. ISA)
 Variety of techniques and approaches available
 Critical technology space highlighted
API interface ABI interface
CS5204 –
Operating Systems
Virtualization
12
System VMMs
 Structure
 Type 1: runs directly on host hardware
 Type 2: runs on HostOS
 Primary goals
 Type 1: High performance
 Type 2: Ease of
construction/installation/acceptability
 Examples
 Type 1: VMWare ESX Server, Xen, OS/370
 Type 2: User-mode Linux
Type 1
Type 2
CS5204 –
Operating Systems
Virtualization
13
Hosted VMMs
 Structure
 Hybrid between Type1 and Type2
 Core VMM executes directly on hardware
 I/O services provided by code running on HostOS
 Goals
 Improve performance overall
 leverages I/O device support on the HostOS
 Disadvantages
 Incurs overhead on I/O operations
 Lacks performance isolation and performance
guarantees
 Example: VMWare (Workstation)
CS5204 –
Operating Systems
Virtualization
14
Whole-system VMMs
 Challenge: GuestOS ISA differs from HostOS
ISA
 Requires full emulation of GuestOS and its
applications
 Example: VirtualPC
CS5204 –
Operating Systems
Virtualization
15
Strategies
 De-privileging
 VMM emulates the effect on system/hardware
resources of privileged instructions whose
execution traps into the VMM
 aka trap-and-emulate
 Typically achieved by running GuestOS at a lower
hardware priority level than the VMM
 Problematic on some architectures where
privileged instructions do not trap when executed
at deprivileged priority
 Primary/shadow structures
 VMM maintains “shadow” copies of critical
structures whose “primary” versions are
manipulated by the GuestOS
 e.g., page tables
 Primary copies needed to insure correct
environment visible to GuestOS
 Memory traces
 Controlling access to memory so that the shadow
and primary structure remain coherent
 Common strategy: write-protect primary copies
so that update operations cause page faults
which can be caught, interpreted, and emulated.
resource
vmm
privileged
instruction
trap
GuestOS
resource
emulate change
change
CS5204 –
Operating Systems
Virtualization
16
Virtualizing the IA-32 (x86) architecture
 Architecture has protection rings 0..3 with OS normally in ring 0 and
applications in ring 3…
 …and VMM must run in ring 0 to maintain its integrity and control
 …but GuestOS not running in ring 0 is problematic:
 Some privileged instructions execute only in ring 0 but do not fault when
executed outside ring 0 (remember privileged vs. sensitive?)
 instructions for low latency system calls (SYSENTER/SYSEXIT) always
transition to ring 0 forcing the VMM into unwanted emulation or overhead
 For the Itanium architecture, interrupt registers only accessible in ring 0;
forcing VMM to intercept each device driver access to these registers has
severe performance consequences
 Masking interrupts can only be done in ring 0
 Ring compression: paging does not distinguish privilege levels 0-2,
GuestOS must run in ring 3 but is then not protected from its applications
also running in ring 3
 Cannot be used for 64-bit guests on IA-32
 The fact that it is not running in ring 0 can be detected (is this important?)
CS5204 –
Operating Systems
Virtualization
17
Memory Management
 Isolation/protection of
Guest OS address spaces
 Efficient MM address
translation
VMM
machine
VMM GuestOS
“shadow” page tables page tables
process
virtual
OS
physical
entity
address space

More Related Content

Similar to Vmm concepts

virtualization.pptx
virtualization.pptxvirtualization.pptx
virtualization.pptx
ssuser6e6eec
 
IaaS - Virtualization_Cambridge.pdf
IaaS - Virtualization_Cambridge.pdfIaaS - Virtualization_Cambridge.pdf
IaaS - Virtualization_Cambridge.pdf
DharavathRamesh2
 
Virtualization and cloud Computing
Virtualization and cloud ComputingVirtualization and cloud Computing
Virtualization and cloud Computing
Rishikese MR
 
Disco: Running Commodity Operating Systems on Scalable Multiprocessors Disco
Disco: Running Commodity Operating Systems on Scalable Multiprocessors DiscoDisco: Running Commodity Operating Systems on Scalable Multiprocessors Disco
Disco: Running Commodity Operating Systems on Scalable Multiprocessors Disco
Magnus Backman
 
Cloud Computing Virtualization and containers
Cloud Computing Virtualization and containersCloud Computing Virtualization and containers
Cloud Computing Virtualization and containers
Selvaraj Kesavan
 
Chapter 5 – Cloud Resource Virtua.docx
Chapter 5 – Cloud Resource                        Virtua.docxChapter 5 – Cloud Resource                        Virtua.docx
Chapter 5 – Cloud Resource Virtua.docx
madlynplamondon
 
Chapter 5 – Cloud Resource Virtua.docx
Chapter 5 – Cloud Resource                        Virtua.docxChapter 5 – Cloud Resource                        Virtua.docx
Chapter 5 – Cloud Resource Virtua.docx
gertrudebellgrove
 
Virtualization for Cloud Environment
Virtualization for Cloud EnvironmentVirtualization for Cloud Environment
Virtualization for Cloud Environment
Dr. Sunil Kr. Pandey
 
Virtualization
VirtualizationVirtualization
Virtualization
vishnurk
 
VIRTUAL MACHINE VERSATILE PLATFORM01~chapter 1 (1).ppt
VIRTUAL MACHINE VERSATILE PLATFORM01~chapter 1 (1).pptVIRTUAL MACHINE VERSATILE PLATFORM01~chapter 1 (1).ppt
VIRTUAL MACHINE VERSATILE PLATFORM01~chapter 1 (1).ppt
nagarajans87
 
Lecture 1-vs.pptx.......................
Lecture 1-vs.pptx.......................Lecture 1-vs.pptx.......................
Lecture 1-vs.pptx.......................
HassamShahid2
 
CloudComputing_UNIT 2.pdf
CloudComputing_UNIT 2.pdfCloudComputing_UNIT 2.pdf
CloudComputing_UNIT 2.pdf
khan593595
 
CloudComputing_UNIT 2.pdf
CloudComputing_UNIT 2.pdfCloudComputing_UNIT 2.pdf
CloudComputing_UNIT 2.pdf
khan593595
 
VSS-1.pdf
VSS-1.pdfVSS-1.pdf
VSS-1.pdf
RiyaBatool
 
Vitualisation
VitualisationVitualisation
Vitualisation
Priya_Srivastava
 
Virtualization Approach: Theory and Application
Virtualization Approach: Theory and ApplicationVirtualization Approach: Theory and Application
Virtualization Approach: Theory and Application
Universitas Pembangunan Panca Budi
 
Virtualization and Cloud Computing
Virtualization and Cloud ComputingVirtualization and Cloud Computing
Virtualization and Cloud Computing
Josh Folgado
 

Similar to Vmm concepts (20)

virtualization.pptx
virtualization.pptxvirtualization.pptx
virtualization.pptx
 
IaaS - Virtualization_Cambridge.pdf
IaaS - Virtualization_Cambridge.pdfIaaS - Virtualization_Cambridge.pdf
IaaS - Virtualization_Cambridge.pdf
 
Virtualization and cloud Computing
Virtualization and cloud ComputingVirtualization and cloud Computing
Virtualization and cloud Computing
 
Disco: Running Commodity Operating Systems on Scalable Multiprocessors Disco
Disco: Running Commodity Operating Systems on Scalable Multiprocessors DiscoDisco: Running Commodity Operating Systems on Scalable Multiprocessors Disco
Disco: Running Commodity Operating Systems on Scalable Multiprocessors Disco
 
Cloud Computing Virtualization and containers
Cloud Computing Virtualization and containersCloud Computing Virtualization and containers
Cloud Computing Virtualization and containers
 
Chapter 5 – Cloud Resource Virtua.docx
Chapter 5 – Cloud Resource                        Virtua.docxChapter 5 – Cloud Resource                        Virtua.docx
Chapter 5 – Cloud Resource Virtua.docx
 
Chapter 5 – Cloud Resource Virtua.docx
Chapter 5 – Cloud Resource                        Virtua.docxChapter 5 – Cloud Resource                        Virtua.docx
Chapter 5 – Cloud Resource Virtua.docx
 
Virtualization for Cloud Environment
Virtualization for Cloud EnvironmentVirtualization for Cloud Environment
Virtualization for Cloud Environment
 
Virtualization
VirtualizationVirtualization
Virtualization
 
VIRTUAL MACHINE VERSATILE PLATFORM01~chapter 1 (1).ppt
VIRTUAL MACHINE VERSATILE PLATFORM01~chapter 1 (1).pptVIRTUAL MACHINE VERSATILE PLATFORM01~chapter 1 (1).ppt
VIRTUAL MACHINE VERSATILE PLATFORM01~chapter 1 (1).ppt
 
Lecture 1-vs.pptx.......................
Lecture 1-vs.pptx.......................Lecture 1-vs.pptx.......................
Lecture 1-vs.pptx.......................
 
Virtualization 101
Virtualization 101Virtualization 101
Virtualization 101
 
CloudComputing_UNIT 2.pdf
CloudComputing_UNIT 2.pdfCloudComputing_UNIT 2.pdf
CloudComputing_UNIT 2.pdf
 
CloudComputing_UNIT 2.pdf
CloudComputing_UNIT 2.pdfCloudComputing_UNIT 2.pdf
CloudComputing_UNIT 2.pdf
 
VSS-1.pdf
VSS-1.pdfVSS-1.pdf
VSS-1.pdf
 
Vitualisation
VitualisationVitualisation
Vitualisation
 
Handout2o
Handout2oHandout2o
Handout2o
 
Virtualization Approach: Theory and Application
Virtualization Approach: Theory and ApplicationVirtualization Approach: Theory and Application
Virtualization Approach: Theory and Application
 
Virtualization and Cloud Computing
Virtualization and Cloud ComputingVirtualization and Cloud Computing
Virtualization and Cloud Computing
 
Usenix Invited Talk
Usenix Invited TalkUsenix Invited Talk
Usenix Invited Talk
 

Recently uploaded

Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !
KatiaHIMEUR1
 
Transcript: Selling digital books in 2024: Insights from industry leaders - T...
Transcript: Selling digital books in 2024: Insights from industry leaders - T...Transcript: Selling digital books in 2024: Insights from industry leaders - T...
Transcript: Selling digital books in 2024: Insights from industry leaders - T...
BookNet Canada
 
AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...
AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...
AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...
Product School
 
Elevating Tactical DDD Patterns Through Object Calisthenics
Elevating Tactical DDD Patterns Through Object CalisthenicsElevating Tactical DDD Patterns Through Object Calisthenics
Elevating Tactical DDD Patterns Through Object Calisthenics
Dorra BARTAGUIZ
 
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
James Anderson
 
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...
Ramesh Iyer
 
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
Product School
 
DevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA ConnectDevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA Connect
Kari Kakkonen
 
The Art of the Pitch: WordPress Relationships and Sales
The Art of the Pitch: WordPress Relationships and SalesThe Art of the Pitch: WordPress Relationships and Sales
The Art of the Pitch: WordPress Relationships and Sales
Laura Byrne
 
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
UiPathCommunity
 
FIDO Alliance Osaka Seminar: Overview.pdf
FIDO Alliance Osaka Seminar: Overview.pdfFIDO Alliance Osaka Seminar: Overview.pdf
FIDO Alliance Osaka Seminar: Overview.pdf
FIDO Alliance
 
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
Product School
 
How world-class product teams are winning in the AI era by CEO and Founder, P...
How world-class product teams are winning in the AI era by CEO and Founder, P...How world-class product teams are winning in the AI era by CEO and Founder, P...
How world-class product teams are winning in the AI era by CEO and Founder, P...
Product School
 
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
DanBrown980551
 
Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...
Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...
Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...
Product School
 
When stars align: studies in data quality, knowledge graphs, and machine lear...
When stars align: studies in data quality, knowledge graphs, and machine lear...When stars align: studies in data quality, knowledge graphs, and machine lear...
When stars align: studies in data quality, knowledge graphs, and machine lear...
Elena Simperl
 
Neuro-symbolic is not enough, we need neuro-*semantic*
Neuro-symbolic is not enough, we need neuro-*semantic*Neuro-symbolic is not enough, we need neuro-*semantic*
Neuro-symbolic is not enough, we need neuro-*semantic*
Frank van Harmelen
 
From Siloed Products to Connected Ecosystem: Building a Sustainable and Scala...
From Siloed Products to Connected Ecosystem: Building a Sustainable and Scala...From Siloed Products to Connected Ecosystem: Building a Sustainable and Scala...
From Siloed Products to Connected Ecosystem: Building a Sustainable and Scala...
Product School
 
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdfFIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance
 
UiPath Test Automation using UiPath Test Suite series, part 3
UiPath Test Automation using UiPath Test Suite series, part 3UiPath Test Automation using UiPath Test Suite series, part 3
UiPath Test Automation using UiPath Test Suite series, part 3
DianaGray10
 

Recently uploaded (20)

Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !
 
Transcript: Selling digital books in 2024: Insights from industry leaders - T...
Transcript: Selling digital books in 2024: Insights from industry leaders - T...Transcript: Selling digital books in 2024: Insights from industry leaders - T...
Transcript: Selling digital books in 2024: Insights from industry leaders - T...
 
AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...
AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...
AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...
 
Elevating Tactical DDD Patterns Through Object Calisthenics
Elevating Tactical DDD Patterns Through Object CalisthenicsElevating Tactical DDD Patterns Through Object Calisthenics
Elevating Tactical DDD Patterns Through Object Calisthenics
 
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
 
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...
 
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
 
DevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA ConnectDevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA Connect
 
The Art of the Pitch: WordPress Relationships and Sales
The Art of the Pitch: WordPress Relationships and SalesThe Art of the Pitch: WordPress Relationships and Sales
The Art of the Pitch: WordPress Relationships and Sales
 
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
 
FIDO Alliance Osaka Seminar: Overview.pdf
FIDO Alliance Osaka Seminar: Overview.pdfFIDO Alliance Osaka Seminar: Overview.pdf
FIDO Alliance Osaka Seminar: Overview.pdf
 
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
 
How world-class product teams are winning in the AI era by CEO and Founder, P...
How world-class product teams are winning in the AI era by CEO and Founder, P...How world-class product teams are winning in the AI era by CEO and Founder, P...
How world-class product teams are winning in the AI era by CEO and Founder, P...
 
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
 
Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...
Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...
Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...
 
When stars align: studies in data quality, knowledge graphs, and machine lear...
When stars align: studies in data quality, knowledge graphs, and machine lear...When stars align: studies in data quality, knowledge graphs, and machine lear...
When stars align: studies in data quality, knowledge graphs, and machine lear...
 
Neuro-symbolic is not enough, we need neuro-*semantic*
Neuro-symbolic is not enough, we need neuro-*semantic*Neuro-symbolic is not enough, we need neuro-*semantic*
Neuro-symbolic is not enough, we need neuro-*semantic*
 
From Siloed Products to Connected Ecosystem: Building a Sustainable and Scala...
From Siloed Products to Connected Ecosystem: Building a Sustainable and Scala...From Siloed Products to Connected Ecosystem: Building a Sustainable and Scala...
From Siloed Products to Connected Ecosystem: Building a Sustainable and Scala...
 
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdfFIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
 
UiPath Test Automation using UiPath Test Suite series, part 3
UiPath Test Automation using UiPath Test Suite series, part 3UiPath Test Automation using UiPath Test Suite series, part 3
UiPath Test Automation using UiPath Test Suite series, part 3
 

Vmm concepts

  • 2. CS5204 – Operating Systems Virtualization 2 Concepts  James Smith, Ravi Nair, “The Architectures of Virtual Machines,” IEEE Computer, May 2005, pp. 32-38.  Mendel Rosenblum, Tal Garfinkel, “Virtual Machine Monitors: Current Technology and Future Trends,” IEEE Computer, May 2005, pp. 39-47.  L.H. Seawright, R.A. MacKinnon, “VM/370 – a study of multiplicity and usefulness,” IBM Systems Journal, vol. 18, no. 1, 1979, pp. 4-17.  S.T. King, G.W. Dunlap, P.M. Chen, “Operating System Support for Virtual Machines,” Proceedings of the 2003 USENIX Technical Conference, June 9-14, 2003, San Antonio TX, pp. 71-84.  A. Whitaker, R.S. Cox, M. Shaw, S.D. Gribble, “Rethinking the Design of Virtual Machine Monitors,” IEEE Computer, May 2005, pp. 57-62.  G.J. Popek, and R.P. Goldberg, “Formal requirements for virtualizable third generation architectures,” CACM, vol. 17 no. 7, 1974, pp. 412-421. References and Sources
  • 3. CS5204 – Operating Systems Virtualization 3 Definitions  Virtualization  A layer mapping its visible interface and resources onto the interface and resources of the underlying layer or system on which it is implemented  Purposes  Abstraction – to simplify the use of the underlying resource (e.g., by removing details of the resource’s structure)  Replication – to create multiple instances of the resource (e.g., to simplify management or allocation)  Isolation – to separate the uses which clients make of the underlying resources (e.g., to improve security)  Virtual Machine Monitor (VMM)  A virtualization system that partitions a single physical “machine” into multiple virtual machines.  Terminology  Host – the machine and/or software on which the VMM is implemented  Guest – the OS which executes under the control of the VMM
  • 4. CS5204 – Operating Systems Virtualization 4 Origins - Principles  Efficiency  Innocuous instructions should execute directly on the hardware  Resource control  Executed programs may not affect the system resources  Equivalence  The behavior of a program executing under the VMM should be the same as if the program were executed directly on the hardware (except possibly for timing and resource availability) Communications of the ACM, vol 17, no 7, 1974, pp.412-421 “an efficient, isolated duplicate of the real machine”
  • 5. CS5204 – Operating Systems Virtualization 5 Origins - Principles Instruction types  Privileged an instruction traps in unprivileged (user) mode but not in privileged (supervisor) mode.  Sensitive Control sensitive – attempts to change the memory allocation or privilege mode Behavior sensitive  Location sensitive – execution behavior depends on location in memory  Mode sensitive – execution behavior depends on the privilege mode  Innocuous – an instruction that is not sensitive 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. Signficance The IA-32/x86 architecture is not virtualizable.
  • 6. CS5204 – Operating Systems Virtualization 6 Origins - Technology  Concurrent execution of multiple production operating systems  Testing and development of experimental systems  Adoption of new systems with continued use of legacy systems  Ability to accommodate applications requiring special-purpose OS  Introduced notions of “handshake” and “virtual-equals-real mode” to allow sharing of resource control information with CP  Leveraged ability to co-design hardware, VMM, and guestOS IBM Systems Journal, vol. 18, no. 1, 1979, pp. 4-17.
  • 7. CS5204 – Operating Systems Virtualization 7 VMMs Rediscovered  Server/workload consolidation (reduces “server sprawl”)  Compatible with evolving multi-core architectures  Simplifies software distributions for complex environments  “Whole system” (workload) migration  Improved data-center management and efficiency  Additional services (workload isolation) added “underneath” the OS  security (intrusion detection, sandboxing,…)  fault-tolerance (checkpointing, roll-back/recovery) VMM VirtualVirtual MachineMachine Guest OS Application VirtualVirtual MachineMachine Guest OS Application VirtualVirtual MachineMachine Guest OS Application Real Machine
  • 8. CS5204 – Operating Systems Virtualization 8 Architecture & Interfaces  Architecture: formal specification of a system’s interface and the logical behavior of its visible resources. Hardware System ISA User ISA Operating System System Calls Libraries Applications ISA ABI API  API – application binary interface  ABI – application binary interface  ISA – instruction set architecture
  • 9. CS5204 – Operating Systems Virtualization 9 VMM Types  System  Process  Provides ABI interface  Efficient execution  Can add OS-independent services (e.g., migration, intrustion detection)  Provdes API interface  Easier installation  Leverage OS services (e.g., device drivers)  Execution overhead (possibly mitigated by just-in-time compilation)
  • 10. CS5204 – Operating Systems Virtualization 10 System-level Design Approaches  Full virtualization (direct execution)  Exact hardware exposed to OS  Efficient execution  OS runs unchanged  Requires a “virtualizable” architecture  Example: VMWare  Paravirtualization  OS modified to execute under VMM  Requires porting OS code  Execution overhead  Necessary for some (popular) architectures (e.g., x86)  Examples: Xen, Denali
  • 11. CS5204 – Operating Systems Virtualization 11 Design Space (level vs. ISA)  Variety of techniques and approaches available  Critical technology space highlighted API interface ABI interface
  • 12. CS5204 – Operating Systems Virtualization 12 System VMMs  Structure  Type 1: runs directly on host hardware  Type 2: runs on HostOS  Primary goals  Type 1: High performance  Type 2: Ease of construction/installation/acceptability  Examples  Type 1: VMWare ESX Server, Xen, OS/370  Type 2: User-mode Linux Type 1 Type 2
  • 13. CS5204 – Operating Systems Virtualization 13 Hosted VMMs  Structure  Hybrid between Type1 and Type2  Core VMM executes directly on hardware  I/O services provided by code running on HostOS  Goals  Improve performance overall  leverages I/O device support on the HostOS  Disadvantages  Incurs overhead on I/O operations  Lacks performance isolation and performance guarantees  Example: VMWare (Workstation)
  • 14. CS5204 – Operating Systems Virtualization 14 Whole-system VMMs  Challenge: GuestOS ISA differs from HostOS ISA  Requires full emulation of GuestOS and its applications  Example: VirtualPC
  • 15. CS5204 – Operating Systems Virtualization 15 Strategies  De-privileging  VMM emulates the effect on system/hardware resources of privileged instructions whose execution traps into the VMM  aka trap-and-emulate  Typically achieved by running GuestOS at a lower hardware priority level than the VMM  Problematic on some architectures where privileged instructions do not trap when executed at deprivileged priority  Primary/shadow structures  VMM maintains “shadow” copies of critical structures whose “primary” versions are manipulated by the GuestOS  e.g., page tables  Primary copies needed to insure correct environment visible to GuestOS  Memory traces  Controlling access to memory so that the shadow and primary structure remain coherent  Common strategy: write-protect primary copies so that update operations cause page faults which can be caught, interpreted, and emulated. resource vmm privileged instruction trap GuestOS resource emulate change change
  • 16. CS5204 – Operating Systems Virtualization 16 Virtualizing the IA-32 (x86) architecture  Architecture has protection rings 0..3 with OS normally in ring 0 and applications in ring 3…  …and VMM must run in ring 0 to maintain its integrity and control  …but GuestOS not running in ring 0 is problematic:  Some privileged instructions execute only in ring 0 but do not fault when executed outside ring 0 (remember privileged vs. sensitive?)  instructions for low latency system calls (SYSENTER/SYSEXIT) always transition to ring 0 forcing the VMM into unwanted emulation or overhead  For the Itanium architecture, interrupt registers only accessible in ring 0; forcing VMM to intercept each device driver access to these registers has severe performance consequences  Masking interrupts can only be done in ring 0  Ring compression: paging does not distinguish privilege levels 0-2, GuestOS must run in ring 3 but is then not protected from its applications also running in ring 3  Cannot be used for 64-bit guests on IA-32  The fact that it is not running in ring 0 can be detected (is this important?)
  • 17. CS5204 – Operating Systems Virtualization 17 Memory Management  Isolation/protection of Guest OS address spaces  Efficient MM address translation VMM machine VMM GuestOS “shadow” page tables page tables process virtual OS physical entity address space