Setup Debian Lenny PV & HVM DomUs (64-bit) sharing same image device at Xen 3.4.1 & Libvirt 0.7.1-10 Dom0 on top of F12 (rawhide) with pvops enabled kernel

Posting bellow provides a workaround for failure of straight forward virt-install Debian Lenny 64-bit DomU via location . It doesn’t require debootstrap involvement and would work on OpenSolaris 2010-02-124 and Solaris Nevada 124 as well. Download mini installer iso image and virt-install Lenny HVM DomU:-

# wget

# virt-install --debug -n Debian5HVM --hvm -r 1024 --vcpus=1 -f /dev/sda9 --vnc -c /home/boris/mini.iso

Login as root into HVM Debian DomU

# apt-get install linux-image-xen-amd64

Add entries to /boot/grub/menu.lst :-

title Debian GNU/Linux, kernel 2.6.26-2-amd64 (vfb)
root (hd0,0)
kernel /boot/vmlinuz-2.6.26-2-xen-amd64 root=/dev/xvda1 ro console=tty0
initrd /boot/initrd.img-2.6.26-2-xen-amd64

title Debian GNU/Linux, kernel 2.6.26-2-xen-amd64 (hvc0)
root (hd0,0)
kernel /boot/vmlinuz-2.6.26-2-xen-amd64 root=/dev/xvda1 ro console=hvc0
initrd /boot/initrd.img-2.6.26-2-xen-amd64

Modify /etc/inittab to support serial console ( just in case)

Shutdown HVM DomU
Create profile

name = "Debian5PV"
memory = 2048
vcpus = 1
vif = [ 'bridge=eth1' ]
disk = [ 'phy:/dev/sda9,xvda,w']
vfb= ['type=vnc,vncunused=1']

# xm create
# vncviewer localhost:0

Run in different terminal session

# virsh dumpxml Debian5PV > Debian5PV.xml

Shutdown PV DomU

# virsh define Debian5PV.xml

Installation on OSOL-2010-02-124

virt-install --hvm --name Debian5HVM --ram 1024 --vnc \
--os-type=linux --network bridge \
--disk path=/tank03/disk-linux,size=15,driver=phy,subdriver=zvol \
--cdrom /export/home/boris/mini.iso

Debian Lenny PV DomU profile

root@opensolaris:/export/home/boris/lenny# cat lenny.cfg
name = "Debian5PV"
memory = 2048
vcpus = 1
vif = [ ' ' ]
disk = [ 'phy:/dev/zvol/dsk/tank03/disk-linux,xvda,w']
vfb= ['type=vnc,vncunused=1']

# xm create lenny.cfg
# vncviewer localhost:0


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: