Nuno Loureiro Ferreira
2009-Jul-03 23:18 UTC
[Xen-users] Migrating domU : image file based to LVM partition
Hey * I''ve some SL47 PV domU''s running on CentOS5.3 running Xen version 3.1.2-128.1.6.el5, created with virt-install. These domU''s are image file based, with only one partition inside (/). They are already configured for my purposes and its time to dump these domU''s to partitions (LVM partitions already in place) for performance reasons. And, I''m having problems doing it. 1 - How do I dump the content of a domU to a LVM partition? Did the following: kpartx -va domu.img mount /dev/mapper/loop0p1 /mnt/loop mount /dev/vg0/domu /mnt/domu cp -ax /mnt/loop /mnt/domu umount /mnt/domu; umount /mnt/loop; kpartx -vd domu.img A quick look inside /mnt/domu ... and all the original contents of the .img disk file seems to be there. Is there a more direct way of doing such procedure? 2 - After step 1) I edited the xen config file (see below) as well as the /etc/fstab and /boot/grub/menu.lst accordingly. But get the following error: xm create bdii-enmr.xen -c Using config file "./bdii-enmr.xen". No handlers could be found for logger "xend" Error: Disk isn''t accessible Usage: xm create <ConfigFile> [options] [vars] [... snip ...] name = "domu" maxmem = 512 memory = 512 vcpus = 1 bootloader = "/usr/bin/pygrub" on_poweroff = "destroy" on_reboot = "restart" on_crash = "restart" vfb = [ ] # Previously : #disk = [ "tap:aio:/data/enmr/domU/bdii/bdii-enmr.img,xvda,w", # "phy:vg0/domu.bdii_enmr.swap,/dev/xvda2,w" # ] # # Currently : disk = [ "phys:vg0/domu.main,xvda1,w", "phy:vg0/domu.swap,xvda2,w" ] vif = [ "mac=00:16:3E:0F:51:53,bridge=xenbr0" ] A couple of months ago I had some domu''s LVM based created by virt-install. And I was not having problems booting up the VM''s Cheers, N. P.S.Did the test, because I''m not receiving my own e-mails. Went to the xen-users mailing list membership configuration, and all seems ok. _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Fajar A. Nugraha
2009-Jul-03 23:36 UTC
Re: [Xen-users] Migrating domU : image file based to LVM partition
On Sat, Jul 4, 2009 at 6:18 AM, Nuno Loureiro Ferreira<nunolf@gmail.com> wrote:> # Currently : > disk = [ "phys:vg0/domu.main,xvda1,w",Extra "s"? Try phy:/dev/vg0/domu.main,xvda1,w -- Fajar _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Nuno Loureiro Ferreira
2009-Jul-03 23:41 UTC
Re: [Xen-users] Migrating domU : image file based to LVM partition
Hi Fajar I feel so stupid right now. Thanks, as usual. N. Fajar A. Nugraha wrote:> On Sat, Jul 4, 2009 at 6:18 AM, Nuno Loureiro Ferreira<nunolf@gmail.com> wrote: > >> # Currently : >> disk = [ "phys:vg0/domu.main,xvda1,w", >> > > Extra "s"? > Try phy:/dev/vg0/domu.main,xvda1,w > >_______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users