Introduction of Virtualization Technology
Introduction of Virtualization Technology
1 1
01 History of the Virtualization
1
02 Technologies of KVM
Confidential 保密 www.h3c.com 2
Current Plight of IT Industry
High cost
Decentralized management
strategy
3 3
Evolution of Server Virtualization Applications
OS(Ring1) OS(Ring1)
Nonprivileged
Ring2 instruction Sensitive non- Sensitive non-
privileged privileged
instructions instructions
Privileged Privileged
Ring1 Sensitive
instructions instructions
instructio
ns
Privileged
Ring0 instructions OS In a simulated
Ring0(VMM)
5 5
Para-virtualization
Working principle
Ring3 App Ring3 App • The Guest OS running on the Hypervisor has integrated
code related to para-virtualization, which enables the
Ring1 OS Ring1 OS Guest OS to work well with the Hypervisor to achieve
virtualization.
Sensitive non-privileged Sensitive non-privileged
instructions instructions • Hypervisor provides Hyper call interface to meet the key
kernel operations of Guest OS, such as memory
privileged privileged
instructions instructions management, interrupt and time synchronization
Advantage
Stuck in simulation
• The performance is very close to a physical machine
Hypercalls
Ring0(VMM) Disadvantage
6 6
Full virtualization
Solution: BT (Binary Translation, binary translation)
Working principle
Ring3 App Ring3 App • The Guest OS instruction segment performs the entire translation
before execution, and replaces the sensitive non-privileged
instructions with the corresponding privileged instructions in Ring0.
Ring1 OS Ring1 OS • Non-privileged instructions are executed directly.
Sensitive non- Sensitive non-
privileged privileged
• The privileged instruction is first trapped in the VMM, and the VMM
instructions instructions
implements this privileged instruction through a series of simulation
Technical bottleneck
Software simulation, which can be optimized and
can be improved. The space is small. It is urgent to
introduce new technologies to break technical
barriers.
8 8
Hardware Assisted Virtualization
virtual machine#1 virtual machine#2 virtual machine#3 virtual machine#N
Virtual
machine operating operating operating operating
system system system system
VMM function
Resource management/system scheduling/user interface
Input/input
VT—xconfiguration EPT configuration
Device simulation
VT—x
Physical
platform VT—x EPT VT-d
CPU0
resources Network
CPUn Storage
9 9
01 History of the Virtualization
1
02 Technologies of KVM
10 10
Hardware-assisted virtualization-CPU
11 11
CPU hardware virtualization—Intel VT-i
Ring 1 Ring 1 02
OS(Ring0) First: Break the limits: Expand the working mode of the
OS(Ring0)
CPU in the virtualized environment, and accurately
distinguish the sensitive instructions issued by the virtual
machine through the non-root identifier
VMCS VMCS
03
App(Ring3) Soul element: Introduce VMCS and new virtualization,
VMM can easily call new instructions, and the CPU
VMX root mode automatically completes the switch between root and
Ring 1 non-root modes
VMM(Ring0)
12 12
Hardware-assisted virtualization-memory
virtual machine #1 virtual machine #2 virtual machine #3 virtual machine #4
13 13
Hardware-assisted virtualization—memory (continued)
Virtual memory space
Virtual address
16 16
Summary
18 18