Hi all, I had centos 5.9 installed with one of its volumes (non-root) on LVM: ... /dev/vgapps/lvapps /opt/apps ext3 defaults 1 2 ... Then installed centos 6.4 on this servers but without exporting this volume (I wanted to reuse it). After that instead importing it I did: # pvcreate /dev/sddlmac # vgcreate vgapps /dev/sddlmac And then realised that I should have import it instead of pvcreate/vgcreate. Can I restore previous state and data from this volume ? I have files from /etc/lvm/backup (taken before reinstallation) with its old definition. Regards P.
To give additional data - currently I have the following: # pvs File descriptor 7 (pipe:[76957]) leaked on pvs invocation. Parent PID 15357: bash PV VG Fmt Attr PSize PFree /dev/sddlmab2 vg01 lvm2 a-- 14.47g 480.00m /dev/sddlmac vgapps lvm2 a-- 50.00g 50.00g But vgapps has been created "manually" after reinstallation (pvcreate + vgcreate) Is that correct approach if I pvremove it and then pvcreate previous volume using /etc/lvm/backup files ? Regards P. Od: przemolicc at poczta.fm Do: centos at centos.org; Wys?ane: 16:22 Poniedzia?ek 2013-12-16 Temat: [CentOS] LVM recovery after pvcreate> > Hi all, > > I had centos 5.9 installed with one of its volumes (non-root) on LVM: > ... > /dev/vgapps/lvapps /opt/apps ext3 defaults 1 2 > ... > Then installed centos 6.4 on this servers but without exporting this volume (I wanted to reuse it). > After that instead importing it I did: > # pvcreate /dev/sddlmac > # vgcreate vgapps /dev/sddlmac > > And then realised that I should have import it instead of pvcreate/vgcreate. > Can I restore previous state and data from this volume ? > I have files from /etc/lvm/backup (taken before reinstallation) with its old definition. > > Regards > P. > _______________________________________________ > CentOS mailing list > CentOS at centos.org > http://lists.centos.org/mailman/listinfo/centos >
On 12/16/2013 09:22 AM, przemolicc at poczta.fm wrote:> > Hi all, > > I had centos 5.9 installed with one of its volumes (non-root) on LVM: > ... > /dev/vgapps/lvapps /opt/apps ext3 defaults 1 2 > ... > Then installed centos 6.4 on this servers but without exporting this volume (I wanted to reuse it). > After that instead importing it I did: > # pvcreate /dev/sddlmac > # vgcreate vgapps /dev/sddlmac > > And then realised that I should have import it instead of pvcreate/vgcreate. > Can I restore previous state and data from this volume ? > I have files from /etc/lvm/backup (taken before reinstallation) with its old definition.If you've got the appropriate /etc/lvm/backup/ file, then vgcfgrestore should be able to put things back the way they were. -- Bob Nichols "NOSPAM" is really part of my email address. Do NOT delete it.