1833178 Members
2797 Online
110051 Solutions
New Discussion

Creating PVGs

 
Cliff Lim Kok Hwee
Regular Advisor

Creating PVGs

Gd Day Forum,

I am creating a few PVGs on a new Volume Group
i) vgcreate -p 64 -s 8 -e 10000 -g pvg0901 /dev/vg09 /dev/dsk/cxxxxxx
ii) vgextend -g pvg09P02 /dev/v09 /dev/dsk/cxxxxx

Query: Please advise whether the above mentioned steps are applicable?

I would want to create a Logical Volume on vg09, with the -D y option

lvcreate -D y -r N -s g -L /dev/vgsg1

Query: Will extent striping be performed automatically on all the PVs in PVG pvg0901 then if no space available will then extent striping on the PVs in PVG pvg0902? I presume this should be the case.

Thanks/cliff
4 REPLIES 4
Leif Halvarsson_2
Honored Contributor

Re: Creating PVGs

Hi,
Use pvcreate to "initialize" a physical volume for use in a volumegroup.
Use vgcreate for creating a NEW volumegroup.
Use vgextend for adding a physical volume to an EXISTING volumegroup.

I am not sure I understand the last query but, a locical volume can NEVER spawn across volumegroupsbut, (if using the -D option) spawn across all avialable physical volumes in a group.
Devender Khatana
Honored Contributor

Re: Creating PVGs

Hi Cliff,

What you are doing is absolutely right only. Onlything is that you should target paths of all devices in your first command on which you want to create pvg0901.

With -D option you are also specifying -s g that means two copies of a Physical extent can not share the same PVG. Also -D options means one PE of each Physical Volume Group will be allocated once & 2nd PE will be allocated to 2nd PVG. For doing this you must have more than one PVG in your Physical Volume Group.


HTH,
Devender
Impossible itself mentions "I m possible"
Keith Bryson
Honored Contributor

Re: Creating PVGs

Hi Cliff

You can create the VGs as normal, then edit the /etc/lvmpvg file and tailor your PVGs as you like them (see 'man /etc/lvmpvg'). This avoids the confusing command lines with the vgcreate.

Keith
Arse-cover at all costs
TwoProc
Honored Contributor

Re: Creating PVGs

Cliff,

You're on the right track for creating the PVG.

I think the striping will occur only across a single PVG. It will not go automatically to the next one.
We are the people our parents warned us about --Jimmy Buffett