LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Server (https://www.linuxquestions.org/questions/linux-server-73/)
-   -   LVM from Fedora to ClearOS (https://www.linuxquestions.org/questions/linux-server-73/lvm-from-fedora-to-clearos-4175427217/)

dgibbs 09-14-2012 05:58 AM

LVM from Fedora to ClearOS
 
Hello All,

I hope you can help. I have a problem with LVM.

I have reinstalled my server with ClearOS from Fedora 17 as I felt that Fedora wasn't right for my needs.

Anyway the installation went well but I am having an issue with my LVM partition that was on the previous install.

I have 3 disks:
80GB - OS disk
2TB - Files disk
2TB - Files disk


[root@fileserver ~]# pvscan
PV /dev/sda2 VG vg_fileserver lvm2 [74.04 GiB / 0 free]
PV /dev/sdb1 lvm2 [1.82 TiB]
PV /dev/sdc1 lvm2 [1.82 TiB]
Total: 3 [3.71 TiB] / in use: 1 [74.04 GiB] / in no VG: 2 [3.64 TiB]

/dev/sdb1 and /dev/sdc1 were part of the same LVM but the Volume group name is missing.

I'm guessing that you need to recreate the volume group with vgcreate however I am worried that I this might delete the files already on there. Does anyone know how to recreate the LVM without losing the data on the disk? I have done some reading on this however haven't found the solution. Your help would be much appreciated. Thank you

syg00 09-14-2012 11:06 PM

Are we to assume you reformatted the OS disk without first saving the /etc/lvm/backup ?.
Try this to get the vg and lvs back as-is
Code:

vgchange -ay

dgibbs 09-15-2012 07:19 AM

Hasn't worked.Looks like it may be completely messed up. I'm attempting to use testdisk to get files back. But is not looking promising. Luckily I use crashplan so most of the important stuff should be backed up. I think I have learnt the hard way on this one. At least I know that LVM is not as simple to transfer to another server like standard partitions.

syg00 09-15-2012 05:01 PM

here is an article I've referred people to before, and gives a good idea of what LVM needs to work. Might give you some ideas.
I'm not a huge fan of LVM, but I wouldn't expect just mangling the OS to cause you to lose data is a separate LVM.


All times are GMT -5. The time now is 09:31 AM.