[CentOS] is it possible to recover LVM drive from accidental Fdisk?

nate centos at linuxpowered.net
Sun Mar 7 06:50:04 UTC 2010


Rudi Ahlers wrote:
> Hi all,
>
> Does anyone know if it's possible to recover an LVM partition from a drive
> that was fdisked? I accidently fdisk'd the wrong drive (had to fdisk a lot
> of 160GB drivers from old servers and one still has important data on that
> client now wants) by running fdisk /dev/sdc & deleting the partitions. The
> drive is still in a another machine and hasn't been rebooted yet, but
> there's no no partition on it.

re-create the original partition table, which is just a map, as long
as you haven't formatted or overwritten data everything should still
be there

Also suggest if your not already doing it set your LVm partitons to
type 8e so it's obvious they are LVM

[root at dc1-mysql001b:~]# fdisk -l /dev/sdc

Disk /dev/sdc: 2197.9 GB, 2197949513728 bytes
255 heads, 63 sectors/track, 267218 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sdc1               1      267218  2146428553+  8e  Linux LVM


nate



More information about the CentOS mailing list