Download 投影片 1 - National Sun Yat

Survey
yes no Was this document useful for you?
   Thank you for your participation!

* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project

Document related concepts

Copland (operating system) wikipedia , lookup

Distributed operating system wikipedia , lookup

CP/M wikipedia , lookup

Spring (operating system) wikipedia , lookup

Berkeley Software Distribution wikipedia , lookup

Mobile operating system wikipedia , lookup

Linux wikipedia , lookup

Caldera OpenLinux wikipedia , lookup

Linux kernel wikipedia , lookup

Linux adoption wikipedia , lookup

OS/2 wikipedia , lookup

Smallfoot wikipedia , lookup

Security-focused operating system wikipedia , lookup

Transcript
An Introduction to Xen
Prof. Chih-Hung Wu
Dept. of Electrical Engineering
National University of Kaohsiung
Email: [email protected]
URL: http://www.johnw.idv.tw
ICAL
History of virtualization development
•
•
•
•
•
•
•
•
•
•
•
•
•
1965 IBM M44/44X paging system
1965 IBM System/360-67 virtual memory
hardware
1967 IBM CP-40 (January) and CP-67
(April) time-sharing
1972 IBM VM/370 run VM under VM
1997 Connectix First version of Virtual PC
1998 VMWare U.S. Patent 6,397,242
1999 VMware Virtual Platform for the
Intel IA-32 architecture
2000 IBM z/VM
2001 Connectix Virtual PC for Windows
2003 Microsoft acquired Connectix
2003 EMC acquired Vmware
2003 VERITAS acquired Ejascent
2005 HP Integrity Virtual Machines
•
•
•
•
•
•
•
•
•
•
2005 Intel VT
2006 AMD VT
2005 XEN
2006 VMWare Server
2006 Virtual PC 2006
2006 HP IVM Version 2.0
2006 Virtual Iron 3.1
2007 InnoTek VirtualBox
2007 KVM in Linux Kernel
2007 XEN in Linux Kernel
ICAL
What Is Xen?
• Xen aims to be able to execute multiple
operating systems on one physical x86
machine:
–
–
–
–
Support popular OS (Linux, Windows XP, NetBSD),
Scalable up to around 100 VMs,
Securely,
With close-to-native performance.
• Xen is a virtual machine monitor (VMM).
ICAL
What is Xen?
• The Xen® hypervisor, the powerful open source industry
standard for virtualization, offers a powerful, efficient, and
secure feature set for virtualization of x86, x86_64, IA64,
PowerPC, and other CPU architectures. It supports a wide
range of guest operating systems including Windows®,
Linux®, Solaris®, and various versions of the BSD operating
systems.
– Xen.org releases Xen 3.4 - The Yankee Groups Third Annual
Virtualization Survey reports a significant increase of commercial Xenbased solutions which represent 17 percent of total market share.
– "I think Xen is a great product. It is easy to use. But most importantly is
the very active community around it...", Werner Vogels,CTO
Amazon.com from his video interview on Virtualization.com
ICAL
Xen Architecture
Source: Xen and the Art of Virtualization (Xen 1.x.) Published at SOSP 2003
ICAL
Xen Jargon
• The hypervisor
– The Xen VMM
– A particular Xen version which handles low level
functionality
• Guest Operating System
– The operating system that Xen hosts
• Domain
– The virtual machine under which a guest operating
system executes
• Guest OS and a domain similar to idea of a
program and a process
ICAL
Xen Architecture (Cont.)
• Domain0 can use the admin interface to
command the hypervisor,
• Domain0 uses a privileged kernel (Dom0
kernel) capable of accessing the hardware
of the machine,
• Other guests use a DomU kernel which is
typically more restricted.
ICAL
Xen 3.4.0
• Available from Xen Source (http://www.xen.org )
• In association with University of Cambridge
(http://www.cl.cam.ac.uk/Research/SRG/netos/xen/)
• Support for 64-Bit and 32-way machines
• Supports IntelVT and AMD-V
• Linux support only, Windows expected later this year
• Open Source Product – One of the most actively
maintained projects in the open source community
• $ - Free
• Latest Current Version: Xen 3.4.0
ICAL
Xen
• Xen already is bundled in some distributions,
CentOS 5.3, Fedora Core 4, Debian and SuSE
Professional 9.3
• The Fedora Project has RPMs for installing
Xen, and other Linux distros have prepared
installation packages for Xen as well.
ICAL
Types of virtualization
• Two categories exist
– Full Virtualization
– Paravirtualization
ICAL
Paravirtualization -- Xen Approach
• Virtual machine is NOT 100% functionally
equivalent to the hardware
• Xen uses paravirtualization instead
• Paravirtualization is a process where the guest
operating system is modified to run in parallel
with other modified systems
– Advantage: Improved performance
– Disadvantage: The hosted operating system must
be modified before it can be hosted by the Xen
Hypervisor (can be difficult)
ICAL
Hypervisor Control
• In Xen
– Domain0 is given greater
access to the hardware
and the hypervisor. It has:
• A guest OS running above
the domain
• Hypervisor Manager
software to manage
elements within other
existing domains.
• In VMWare
– Host OS acts underneath
the domain.
Hypervisor Manager
Guest OS on Domain 0
Guest OS on Domain X
Domain 0
Domain 1
Hypervisor
Guest OS
Guest OS
VM Specific
Drivers
VM Specific
Drivers
VM
VM
VMWare
Host Operating System
VMWare
Drivers
Other
Drivers
ICAL
HVM in Xen
• Paravirtualization
– Xen patches the kernel.
• HVM for full virtualization
– Xen supports full virtualization so that the kernel
can run on it unpatched.
– For example, both Intel VT and AMD Pacifica
processors will include such support.
ICAL
Virtual Networking in Xen
Source: http://wiki.xensource.com/xenwiki/XenNetworking
ICAL
Virtual Networking in Xen
Source: http://wiki.xensource.com/xenwiki/XenNetworking
ICAL
Virtual Networking in Xen
Source: http://wiki.xensource.com/xenwiki/XenNetworking
ICAL
Virtual Networking in Xen
Source: http://wiki.xensource.com/xenwiki/XenNetworking
ICAL
Virtual Networking in Xen
Source: http://wiki.xensource.com/xenwiki/XenNetworking
ICAL
Live Migration
• Xen supports live migration over LAN,
• Uses ‘pre-copy’ method:
–
–
–
–
Iteratively copy memory,
Pause the VM,
Copy rest of the memory,
Start VM in on new machine.
• ARP is used to signal the network that the
IP has moved.
• Disk is provided by NAS.
ICAL
Requirements For Running Xen
• A working Linux distribution using the GRUB
bootloader and running on a P6-class (or newer) CPU,
• More than 1GB RAM (suggested)
• iproute2, bridge-utils, gcc, binutils, make, libcurldevel, zlib-dev, python-dev,
• Don’t need to reinstall to try it:
– Build Xen in your existing Linux install (which will
become Domain0),
– Use a file backed filesytem for guests.
• You can try it using a bootable live CD.
ICAL
Current Status (Xen 3.x)
•
•
•
•
•
Secure isolation between VMs,
Resource control and QoS,
Only guest kernel needs to be ported,
All user-level apps and libraries run unmodified
Linux 2.4/2.6, NetBSD, CentOS 5, FreeBSD, Plan9,
and more
• Execution performance is close to native,
• Supports the same hardware as Linux x86,
• Live Relocation of VMs between Xen nodes.
Source : Overview of Xen 3.0. Describes the progression from Xen 2.0 to 3.0.
ICAL
Performance
Relative performance on native Linux (L), Xen/Linux (X),
VMware Workstation 3.2 (V), and User Mode Linux (U).