[clug] LVM Partion Access

Scott Ferguson scott.ferguson.clug at gmail.com
Tue Sep 20 05:00:41 MDT 2011


On 20/09/11 20:51, Brett Worth wrote:
> On 15/09/11 15:19, Scott Ferguson wrote:
>> fdisk -lu $LOOP
>>
>> but there are several other approaches....
>>
>>
>> /data/kvm# file IMAGEFILE
>> note down the start sector
>> /data/kvm# losetup -v -o $[BLOCKSIZE*START_SECTOR] /dev/loop0 IMAGEFILE
>> /data/kvm# lvm pvscan
>>
>>
>>
>> alternatively:-
>> losetup $LOOP IMAGE MOUNT
>> kpartx -av $LOOP
>> fdisk -lu $LOOP
>> mount ${LOOP}p1 /tmp/part1
>> ls /tmp/part1
>>
>> LVM?
>> lvdisplay -c
>> (find /dev/mapper)
>> mount /dev/mapper/$LV /tmp/lv
>> ls /tmp/lv
> 
> Thanks for this response Scott.  Probably exactly what I need.
> 
> Is there an issue with the naming of the volgroup and the volume? 

Yes! I vaguely recall... let me think on (the work-around) it for a bit
(I'm in the middle of something)

> The
> host server has the same names as are inside the VMs i.e. the defaults,
> 
> Brett

I'm pretty sure it's trivial - I should be able to reply later this evening.

Cheers


More information about the linux mailing list