[linux-lvm] Having problems recovering LV

Colin Faber cfaber at gmail.com
Wed Jan 21 19:18:53 UTC 2009


So I managed to recover my raid, now I have what I think is a complete 
md0 and md1. However when I pvscan I get different results depending on 
whether md0 is online or not.

Here is an example of what I'm referring to:

# pvscan
  Warning: Volume Group raid is not consistent
  PV /dev/md0   VG raid   lvm2 [1.82 TB / 1.82 TB free]
  Total: 1 [1.82 TB] / in use: 1 [1.82 TB] / in no VG: 0 [0   ]

that is what I get when I have md0 and m1 enabled. However if I disable md0:

# mdadm -S /dev/md0
 mdadm: stopped /dev/md0

# pvscan
  Couldn't find device with uuid 'oI1oXp-NOSk-BJn0-ncEN-HaZr-NwSn-P9De9b'.
  Couldn't find device with uuid 'oI1oXp-NOSk-BJn0-ncEN-HaZr-NwSn-P9De9b'.
  PV unknown device   VG raid   lvm2 [1.82 TB / 0    free]
  PV /dev/md1         VG raid   lvm2 [1.36 TB / 0    free]
  Total: 2 [3.18 TB] / in use: 2 [3.18 TB] / in no VG: 0 [0   ]


So that said md0 exists (temporarily ) across 3 USB mass storage 
devices. After the initial rebuild I suspected that the device order was 
mixed up (yeay for random USB device assignments). I verified that this 
was in fact the case with the first and last 64k of the array containing 
no PV label and the middle one containing the label. I've since 
corrected it so the disks are (should be) in the right order again.

So I guess what I'm asking is what I should do next here, my experience 
with LVM is limited.  Am I hosed here? Is my data recoverable?

-cf




More information about the linux-lvm mailing list