[linux-lvm] Help with LVM reconstruction

Marek Podmaka marki at marki-online.net
Sun Oct 5 19:58:11 UTC 2008

Hi Robin,

Sunday, October 5, 2008, 21:09:56, Robin Thompson wrote:

> In short the data is intact, and I have found a program called RAID
> Reconstructor that will produce an image file of the RAID 5 arrays.
> This will be hopefully 2.05tb file.
> I've read that I can use losetup and vgscan to create LVM from 2
> image files. But i'm unsure of how to proceed with when i have only
> one file which is combination of both.
> Anyone out there any advice or help?

I have used losetup few times when doing tests with LVM. Your problem
is that you have 2 PVs in 1 file (if I understand it correctly). If
you know the exact size in bytes of the 2tb PV, then you can use dd to
skip those 2tb and copy only the last 50gb into different file. Then
truncate the original to 2tb (or copy first 2tb).
Then you should have 2 files with your 2 PVs. But think of (or test)
any headers that could be in the begining of those files (for example
partition table and only inside partition there is PV).
But generally, it should be possible to use those files as PVs.

  bYE, Marki

More information about the linux-lvm mailing list