Operating System - HP-UX
1752307 Members
5278 Online
108786 Solutions
New Discussion юеВ

Increasing the preset max. number of Physical Volumes for a VG

 
SOLVED
Go to solution
perfman_1
Advisor

Increasing the preset max. number of Physical Volumes for a VG

I have a VG01 that lives on a virtual array 7100. When the Volume group was setup, it was built to contain a maximum of 16 physical volumes. There are several logical volumes that exist in VG01. I have a request from our development team to increase space on these logical volumes.

So, i went ahead and created new LUNs on the Virtual array. Now when i hit SAM to increase the VG size and try to add those LUNs into VG01, by extending the VG01 i get the following message:

Volume group VG01 currently contains 16 physical volumes, which is the maximum number of physical volumes it was configured to contain. The volume group cannot be extended.

I have a lot of disks and space. But i cannot extend the VG and hence no space extension possible in the logical volumes that are in the VG01. How to get around this problem?

Any help would be really appreciated.

Thank you
Sam
10 REPLIES 10
Calandrello
Trusted Contributor

Re: Increasing the preset max. number of Physical Volumes for a VG

Friend
if the VG was created to support only 16 records does not have as to add to more records you tera that to create another VG and to copy the data
DCE
Honored Contributor

Re: Increasing the preset max. number of Physical Volumes for a VG



This cannot be modified after creation. You will have to destroy and recreate the VG.

That being said, There have been references in the past on this forum about an unsupported program some HP CE's have called pvmodify. If you have a good relationship with your CE, you might want to ask him/her if they know about it.........
perfman_1
Advisor

Re: Increasing the preset max. number of Physical Volumes for a VG

So, if i had enough space, can i create another volume group (lets call it VG02) with more physical volumes and create the new logical volumes with new space requirement within that and then copy existing logical volumes from VG01 to the new VG02. If everything comes up ok, may be delete the VG01?

When we copy over stuff, is the permissions get copied too? otherwise, i would think it will be a nightmare..

Any other ideas? Thank you for responding.
Hein van den Heuvel
Honored Contributor

Re: Increasing the preset max. number of Physical Volumes for a VG


>> Any other ideas?

Just add a VG02
Create a large LV in there: example: LV05_new
Mount on some tmp mountpoint /tmp/LV05_new

Copy (cp -Pr? tar! ) your largest LV from VG01 (example: LV05_old) to the new LV05_new
Unmount the LV05_old
Unmount /tmp/LV05_new
Mount LV05_new on LV05_old mountpoint

Wait a few hours or days to make sure it all works.

Delete LV LV05_old
Use freeed up space in VG01 to grow other LV's there.

Hein.
DCE
Honored Contributor

Re: Increasing the preset max. number of Physical Volumes for a VG



Yes

When you do the copy command use -r to get the subdirectories and -p for permissions

another way - back up the vg to tape, destroy the vg, recreate it and restore from tape
Steven E. Protter
Exalted Contributor

Re: Increasing the preset max. number of Physical Volumes for a VG

Shalom,

By default the max physical volumes of a volume group is 255. With the size of LUN's nowadays this is pretty ridiculous.

If the -p physical volume parameter was used to build the group this figure could have been lowered.

To change it you must vgexport the volume group and then re-create it with a different number in the -p parameter.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Pradeep_29
Frequent Advisor
Solution

Re: Increasing the preset max. number of Physical Volumes for a VG

Hi,

Default Max PV for a VG is 16 and not 255. I think its a typo by Steven. Using -p parameter u can specify large value.

I would suggest to create VG always using -e (max PE), -s (PE size) and -p (max PV).
I normally create using -e 9000 -s 32 -p 64. Using this you can add a Physical disk of size 288 GB and 64 disks.
As Steven mentioned these days LUNs are pretty huge. You may calculate depending on your environment or thinking of future growth.

For current situation, suggestions were already given. Since you have lot of space easier would be to export VG01, create new VG with better options and import. Then add new disks to this VG. For this you will need downtime. Use -s for vgexport and vgimport so that you may not need to specify all Physical disks while import.

Read man pages before starting.

~Pradeep.
John Guster
Trusted Contributor

Re: Increasing the preset max. number of Physical Volumes for a VG

We had similar situation where the MAX PV is set to default 16 which prevents further grow in space. One way to fix this is to create a new volume group like many suggest. When create new VG, please consider
1. MAX PV and MAX PE per PV==-s
2. 2TB file system size limit assuming OS is 11.X. ==-p
3. size of the single disk==-s
vgcreate -p 50 -s 128 ....for an example
lots planning...
As to data migration, cpio will fail if your have a single file larger than 2GB...cp is too slow if you have over a couple of hundred GB...best bet is backing them up followed by a full restore. You can check if everything is OK on new vg against the old vg..play safe...
Wessam Aly
Frequent Advisor

Re: Increasing the preset max. number of Physical Volumes for a VG

May I just note that vgexport/vgimport will not work since vgimport will recreate the VG on the system with exactly the same options and limitations as it were before.

Only solution is to backup/restore or copy.

tar or fbackup/frecover is the best for preserving file permissions, access times,etc..

a tar copy on the fly could be as follows

mount the new LV as /newlv for example and your old filesystem as /oldlv
then

tar cvf - /oldlv|tar -C /newlv -xf -

but ofcourse, cp is the fastest way to get it done.
The manual said the program requires Windows 95 or better, so I installed Linux !