I have a number of normal (paravirtualized) domU guests with LVM-backed filesystems. Each of these filesystems has an entry in (e.g.) /dev/vg0, and can be mounted without issues. However, I''m having trouble mounting the LVM-backed filesystems of the HVM domU guests, because the LVM logical volumes in question don''t hold filesystems directly, but rather act as virtual disks with their own partition tables, MBRs and (virtual) partitions. The fdisk, cfdisk, and sfdisk programs all grok this scheme and, when invoked on (e.g.) /dev/vg0/lv0, cheerfully report partitions of lv0p1, lv0p2, etc. However, there are no device node entries (either in /dev/vg0 or /dev/mapper) for these sub-partitions, and thus mount(8) is unable to use them. I''m sure that I''m missing something simple, but my Googling hasn''t turned up anything. Thanks in advance. -- Kevin DeGraaf _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
hi, Kevin DeGraaf schrieb:> I''m sure that I''m missing something simple, but my Googling hasn''t > turned up anything. Thanks in advance.have a closer look to kpartx as a part of the multimapper-tools: http://linux.die.net/man/8/kpartx cu denny _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
> have a closer look to kpartx as a part of the multimapper-tools:That worked, thanks. For the benefit of anyone searching the archives for this issue: # apt-get install multipath-tools # kpartx -a /dev/vg0/lv0 # mount /dev/mapper/lv0p1 /mnt/foo I''m a bit surprised that it didn''t follow the format of the existing nodes (e.g. /dev/mapper/vg0-lv0--p1). Doing it the naive way allows collisions between similarly-named LVs in different VGs. Oh well. :-) -- Kevin DeGraaf _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Nico Kadel-Garcia
2007-Aug-11 06:42 UTC
Re: [Xen-users] Mounting LVM sub-partitions - SOLVED
Kevin DeGraaf wrote:>> have a closer look to kpartx as a part of the multimapper-tools: >> > > That worked, thanks. > > For the benefit of anyone searching the archives for this issue: > > # apt-get install multipath-tools > # kpartx -a /dev/vg0/lv0 > # mount /dev/mapper/lv0p1 /mnt/foo > > I''m a bit surprised that it didn''t follow the format of the existing > nodes (e.g. /dev/mapper/vg0-lv0--p1). Doing it the naive way allows > collisions between similarly-named LVs in different VGs. Oh well. :-) >You noticed that! Yeah the syntax of device naming there is a bit interesting. It makes it important to name the partitions for your DomU''s in ways that will not naturally collide. Me, I create a specific volume group for them called something like XENDISK and use names for the individual DomU''s such as "DOMU01", "DOMU02", etc. That helps avoid collisions. _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Hi there, Denny Schierz wrote:> http://linux.die.net/man/8/kpartxI needed this for a long time, but never thought it would be possible, so I never really searched for a solution :-p Thanks for the hint! Will try this too! Greetz Age_M _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
The lomount tool included in the Xen distribution (originally obtained from QEMU) will also enable you to mount partitions from within a file or block device. Cheers, Mark On Saturday 11 August 2007, Age_M wrote:> Hi there, > > Denny Schierz wrote: > > http://linux.die.net/man/8/kpartx > > I needed this for a long time, but never thought it would be possible, > so I never really searched for a solution :-p > Thanks for the hint! Will try this too! > > Greetz Age_M > > _______________________________________________ > Xen-users mailing list > Xen-users@lists.xensource.com > http://lists.xensource.com/xen-users-- Dave: Just a question. What use is a unicyle with no seat? And no pedals! Mark: To answer a question with a question: What use is a skateboard? Dave: Skateboards have wheels. Mark: My wheel has a wheel! _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users