Operating System - HP-UX
1836581 Members
1651 Online
110102 Solutions
New Discussion

When create a new group file for vg10, what should I type for mknod?

 
SOLVED
Go to solution
Fragon
Trusted Contributor

When create a new group file for vg10, what should I type for mknod?

Is it ---
#mknod /dev/vg10/group c 64 0x0a0000
or ---
#mknod /dev/vg10/group c 64 0x100000
?

====================================
Regards by
Gerald
5 REPLIES 5
Tim D Fulford
Honored Contributor

Re: When create a new group file for vg10, what should I type for mknod?

Either will work as the minor number only needs to be unique. The minor number does not need to match the volume group name as it is just a label (you could call it bobby, vgbobby....). However, if it is consistency you want 0x0a0000.

Regards

Tim
-
Kenneth_19
Trusted Contributor

Re: When create a new group file for vg10, what should I type for mknod?

In fact the two options make no difference from the system point of view, you can name it whatever you like, but for easy future reference and a good practice, suggest to use 0x0a0000.

Correct me if I am wrong.

Regards,
Kenneth
Always take care of your dearest before it is too late
S.K. Chan
Honored Contributor

Re: When create a new group file for vg10, what should I type for mknod?

The "group" minor number's format is like so 0xnn0000 whereby nn can have the value between 00 and ff. Of course depending on the "maxvgs" (maximum alloawable volume groups) kernel value defined. For example (by default) the "maxvgs" is 10. This means you cannot have more than 10 VGs. If you want more you got to increase the kernel value. So with 10 VGs as default, usually (the norm) is VGs are created in order ..
vg00 = 0x000000
vg01 = 0x010000
...
vg09 = 0x090000
So all together 10 VGs. If "maxvgs" got increased to say 16, then ..
vg10 = 0x0a0000
vg11 = 0x0b0000
...
vg15 = 0x0f0000

So in your case if you've been following the VG creation in that order, it should be ..
# mknod /dev/vg10/group c 64 0x0a0000
but then again the rules are not rigid, as long as the minor numbers are unique you're okay. Find out what are the current used minor number ..
# ll /dev/vg*/group
If "0x0a0000" is not used, then go ahead and use that minor number (to stay consistent).if it's been used then you can "pick" any unused minor number.
Nick Wickens
Respected Contributor
Solution

Re: When create a new group file for vg10, what should I type for mknod?

hi just to add to the answer above because I recall it confused me for a while.

If you have two volume groups already called vg00 and vg01 and then for some reason you want to create vg10 but use the "standard" 0x0a0000 minor number then you still need to increase maxvg beyond 10 even though you would only have three volume groups.

I would regard 0x0a0000 as the "standard" mainly because I have come across disaster recovery sites that did not follow this and it caused extra work for me because all my informix link rebuild scripts wanted the "standard".
Hats ? We don't need no stinkin' hats !!
Darrell Allen
Honored Contributor

Re: When create a new group file for vg10, what should I type for mknod?

Hi Gerald,

Once upon a time I tried to create vg35 with minor number 0x350000 (which is hex or base 16). I had a problem doing so because the kernel parameter maxvgs (which specifies how many volume groups can be configured) was set to 40 (which is specified in base 10, or decimal). Apparantly since 0x35 hex is 53 decimal (and obviously 53 is greater than 40), the system thought I was exceeding the allowed number of VGs (maxvgs). I was able to create the VG only when the minor number did not exceed maxvgs as expressed in hex.

Yes, I was told it is a good idea to create VGs as VGnn and specify the minor number as 0xnn0000. In fact, it really doesn't matter. Just be sure all your volume groups have a unique minor number for the group file.

Darrell
"What, Me Worry?" - Alfred E. Neuman (Mad Magazine)