1753566 Members
5969 Online
108796 Solutions
New Discussion юеВ

vgexport

 
SOLVED
Go to solution

vgexport

Hi,

I am getting ready to remove two volume groups from hp-ux 11.0 so the disk drives can be moved to another server. What hp-ux commands should I run to help me determine if any of the drives are being referenced? I have already checked 'bdf', 'swapinfo' and application raw space usage. What command checks dump space configuration? Anything else? What abount glance?

Thanks,
Jerry

8 REPLIES 8
James R. Ferguson
Acclaimed Contributor
Solution

Re: vgexport

Hi Jerry:

> What command checks dump space configuration?

# crashconf -v

Regards!

...JRF...
Patrick Wallek
Honored Contributor

Re: vgexport

You can also do an:

lvlnboot -v

to show dump devices.


To check any LVM configuration:

pvdisplay -v

Re: vgexport

Perfect. thanks to all...
Michael Steele_2
Honored Contributor

Re: vgexport

HI

RE: "...What hp-ux commands should I run to help me determine if any of the drives are being referenced? ..."

Not in HP_UX, only solaris or linux. Refer to what processes are attached to what file systems with 'fuser -cu /file system'.

If you want to drill down and id the disk mounted to the file system then you can use pvdisplay -v /dev/dsk/c.... and note the lv's. Then cross reference the lv's in /etc/fstab to the file system.

Re: "...remove two volume groups from hp-ux 11.0 so the disk drives can be moved to another server. ..."

If you can 'vgchange -a n vg' and deactivate the vg then nothing is attached to the vg. But really, you're going about this backwards. You want to unmount the file system associated to the vg first, and then deactivate the vg.

But then, this is incomplete. In order to move disk between servers you need to 'vgexport -p -m /tmp/vg_map_file -v /dev/vg'. Note the -p option. Without -p you delete the vg out of /dev and out of /etc/lvmtab.

ftp the map file over to the server and import it.

mkdir /dev/vg
mknod group file
vgimport
Support Fatherhood - Stop Family Law
midoone103
Advisor

Re: vgexport

hello pal,
u can use "vgexport", when u wanna remove volume group, the uses will more formally.


# vgchange -a n vgO1
# vgexport vg01


may be that this is true.
Olivier Masse
Honored Contributor

Re: vgexport

I would personally do a vgremove. Unlike vgexport, vgremove is more strict and will not run unless there is are no longer any logical volumes inside the VG. These logical volumes must be removed with lvremove, which in turn have their own protection against accidental removal. Finally once you're done, do a pvremove to remove any PV information from the disk. Using this technique is the long road, but it is the safest one.

Good luck

Re: vgexport

Thanks to all. My volume groups are disabled using vgchange. Later, after resolving any screems, I will vgexport them and be done.
Michael Steele_2
Honored Contributor

Re: vgexport

Gee, eight questions and points for only two of eight questions. Brutal. Just brutal.
Support Fatherhood - Stop Family Law