Nethence Documentation Lab Webmail Your IP BBDock  

Those documents are obsolete, please use the Nethence Documentation instead.


HVM XEN guest
You'll never see (vmx|svm) in /proc/cpuinfo if you're currently running a dom0 or domU. The Xen hypervisor suppresses these flags in order to prevent hijacking. To check if Intel VT or SVM (formaly AMD-V) are available or enabled for HVM guests, on a non-xen system,
egrep '(vmx|svm)' /proc/cpuinfo
on a xen system,
xm dmesg | grep -i hvm
note. qemu comes with xen-tools, no need to install qemu seperately.
note. 32 and 64-bit guests both seem to work even as hvm (we're running xen4 with a 64-bit dom0 here)
Build guest's skeleton (harddrive and config file),
mkdir -p /data/guests/hvmguest/
cd /data/guests/hvmguest/
dd if=/dev/zero of=hvmguest.disk bs=1024k count=1 seek=10000
locate hvmloader
locate qemu-dm | grep bin
vi hvmguest
kernel = '/usr/lib/xen/boot/hvmloader'
device_model = '/usr/lib/xen/bin/qemu-dm'

name = 'hvmguest'
memory = 1024
disk = ['file:/data/guests/hvmguest/hvmguest.disk,hda,w',\
vif = [ 'type=ioemu,bridge=bridge0,vifname=vhvmguest.0' ]
boot = "dc"

note. change ISO-IMAGE accordingly
note. boot=dc to force the boot on cdrom
note. for FreeBSD 8.{1,2} only hda works (otherwise it will install but won't reboot...),
disk = ['file:/data/guests/hvmguest/hvmguest.disk,hda,w',\
note. for Redhat 6.2, sda is just fine (hda will make the installer stuck at format stage...),
disk = ['file:/data/guests/hvmguest/hvmguest.disk,sda,w',\
note. for Oracle Solaris 10, sda or hda doesn't matter yet, as the console doesn't show anything beyond the SunOS release and copyright statement.
note. for Oracle Solaris 11, only hda is recognized by the installer,
disk = ['file:/data/guests/hvmguest/hvmguest.disk,hda,w',\
note. for OpenSolaris 0906-x86, sda makes it dump at boot time. Try with hda?
disk = ['file:/data/guests/hvmguest/hvmguest.disk,hda,w',\
note. for Windows 2000, hda is fine,
disk = ['file:/data/guests/hvmguest/hvmguest.disk,hda,w',\
note. other iso-images,
Ready to go
Start the guest,
modprobe tun
#lsmod | grep tun
#ls -l /dev/net/tun
xm cr hvmguest
note. you can now connect with VNC (to the dom0 IP). Eventually choose US-English keyboard, as your VNC client deals with your keymap locally.
note. check Qemu launched the vnc server,
netstat -an --inet | egrep '59[0-9][0-9]'
note. eventually disable tcp offloading (see
Install the operating system and once finished, edit the guest configuration again,
cd /data/guests/hvmguest/
vi hvmguest
to remove the ISO-IMAGE line. Also comment 'boot = "dc"'

Last update: Sep 16, 2011