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

Re: [linux-lvm] How to find out the location of PE's

Assuming you used standard config when creating the LVM, you'll find PV
metadata at the very beginning of the disk (an probably nowhere else).

There is no such thing like per PE markers, all information is stored in
the LVM header. Usually though there should be files in /etc holding the
information of the PVs/VGs/LVs as backup - assuming the rest of the disk
layout is still valid (i.e. PV on partition -> partition still exists)

The LVM Metadata is in the second sector (usually) and you should see
something like the string LVM2 and LABELONE (for LVM 2 metadata)

I don't know of any detailed on disk format description (except the source



On Wed, December 28, 2011 11:03, peter bieshaar gmail com wrote:
> Due to a hardware mistake (dvd and hdu as IDE-master ??) I lost complete
> disk- and therefor lvm administration on SATA disks.
> - In other words I cannot see the partition- or PV/VG and LV
> administration.
> - So, fdisk or (pv|vg|lv)display can't give information.
> lvm was initiated under ubuntu 11.04 or 10.10, a recent lvm2 version was
> installed.
> On one disk I tried to create a partition (without creating a filesystem
> of-course :) ) but no pv-information was shown, using pvdisplay. I didn't
> dare to do this on my RAID1 (md) disks.
> I can read the disks with strings and dd, and saw content of scripts and
> documents. So the content/data is still on the disks.
> My chosen strategy to recover the LV's, is finding the PE's, pickthem
> up and place them in a blob on another filesystem. So I can mount -o loop
> that blob and restructure the disks.
> My problem now is how to find these information. The web gives a lot of
> information how to setup, but almost none on technical issues like this.
> Can someone give me a hint on how this (the PE's) technically is being
> organized (pointer -> pointer structures??) and where and how to search
> these on the disk. So I can write a C-thingy to accomplish my strategy. If
> someone already has something like this, or examples,
> --
> Regards,
> Peter Bieshaar
> _______________________________________________
> linux-lvm mailing list
> linux-lvm redhat com
> https://www.redhat.com/mailman/listinfo/linux-lvm
> read the LVM HOW-TO at http://tldp.org/HOWTO/LVM-HOWTO/

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