Chapter 2: Infrastructure as a Service (IaaS) Flashcards

1
Q

What is a Hypervisor?

A
  • is a program that allows multiple OS systems to share a single hardware host, each OS appears to have the host’s resources ie: processore, memeory, nic etc all to itself
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Name and explain Type 1 Hypervisor

A

Runs directly on hardware

  • More secure and more available
  • Offers better performance to the guests it supports
  • Requires special device drivers
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Name and explain Type 2 Hypervisor

A

Runs on top of an OS

  • Leverages the OS drivers
  • Often used for desktop development and testing
  • More overhead
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What are the Challenges for IaaS Providers?

A
  • Rapid provisioning
  • Elasticity
  • Isolation of different consumers
  • Performance
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Definition of Virtualization

A

Virtualization is the simulation of the software and/or hardware upon which other software runs. This simulated environment is called a virtual machine (VM).

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

What is the challenge of Elasticity for a Cloud?

A
  • Create illusion of infinite resources

- manage data center in a cost-efficient manner

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

What is the challenge Rapid Provisioning for a Cloud?

A
  • Resources must be available to the consumer quickly

- No human interaction during provisioning

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Taxonomy of Virtualization

A
  • Process Virtualization
  • OS Virtualization
  • System Virtualization
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

What is the VMM?

A

Virtual machine monitor

aka Hypervisor

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Name the three types of processor instructions.

A
  • Privileged instruction
  • Sensitive instructions
  • Unprivileged instructions
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

What is the necessary condition to the processor instructions for efficient virtualization (Popek and Goldberg-Theorem)?

A

Set of sensitive instructions is a subset of the set of privileged instructions. (=Condition satisfied)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

What are the three Hardware Virtualization techniques?

A
  • Full Virtualization
  • Paravirtualization (OS-Assisted)
  • Hardware-Assisted Virtualization
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

Define Full Virtualization.

A

Full Virtualization is virtualization in which the guest operating system is unaware that it is in a virtualized environment, and therefore hardware is virtualized by the host operating system.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

Define Paravirtualisation.

A

Software Assisted Virtualization (Paravirtualization) is virtualization in which the guest operating system is aware that it is a guest. Therefore the guest source code is modified so that it avoids assistance of the VMM as far as possible.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

Define Hardware-Assisted Virtualization.

A

Hardware Assisted Virtualization has special instructions to aid the virtualization of hardware. The guest can execute privileged instructions directly on the processor without affecting the host.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

Explain Full Virtualization using Binary Translation

A
  • Find critical instructions and replace them
    • Run unprivileged instructions directly on CPU
    • Trap and emulate privileged and sensitive instructions
    • Find critical instructions and replace with exception
  • Problem: Replacement must be done at runtime
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
17
Q

What is the MMU

A

Memory management unit (MMU) translates logical to physical memory addresses
by lookup the page table (logical page ←→ physical page)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
18
Q

What are Shadow Pages?

A

Shadow page tables solves the problem of additional memory access required to resolve address at full virtualisation. By mapping the logical pages of a process in the VM directly to the physical address.

19
Q

What are the classes of I/O devices

A
  1. Dedicated devices (e.g. display, keyboard, mouse, …)
    Not shared among VMs on a very long time scale
  2. Partitioned devices (e.g.disks)
    Partitions made available to VMs as dedicated devices
  3. Shared devices (e.g. network adapters)
    Shared among VMs on very fine-grained time scale
  4. Spooled devices (e.g.printers)
    Shared among VMs but with time higher granularity
  5. Non existent physical devices e.g.virtualNICs)
    Virtual devices without physical counterpart
20
Q

What is the idea for Paravirtualization (OS-Assisted)?

A

Idea of Paravirtualization:

  • Make guest OS aware that it is running in a VM
  • Modify the guest source code so that it avoids assistance of the VMM as far as possible
21
Q

How does Physical Memory Management with XEN work?

A

Domain gets fraction of phys. memory at creation time

  • Static partitioning among domains
  • No guarantee partition is contiguous
  • Hypervisor knows which domain „owns“ which pages
  • Each guest (Domain) needs which Blocks to use
22
Q

How does Virtual Memory Management with XEN work?

A

Command Batching:

  • Xen collects Requests and submits them with one hypercall
  • > Requests are not immediately processed
  • > Requires only one entry to hypervisor
23
Q

How does I/O Virtualization with XEN work?

A
  • XEN itself contains specific device drivers

- I/O data transferred from guests via XEN using shared-memory, async. buffer ring

24
Q

Explain how Binary Translation works

A
  1. Separate instruction sequence in translation units
  2. Check unit for critical instructions and modify code
  3. Modified code is stored in translation cache
