1834691 Members
2545 Online
110069 Solutions
New Discussion

/etc/lvmpvg

 
Waugh
Frequent Advisor

/etc/lvmpvg

Hi ,

Is it necessary to configer /etc/lvmpvg. what is the use of it.

Regards
Rkumar
5 REPLIES 5
點燃
Valued Contributor

Re: /etc/lvmpvg

Hi,
No, it is not mandatory to configure the /etc/lvmpvg.
Please have a look on these threads

http://www.informatik.uni-frankfurt.de/doc/man/hpux/lvmpvg.4.html

http://forums11.itrc.hp.com/service/forums/questionanswer.do?admit=109447626+1238226964030+28353475&threadId=91052

regards!
Man's mind, once stretched by a new idea, never regains its original dimensions
Sajjad Sahir
Honored Contributor

Re: /etc/lvmpvg

Dear Rkumar

it is an important file, see once u are going to create a physical volume u can confirm physical volume is used or not in some where else.(in volume group)

suppose if u are creating physical volume by using pvcreate if it is used in some other volume group it will say where it is used
then u can check this file then u can easily identify, such a purpose
also this file give u description about volume group and what are the physical volume under this. so u can decide do u want to create this file or not?

thanks and regards

Sajjad Sahir
sen_ux
Valued Contributor

Re: /etc/lvmpvg

This is one allocation policy for mirroring.

If you set PVG-strict as allocation policy.The mirrors can not be placed on a disk which are in the same controller.

For enabling this u have to create the file /etc/lvmpvg and change the policy to PVG strict using lvchange.


thanks
sen
R.K. #
Honored Contributor

Re: /etc/lvmpvg

Hi RKumar,

'/etc/lvmpvg' file is necessary only in certain situations. In normal mirroring layouts it is NOT required.

**********************
An extract from an LVM guide:

The â PVG-Strictâ policy requires a logical volumeâ s mirrors to reside in separate userdefined â physical volume groupsâ . Usually physical volume groups are configured to ensure that the mirrors are on different controllers and interface cards. You can explicitly request the strict policy via the â s g option on lvcreate. In order to use the PVG strict policy, you must also configure the /etc/lvmpvg file.

# vi /etc/lvmpvg

# lvcreate â L 32 â n data â m 1 â s g vg01

**********************

SO, if we are creating a normal LV or a normal mirrored LV, we may not require 'lvmpvg' file.

Normally we require this file for 'striped & distributed mirroring'.
SO, in this case, procedure would be:

# vi /etc/lvmpvg
# lvcreate â n data â D y -s g vg01
# lvextend â L 16000 /dev/vg01/data /dev/dsk/c0t0d0 /dev/dsk/c0t1d0

Now our lvdisplay looks like,
# lvdisplay -v /dev/vg01/data
Mirror copies 0
Stripes 0
Stripe Size (Kbytes) 0
Allocation --> PVG-strict/distributed <--

And contents of /etc/lvmpvg will be somewhat like this:
# vi /etc/lvmpvg
VG /dev/vg01
PVG controller0
/dev/dsk/c0t0d0
/dev/dsk/c0t1d0
PVG controller1
/dev/dsk/c1t2d0
/dev/dsk/c1t3d0


Hope this helps..

Regds,
R.K.
Don't fix what ain't broke
Taifur
Respected Contributor

Re: /etc/lvmpvg

Hi Rkumar

lvmpvg is an ASCII file that stores the volume-group information for all of the physical volume groups in the system. The information is stored in a hierarchical format.

First, it starts with a volume group under which multiple physical volume groups can exist. Under each physical volume group, a list of physical volumes can be specified. There must be at least one physical volume group in each volume group that appears in this file. The physical-volume-group name must be unique within the corresponding volume group, although it is permissible to use a common physical volume group name across different volume groups. There can be as many volume groups in this file as there are in the system.

Instead of using the vgcreate and vgextend commands, the administrator can edit this file to create and extend physical volume groups. However, care must be taken to ensure that all physical volumes to be included in the file have already been defined in their respective volume groups by previous use of vgcreate or vgextend.

Instead of using the vgcreate and vgextend commands, the administrator can edit this file to create and extend physical volume groups. However, care must be taken to ensure that all physical volumes to be included in the file have already been defined in their respective volume groups by previous use of vgcreate or vgextend.

The lvmpvg file format has the following structure. VG and PVG are keywords that introduce the names of the volume group and physical volume group, respectively. No comments are allowed in this file.

VG vg_name
PVG pvg_name
pv_path
...
PVG pvg_name
pv_path
...
VG vg_name
PVG pvg_name
pv_path
...The variables are defined as follows:

pv_path
The block device path name of a physical volume within the volume group.

pvg_name
The name of the physical volume group. It must be unique within the volume group.

vg_name
The path name of the volume group.

EXAMPLES
The following example shows an lvmpvg file containing two volume groups: the first containing two physical volume groups, each with two physical volumes defined in it; the second containing three physical volume groups, each with one physical volume defined in it.

VG /dev/vg00
PVG PVG0
/dev/dsk/c2t0d0
/dev/dsk/c2t1d0
PVG PVG1
/dev/dsk/c3t0d0
/dev/dsk/c3t1d0
VG /dev/vg01
PVG PVG0
/dev/dsk/c4t0d0
PVG PVG1
/dev/dsk/c5t0d0
PVG PVG2
/dev/dsk/c6t0d0

For more details you can follow below link,
http://docs.hp.com/en/B2355-60127/lvmpvg.4.html

Rgds//
Taifur