Operating System - HP-UX
1837650 Members
2919 Online
110117 Solutions
New Discussion

Re: How to specify minor number for /dev/vgx/group?

 
SOLVED
Go to solution
zhaogui
Super Advisor

How to specify minor number for /dev/vgx/group?

I have two servers sharing a VA7400 disk array. Now I am trying to vgimport a few VGs from node node A to node B
nodeB@root#/etc/hp/EBTCIA:> vgimport -v -s -m dev/vgprz10.map /dev/vgprz10
Beginning the import process on Volume Group "/dev/vgprz10".
vgimport: Cannot open the control file "/dev/vgprz10/group":
No such device
But I have already created this file.
nodeB@root#/etc/hp/EBTCIA:> ll /dev/vgprz10/group
crw-r--r-- 1 root sys 64 0x360000 Jan 18 16:32 /dev/vgprz10/group

If I change minor number to 0x2b0000, then every thing goes smoothly. How come I cannot use 0x360000 that I ensure no other VG use this number.

Thanks,
8 REPLIES 8
Frank Gilsdorf
Advisor

Re: How to specify minor number for /dev/vgx/group?

Hi,

you have to change your kernel-parameter "maxvgs". I think it defaults to 10 so the max number allowd is 0x0a0000.

Frank
Stefan Farrelly
Honored Contributor

Re: How to specify minor number for /dev/vgx/group?


0x360000 is a huge number to use for a VG group id, it probably completely changes the way the device is accessed.

The normal procedure for creating a VG group file is to start at;
0x010000
then go up;
0x020000
0x030000
....
as 0x00000 is used for VG00
Im from Palmerston North, New Zealand, but somehow ended up in London...
Steven Sim Kok Leong
Honored Contributor
Solution

Re: How to specify minor number for /dev/vgx/group?

Hi,

The minor number for the group file should be unique among all the volume groups on the system. It has the format 0xNN0000, where NN runs from 00 to 09. The maximum value of NN is controlled by the kernel tunable parameter maxvgs.

Unless you increase the default tunable parameter maxvgs from 10 to 55 (36 is hax for 54), you will not be able to use 0x360000 as the minor number for your volume group.

Hope this helps. Regards.

Steven Sim Kok Leong
Michael Tully
Honored Contributor

Re: How to specify minor number for /dev/vgx/group?

Hi,

The number represents a hexadecimal value.

For instance once you have

vg01 0x010000
vg02 0x020000
etc
vg09 0x090000
vg10 0x0a0000

etc
Once you cannot create further groups
you need to increase the kernel paramater
'maxvgs'. Increase it to at least 30 more
if required. Also these numbers are an
example, they are usually done in creation
order.


HTH
-Michael
Anyone for a Mutiny ?
Steven Sim Kok Leong
Honored Contributor

Re: How to specify minor number for /dev/vgx/group?

Hi,

Just a word of caution.

The default maxvgs parameter value 10 means that you can only use 0x000000 to 0x090000. Thus, you cannot use 0x0a0000 (hex a = dec 10) since it would be the 11th VG.

man 1m vgcreate for more information.

Hope this helps. Regards.

Steven Sim Kok Leong
Ravi_8
Honored Contributor

Re: How to specify minor number for /dev/vgx/group?

Hi,
minor start with 0x010000 and then goes like
0x020000, 0x030000 .....
never give up
Wodisch
Honored Contributor

Re: How to specify minor number for /dev/vgx/group?

Hello,

the minor device number looks like this:

0xVV00LL

where:
- "0x" means hexdecimal
- "VV" is the internal VolumeGroup number, which must from 0 to one less than the kernel parameter "maxvgs"
- "00" must be two zeros
- "LL" is the internal LogicalVolume number, which must be from 1 to the maximum of LVs for this VG, as configured by "vgcreate"

HTH,
Wodisch
zhaogui
Super Advisor

Re: How to specify minor number for /dev/vgx/group?

Sorry for late reply. I have fixed the problem. It is mainly because I specified too big minor number(0x360000 is equivalent to 54), but on my system maxvgs=50. That's why 0x2b0000 can work.

Thanks a lot.