25
Q

Name different levels of I/O virtualization possible

A
  1. At system call level
  2. At device driver level
  3. At I/O operation level
26
Q

What is the requirement for Paravirtualization (OS-Assisted)?

A

Requirements for pure OS-assisted approach:
- Source code of guest operating system is available
- Modified guest OS maintains application binary interface
Most common used for device driver virtualization. e.g. XEN

27
Q

Explain the procedure of Memory Virtualization with XEN work?

A
  1. Guest requests page table update via hypercall
  2. XEN checks if mapping address belongs to domain
  3. If ok, allows update to page table
28
Q

Explain I/O Virtualization with XEN work?

A

I/O data transferred from guests via XEN using shared-memory, async. buffer ring (circular buffer)
■ Descriptions reference guest’s memory pages

29
Q

Summary OS-Assisted Virtualization

A

Requires modified guest OS? YES
Requires hardware support? NO

+ Better performance through cooperation between hypervisor and guest OS

  • Limited compatibility, not generally applicable
  • Increased management overhead for data center operator, different version of OS must be maintained
30
Q

Summary of full virtualization

A

Requires modified Guest OS? YES
Requires hardware support? NO
Good approach for compute-intensive applications, because unprivileged instructions run directly on CPU

31
Q

Which Virtualization requires a modified guest OS?

A

OS-Assisted Virtualization

32
Q

Which Virtualization requires hardware support?

A

HW-Assisted Virtualization

33
Q

Performance of Full Virtualization

A

■ Good approach for compute-intensive applications
♦ Unprivileged instructions run directly on CPU
■ Degraded performance for data-intensive applications
♦ I/O requires syscallsprivileged instructions
♦ “trap and emulate” often requires context switches
♦ Context switches lead to complete flush of TLB

34
Q

Pros and Cons of OS-Assisted

A

+ Better performance through cooperation between hypervisor and guest OS

  • Limited compatibility, not generally applicable
  • Increased management overhead for data center operator, different version of OS must be maintained
35
Q

Pros and Cons of HW-Assisted

A

+ Improved performance even for unmodified guest OSs
+ Good adaption of 1st generation HW-support by VMMs
+ 2nd generation VMM support increasingly deployed
- Reduced flexibility due to hardware constraints (especially for 3rd generation HW support)

36
Q

First Generation of HW - Assisted Virtualization

A

Two new CPU modes: VMM runs in root mode vs. Guest OS in guest mode
VMM and guest run as “co-routines”
VMM can give CPU to guest OS (VM ENTER)
VMM can define conditions when to regain CPU (VM EXIT)
VMM uses control bits to “confine” and observe guest

37
Q

Second Generation of HW - Assisted Virtualization

A

Extended Page Tables/Nested Page Tables introduce HW support for memory virtualization
Translation lookaside buffer TBL continues to cache LA PA address translation
MMU composes LA RA and RA PA mapping at TLB fill time

38
Q

Third Generation of HW - Assisted Virtualization

A

Third generation support for virtualization focuses on I/O

39
Q

Design Focus of HW- Support: Direct Assignment

A

■ No sharing of device between several VMs
■ Guest VMs runs the unmodified device drivers
■ Goal: Efficient I/O without VMM intervention
■ Challenge: VMM must still ensure correctness & isolation

40
Q

Desired property: Live migration

A

■ No shutdown of the virtual machine
■ No disruption of the service
■ Minimal impact for the user
Minimize downtime and total migration time

41
Q

Strategies for Memory Migration

A
  1. Push phase
    ■ Source VM continues running, sends pages to destination ■ Memory must potentially be sent multiple times Minimum downtime, potentially long migration time
  2. Stop-and-copy phase
    ■ Source VM stopped, pages copied to destination VM
    ■ Destination VM is started after having received all pages Short overall migration time, long downtime
  3. Pull phase
    ■ Execute new VM, pull accessed pages from source Performance depends on number of page faults
42
Q

Resource Distribution among VMs

A

Storage space: statically partitioned
■ Each VM typically receives predefined fraction of disk
Main memory: statically partitioned
■ Each VM typically receives predefined fraction of RAM
CPU: Different methods possible
■ Pinning: Each VM is statically assigned CPU (cores)
■ Scheduling: VMM dynamically assigns time slots to VMs
I/O Access: Typically FCFS, see XEN ring buffer
■ More sophisticated methods subject to research!

43
Q

What means Virtual Machine Migration

A

Move VM from one physical host to another

44
Q

define shadow page tables? what does they do?

A

Shadow page tables solves the problem of additional memory access required to resolve address at full virtualisation. By mapping the logical pages of a process in the VM directly to the physical address.