Wednesday, May 4, 2011

XEN images mount -block device

some brief:- A server with centos contain 10 Virtual machines, (xen virtual machine), i planned to migrate xen to KVM.

All VM run under LVM partition. So i start 1 vm and update kernel (non-xen kernel) and do the changes under grup.conf to make sure VM will boot under non xen kernel. After that system restart, after restart i realized i need some conf file..but this time system unable to boot.

So here i did some chnages in VM, to make boot under xen kernel.

here are the steps.

#fdisk -l /dev/vmImage/my1sqmail01

#kpartx -a /dev/vmImage/my1sqmail01

#ls -l /dev/mapper/

#mount -o rw /dev/mapper/my1sqmail01p1 /opt

#cd /opt/

#vi grub/grub.conf

here i change boot order make sure system boot under xen kernel..and save file.

#umount /opt

#kpartx -d /dev/vmImage/sgd1sqmail01


now run your VM and enjoyee..

0 comments: