1758566 Members
1965 Online
108872 Solutions
New Discussion юеВ

Recover old Volume Group

 
SOLVED
Go to solution
Tonatiuh
Super Advisor

Recover old Volume Group

HP-UX 11.11.

2 disks in my system. One volume group, one in each disk. I reinstalled OS using only the disk 1.

How can I recover my old volume group (with its logical volumes) still existing in the disk 2?
13 REPLIES 13
unixguy_1
Regular Advisor

Re: Recover old Volume Group


Hi Tonatiuh,

I thing this is not possible,becuase if u r going to add a new disk,it will be automatically formated,

so you are not able to recover the VG.

Regards,
Unixguy.

Wim Rombauts
Honored Contributor

Re: Recover old Volume Group

Unless disk 2 contains a second copy of an OS, which has correct knowledge of the VG-configuration of disk 1, you cannot recover your VG.

And even if you recover your VG, you will need a backup to restore the data.
likid0
Honored Contributor

Re: Recover old Volume Group

yes, it's still there.

You have 2 options, import the vg with the names of the lvols or with the default name lvols


with name of lvols:

Do you still have a map from the vg?

or a cfg2html, somewhere where you can look at the names of the lvols?

if you have you can import with:
vgimport -m vgmapfile /dev/vgname /dev/dsk/disk

if not you have to import:
vgimport /dev/vgname /dev/dsk/disk

and the names of the lvols will be lvol1,lvol2,etc

Just mount them to guess what where their names, and change then with a mv


Windows?, no thanks
likid0
Honored Contributor

Re: Recover old Volume Group

If i understand this:

2 disks in my system. One volume group, one in each disk. I reinstalled OS using only the disk 1.

It means you had to independent VG's, 1 in each disk, then it is posible to get your data from the disk that doesn't have the os
Windows?, no thanks
unixguy_1
Regular Advisor

Re: Recover old Volume Group


Hi,

yes Orange adm is correct,

if u have a map file for that VG,
it will be going recover it.

use the below mentioned commands

#vgimport -s -p -m /tmp/vg01.map /dev/vg01

the above mentioned commands is going to recover a VG.

but if u don't have it's not possible to do it.

Regards,
Unixguy.

Ganesan R
Honored Contributor

Re: Recover old Volume Group

Hi,

You can recover the volume group with the help of vgimport command

Just issue the below commands.

#mkdir /dev/vgnew
#mknod /dev/vgnew/group c 64 0x030000
#vgimport /dev/vgnew
#vgimport /dev/vgnew /dev/dsk/c0t5d0

#vgchange -a y /dev/vgnew
#vgdisplay -v /dev/vgnew

It will list the available logical volumes

Mount the logical volumes and access the data.
Best wishes,

Ganesh.
Analyst
Trusted Contributor

Re: Recover old Volume Group

If I understood your query,

Yes you can recover it using the map files, if exists.

After exporting/importing.
go for vgscan command.
there is possibilities to get the configurations back.

Tonatiuh
Super Advisor

Re: Recover old Volume Group

I already have tried importing the vg and does not work.

Any other idea?
Ganesan R
Honored Contributor

Re: Recover old Volume Group

Hi Tonatiuh,

Post the error you received when you try to import. That will help us to provide more solutions..

Other than vgimport, I don't think anyway you can import the data.
Best wishes,

Ganesh.