I'm running CentOS 5.2, it uses LVM to manage the disks and we had a programmer do something (not sure what) then reboot the system. When it came up it kernel panicked. Luckily it's not production, it was their sandbox. But they didn't backup any of their files. I know the disks are fine because I was able to boot from a linux live cd and mount the /boot partition from the sda drive, and the sdb drive that has the mysql database mounted at /var/lib/mysql and not using LVM. What I don't know how to do is mount /dev/sda2 (root / partition) which is an LVM/ext3 partition. Does anyone have the steps to mount this drive while booted into a linux live cd? -- -matt -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.centos.org/pipermail/centos/attachments/20080917/3554d158/attachment-0001.html>
Stephen Harris
2008-Sep-17 16:00 UTC
[CentOS] Mounting a LVM partition from a linux live cd
On Wed, Sep 17, 2008 at 11:44:19AM -0400, Matt Shields wrote:> I'm running CentOS 5.2, it uses LVM to manage the disks and we had a > programmer do something (not sure what) then reboot the system. When it > came up it kernel panicked. Luckily it's not production, it was their > sandbox. But they didn't backup any of their files. I know the disks are > fine because I was able to boot from a linux live cd and mount the /boot > partition from the sda drive, and the sdb drive that has the mysql database > mounted at /var/lib/mysql and not using LVM. What I don't know how to do > is mount /dev/sda2 (root / partition) which is an LVM/ext3 partition. Does > anyone have the steps to mount this drive while booted into a linux live cd?Commands that might be useful: pvscan - verify the physical disks are present vgscan - scans for volume groups vgchange -a y - activates all volume groups Now your logical volumes should be present and seen with 'lvscan' and so can be mounted (/dev/VolGroup/LVName would be the volume to mount) -- rgds Stephen