Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

"Remove a vg without exportvg ..??

Status
Not open for further replies.

stephnane

Technical User
Jun 25, 2004
34
FR
Hello.

I need to "detach" a VG from a serveur without making an exportvg.

Is it possible ??

Tks.

Stephnane
 
After the varyoffvg, my server always know it.

I want to remove it from the ODM, but les all data on disks, to attach this vg to another server.

Stephnane
 
Hi Stephane,

if you want to move the VG to another system it's enough to varyoffvg the VG on the old system and cfgmgr (to get the disks if not already done) and varyonvg on the new system.

The old system still knows the VG. If you want the old system to forget the VG run exportvg which could also be named forgetvg ;-).

exportvg will not remove any data from the disks it just removes the VG data from the odm and removes the filesystems from you /etc/filesystems.

HTH
Axel
 
I explain my problem.
I have 2 servers Q and S.
On Q, I have a vg, all FS are in /oracle/xxx.
When I move my vg from Q to S, I do a recratevg to mount my FS in /Q/oracle/xxx to save them.
When my backup has finished, I want to move my vg from S to Q, but mounting my FS in /oracle/xxx ..

Here is my problem.
The exportvg writes informations about FS on the disks...
I need a "forgetvg " command which dont write changes about FS...

Stephnane
 
nope ... exportvg doesn't modify info into the exported VG's VGDA ... only zap out the info from ODM, infact when you import the VG on a different system everything works fine.
Completely different is to REMOVE a vg from smitty panel ... which physically modifies disks info in the VGDA and destroy the aggregation.
Normally recreatevg is used after a FLASHCOPY operation, and is required because with a such operation also vgid and pvid are copied so you will find TWO different set of disks per a single VG ... in other words ... if you VG is i.e. of 4 disks at the end of a FLASHCOPY you will find 8 disks referring the same VG with 4 pairs of disks with the same pvid ...
To avoid the filesystem and LV renaming dued to a recreatevg you can specify the -L / and -Y NA flags ... but they work fine only in AIX 5L
 
my recreatevg option -L is /Q
Is it possible to "remove" the /Q after my operations ??
 
let me understand .... the problem is when you execute the recreatevg on the Q system or when you go back to the S system?
 
Heu.

At start, my vg is on Q with the path /oracle
I recreatevg it and add the prefix /Q on S.
I want now to go back to Q with only /oracle.

(and I need to script it).

Tks.
 
well ... the only way is to execute this script with YourVG varied on and all filesystems UNMOUNTED:
lsvg -l YourVG |awk '($7 ~ /^\/Q/){print $7}'|while read a
do
NewName=$(echo $a|cut -c3-)
chfs -m $NewName $a
done
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top