Jul 6, 2012

Access an LVM module (Ubuntu 12.04)

A computer died on me and I needed to recover some of the data. I thought it would simply be a case of popping the disk into an external hard-drive case and ripping the data out. Unfortunately, I encountered a little snag involving LVM.

My Ubuntu 12.04 machine could not recognise the LVM partition natively. Basically this meant I had to configure the machine so that I could manipulate the disk; a quick Google search revealed this post from linux-sxs.org.

To make your life easier, here are the steps:

  1. Install lvm2, which is the libraries and utilities required to manipulate LVM volumes.
    sudo apt-get install lvm2
  2. Use the following command to scan for available LVM volume groups and find the one you are looking for (in this example we are going to assume our volume group is VolumeGroup01)
    sudo vgscan
  3. Activate your volume
    sudo vgchange -ay VolumeGroup01
  4. Search for the volume that contains the partition you are looking for (we are going to assume that the volume is called LogicalVolume01)
    sudo lvs
  5. Create a mount point for your volume
    sudo mkdir /mnt/destination
  6. Mount the volume
    sudo mount /dev/VolGroup00/LogVol00 /mnt/fcroot -o ro,user

 

References:

No comments:

Post a Comment

Thanks for contributing!! Try to keep on topic and please avoid flame wars!!