Accessing LVM Volumes

  • I had a Fedora install, needed to access the disk volumes it created from another machine
  • testing out Trinity Rescue Kit
  • this explanation assumes root access
  • fdisk showed that the Fedora disk had a small partition /dev/sda1 type "Linux", much larger /dev/sda2 of type "Linux LVM"
  • "vgscan" shows:
Reading all physical volumes.  This may take a while ...
Found volume group "vg_centos65" using metadata type lvm2
  • vgchange -ay vg_centos65 means "activate" ("a") and set to "yes" ("y") for this volume, response:
2 logical volume(s) in volume group "vg_centos65" now active
  • "lvs" (man page says "report information about logical volumes") tells me there's a "lv_root" and a "lv_swap" in there
  • not interested in the swap, so: mount /dev/vg_centos65/lv_root /mnt/tmp/ where "/mnt/tmp/" is any existing dir where you want to temporarily mount this volume