[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: [Xen-users] LVM and VMM



You haven't said if you are creating HVMs ... but HVMs have disks associated 
with them. PVMs can (must?) have partitions. I only use partitions with PVMs so 
I don't know if a PVM will accept a simulated disk from which it finds the 
partitions. 

> -----Original Message-----
> From: Dylan Martin [mailto:dmartin@xxxxxxxxxxxx]
> Sent: Monday, September 17, 2007 5:28 PM
> To: Thomas King
> Cc: xen-users@xxxxxxxxxxxxxxxxxxx
> Subject: Re: [Xen-users] LVM and VMM
> 
> 
> I don't think it works to assign partitions on dom0 as partitions on
> domU.  I think you have to assign partitions on dom0 as whole block
> devices on domU.  So, you'd make an LV on dom0, assign it as hda (or
> whatever) in the config file, and then using the OS installer, break
> it up into more partitions and LVs.
> 
> I use Fedora, and the text only installer doesn't do LVM very well, so
> I pre-configure my LV from inside dom0.  Here's how:
> 
> (Note: this syntax may not be correct as I'm just running from memory,
> but it should point you in the right direction.)
> 
> - First make an LV, I'll call it /dev/vg/fred
> - Run fdisk /dev/vg/fred and divide into two partitions.  The 
> 1st is 500
>   Megs for /boot the 2nd gets the rest of the space
> - run kpartx -a /dev/vg/fred to create /dev/mapper/vg-fredp1 and
>   /dev/mapper/vg-fredp2
> - make /dev/mapper/vg-fredp2 a PV with pvcreate
> - make a new vg, I'll call it barney, with /dev/mapper/vg-fred2 as
>   it's only member PV.
> - create LVs for your domU e.g. lvcreate -n swap -L 1G barney
> - deactivate that VG - vgchange -a n barney
> - remove /dev/mapper/vg-fredp1 and /dev/mapper/vg-fredp2 by running
>   kpartx -d /dev/vg/fred
> 
> When you boot the system installer, it should find all those
> partitions and LVs.  You must tell it to format each one.
> 
> Hope that helps.  
> 
> If anyone out there has reason to believe there is a better way to do
> this, please let me know!
> 
> -Dylan
> 
> >    Hi,
> > 
> >    I am trying to create a DomU under SLES10.1 that uses LVM.
> > 
> >    I created 3 lv's
> >            /dev/vg1//lv-024swap
> >            /dev/vg1//lv-024boot
> >            /dev/vg1//lv-024root
> > 
> >    In Virtual Machine Manager (VMM) I try to assign these 
> to a new machine.
> >    The best I can get is using each as a disk, not a 
> partition. When I
> >    manually edit the config file and put the lines as
> > 
> >    disk=[ 'phy:vg1/lv-024swap,hda1,w', 'phy:vg1/lv-024boot,hdb1,w',
> >    'phy:vg1/lv-024root,hdc1,w', 'phy:/dev/sr0,xvdd,r', ]
> >    What is supposed to be in my bootloader and bootargs lines?
> > 
> >    Any help, or pointing me to a document to read would be 
> appreciated.
> > 
> >    Thomas King
> 
> > _______________________________________________
> > Xen-users mailing list
> > Xen-users@xxxxxxxxxxxxxxxxxxx
> > http://lists.xensource.com/xen-users
> 
> _______________________________________________
> Xen-users mailing list
> Xen-users@xxxxxxxxxxxxxxxxxxx
> http://lists.xensource.com/xen-users
> 

_______________________________________________
Xen-users mailing list
Xen-users@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-users


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.