Intro To XEN
By Derek Carter (goozbach)
Http://www.friocorte.com/presentation
XEN Basics
What is XEN?
A paravirtualising virtual machine monitor
Xen Layout/Design
A hypervisor – xen.gz
A Host or Domain-0 OS – vmlinuz-XEN-0
Host OS provides all guest OS file access
One or more guest or Domain-U – vmlinuz-XEN-U
Can be file/lvm/network backed
XEN Installation
Prerequisites:
Linux OS (2.4 or 2.6 kernel)
Iproute2
Bridge-utils (for guest networking)
Twisted (again for guest networking)
Curl-devel
Zlib-devel
Python 2.2-devel
Installing XEN-0
Package based
FC4 uses kernel-XEN-0 and kernel-XEN-U packages
Source based
Follow install instructions from main documentation
Http://wwww.cl.cam.ac.uk/Research/SRG/netos/xen/readmes/user/user.html
Creating A Guest
Create a disk image
Use dd to create a sparse image file
Use mkfs to format image file
Create a Linux image file
Very easy with YUM
Create at least /dev/zero /dev/console and /dev/null
Use YUM with the --installroot switch
Other solutions exist
debbootstrap, gentoo stage 3 install, etc...
Commands Galore
xend
xm
Custom build scripts
Will be available atHttpp://www.friocorte.com/presentation
Advanced XEN
Guest pausing and restoration
Domain-U can be ‘paused’ where all instructions/memory is stored in a persistent state
Domain can then be restarted to it’s previous state
Guest Migration
Move a XEN domain-U to another XEN domain-0
New domain-0 host must be on the same layer 2 segment
Works best if domain-U uses a network backed vfd (eg. NFS) and vfd resides on a third host