Test for VT or HVM Stability

From The FluidVM Wiki

Jump to: navigation, search

Intel VT (Virtualization Technology) and AMD SVM(Secure Virtual Machine) extensions make it possible for the host OS to run unmodified guest operating systems. Although most chips(including Intel Atom!!) ship with these extensions these days, there needs to be support in the motherboard for VT to work well. Xen is know to crash the compute node instantaneously or even after a few minutes or seconds after a HVM based virtual machine is started.

If you need to be sure, first copy the following contents into a script named sample_vm.hvm

import os, re
arch = os.uname()[4]
if re.search('64', arch):
    arch_libdir = 'lib64'
else:
    arch_libdir = 'lib'

kernel = "/usr/lib/xen/boot/hvmloader"
builder='hvm'
memory = 128
shadow_memory = 8
name = "ExampleHVMDomain"
vif = [ 'type=ioemu, bridge=xenbr0' ]
disk = [ 'file:/home/user/dsl-4.2.5.iso,hdc:cdrom,r']
device_model = '/usr/' + arch_libdir + '/xen/bin/qemu-dm'
boot="d"
sdl=0
vnc=1
vncpasswd=''
serial='pty'

The only thing that you'll need to customize is the path of the ISO file. In this example, I have used a Damn Small Linux(DSL) ISO file. Damn Small Linux is a Linux Live CD that is capable of running off a business card sized CD-ROM disk and is about 50M in size. A DSL ISO is also made available as part of the default install of FluidVM and can be found in the /nbd directory on the management server. You can copy it over to a node you want to test or just download it from http://www.damnsmalllinux.org.

You'll then need to create an HVM domain with the following command:

xm create sample_vm.hvm

This should create a Xen HVM based virtual machine. You can verify this by punching in:

xm list

You must see it listed apart from the Domain-0. Leaving it running for about 30 minutes or so. If nothing happens, then we're good. If you compute node reboots immediately or hangs or reboots in a while, your hardware is incompatible with HVM Xen of the CentOS distribution.