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 IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Volume group migration 1

Status
Not open for further replies.

tech123786

Technical User
Nov 13, 2006
31
US
We have a volume group prodvg on one of our aix 5.3 server, now we need to move this VG to different emc disks (different frame).I was thinking doing this procedure.
1.after getting the new disks, run
extendvg prodvg hdiskX (new)
mirrovg prodvg hdiskX.....
2.syncvg prodvg
3.Break the mirror using unmirrovg prodvg hdiskx(old)
4.reducevg prodvg hdiskX(old)

Is this a correct procedure to accomplish this change? Any suggestions pls...
Any idea how long would it take to mirror and unmirror a volume group of 40GB?

Thanks
 
you could do an extendvg with the emc disks,afterwards add a logical volume copy to your lv's, then remove the lvcopy on your old disks, leaving 1 copy on the new disks, then a reducevg of the old disks.

mirror speed all depends on your reading speed of the actual disks and write speed of the emc's,so it's hard to tell.With an average speed of 75 M /sec,and a system under normal load it would take about 30 minutes to sync.

rgds,

R.
 
Depending on the number of disks, migratepv might be a simpler option. It'll take care of the lv mirror/sync/remove for you.
Code:
# Example: 
# old disks hdisk2-4 
# new disks hdisk5-7

extendvg prodvg hdisk5 hdisk6 hdisk7
migratepv hdisk2 hdisk5
migratepv hdisk3 hdisk6
migratepv hdisk4 hdisk7
reducevg prodvg hdisk2 hdisk3 hdisk4

- Rod


IBM Certified Advanced Technical Expert pSeries and AIX 5L
CompTIA Linux+
CompTIA Security+

A Simple Code for Posting on the Web
 
Rmgbelgium/Rod,
Thanks for the replies.
Rod,
Here is the situation that I have now. Each of the old disks are with size 10GB each (total 4 disks for prodvg)so prodvg has 40GB of disks without any free apce left on.
The new disks are going to be 9.5GB each and storage team will be assigning 5 disks (5x9.5) which would be enough to migrate prodvg on new disks.
My question is can I run the command
migratepv hdisk2(old) hdisk5(new) hdisk6(new)
If hdisk6 has some free PPs (it should) then can I use
migratepv hdisk3(old) hdisk6(new) hdisk7(new)
Otherwise I can not assign the disks one-on-one basis.Pls clarify me.

Thanks
 
tech123786 said:
My question is can I run the command
migratepv hdisk2(old) hdisk5(new) hdisk6(new)
If hdisk6 has some free PPs (it should) then can I use
migratepv hdisk3(old) hdisk6(new) hdisk7(new)

You can do exactly that.

After you've done one, check "lsvg -p prodvg" and check which of the two drives you targeted has space left. I seem to recall that some LVM command(s) use the last drive specified on the command line first. Worst case, you'll get an error message about a target drive being full.

Another option, if your lv allocations allow, would be to use migratepv's "-l" switch to move a small (but 0.5GB or larger) lv off of each source drive onto the same destination drive, then do the one-to-one migrations with the four remaining destination drives. This is especially handy if you have multiple applications or environments(prod/test/dev) on the server and want to reduce disk contention by isolating each on their own physical device.

- Rod






IBM Certified Advanced Technical Expert pSeries and AIX 5L
CompTIA Linux+
CompTIA Security+

A Simple Code for Posting on the Web
 
If the current disks are all full and the target disks are of different size, then your original plan will probably be handier:

assumptions:
VG name is prodvg
current disks are hdisk2, 3, 4 and 5
new disks are 6, 7, 8, 9 and 10
you now have one copy (not mirrored)

Code:
extendvg prodvg hdisk hdisk6 hdisk7 hdisk8 hdisk9 hdisk10
mirrorvg -c 2 -Q -s prodvg
(now wait until off peak period - evening?)
syncvg -P 4 prodvg
(then next morning)
lsvg -l prodvg (check that all LVs have 2 copies and are sync'd)
unmirrorvg -c 1 prodvg hdisk2 hdisk3 hdisk4 hdisk5

That way you let mirrorvg worry about where to place what. For SAN LUNs LV placement is less of an issue anyway...


HTH,

p5wizard
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top