Re: Please help me recover my LVM configuration

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

 



On Fri, Jul 29, 2011 at 08:30:25PM -0700, David Ziring wrote:
> Hi all,
>  
> I’m hoping I can get some help recovering my data.  A week or so back I
> accidentally overwrote the partition table on one of the two drives containing
> my data.  I luckily didn’t touch the partition itself, so I believe all the
> data is still there, but in rebuilding the partition table I (think I) nuked
> the uuid of the drive.  Now I’m not sure how to progress. 
> Please help this relative neophyte – there is a lot of nostalgia sitting on
> those drives.  Tell me what information you need and I will get it.
>  
> DZ

Was the lost partition also the one housing /etc/lvm?  If not, you can
get the UUID that way....

If it was, fortunately LVM keeps metadata information about itself.
You should able to dump it via:

     dd if=/dev/sda2 bs=512 count=255 skip=1 of=/tmp/sda2.txt

Where /dev/sda2 is your LVM partition.

You can then examine the output file with "strings" and pull out the
UUID information or even completely recreate your configuration files.

What I have done in the past is to just examine this information and
then use dmsetup to create a temporary device, mount it and copy out
the information from /etc/lvm.

Then it's the standard vgcfgrestore dance...

Dumped some instructions from a work wiki here that may be of help
(sorry it's PDF):

    http://www.bludgeon.org/~rayvd/files/LVM_Missing_Metadata.pdf

Ray

_______________________________________________
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/



[Index of Archives]     [Gluster Users]     [Kernel Development]     [Linux Clusters]     [Device Mapper]     [Security]     [Bugtraq]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]

  Powered by Linux