1833126 Members
3358 Online
110051 Solutions
New Discussion

vgcreate: minor numbers

 
Joe Robinson_2
Super Advisor

vgcreate: minor numbers

in using the syntax

vgcreate -s 16 /dev/vg02 /dev/dsk/c2t0d0

I'm running across an error claiming my minor number (4) that I'm using is in use by another volume group. I've already verified in my /dev directory that 4 in fact is not being used by another volume group. Is there another place or means that the system is looking at that I'm unaware of?
13 REPLIES 13
S.K. Chan
Honored Contributor

Re: vgcreate: minor numbers

To check for duplicate minor number ..
# ll /dev/*/group
This the only place to check for it.
Uday_S_Ankolekar
Honored Contributor

Re: vgcreate: minor numbers

Hello,

cd to /dev/vgnn to all the vg's and look for group file

there should be only one one file in one of the vg directory with group 64 0x040000

Before you execute vgcreate try this ,
mkdir /dev/vgnn
mknod /dev/vgnn/group 64 c 0x040000

Goodluck,

-USA
Good Luck..
James R. Ferguson
Acclaimed Contributor

Re: vgcreate: minor numbers

Hi Joe:

Exactly what error message do you receive?

Regards!

...JRF...
PIYUSH D. PATEL
Honored Contributor

Re: vgcreate: minor numbers

Hi,

ll /dev/*/group has to be checked.

Create a vg04 by

#mkdir /dev/vg04
#mknod /dev/vg04/group c 64 0x040000

Piyush
Shahul
Esteemed Contributor

Re: vgcreate: minor numbers

Hi

I think U are missing something. Please check very carefully. Follow this

#cd /dev
#ll vg* |grep group

Now it will list all the group files which are under different vgs. Minor number should not repeat. cross check again. If U are getting the error still, please create VG with different minor number and see.

Best of luck
Shahul
Mike Hassell
Respected Contributor

Re: vgcreate: minor numbers

Joe,

Was the minor number 4 used in the past? Did you perform a 'vgexport'? If so, your kernel is confused and needs to be rebooted to solve your problem.

Also what version of HP-UX are you running? 10.20?

Hope that helps.

-Mike
The network is the computer, yeah I stole it from Sun, so what?
S.K. Chan
Honored Contributor

Re: vgcreate: minor numbers

If you can't find any minor number conflict and still get this error .. then it might be that in the past some LVM disks were not removed "cleanly". Take a look at /etc/lvmconf and see if there is any non-existing VG's config file. If yes remove it .. (example if vg12 does not exist..)
# cd /etc/lvmconf
# rm vg12.conf
Then try the vgcreate again.. if it still gives the same error, then like what Mike Hassell said a reboot may be necessary. If it's not possible to reboot, then use another minor number in your "mknod".
Joe Robinson_2
Super Advisor

Re: vgcreate: minor numbers

specifics:

my system is running 11.00 on a L2000 class server.

The exact error I'm getting is 'vgcreate: Volume group "/dev/vg02" could not be created:
A volume group is already using this major and minor number.
Please check the minor number of the "group" device file.'

Is simply removing the group file from the system enough to clear this from the system (and rerun vgcreate)? I had considered doing vgexport, but the vg isn't listed in my /etc/lvmtab (I've already run vgscan -a to ensure I've viewed the current configuration).
Joe Robinson_2
Super Advisor

Re: vgcreate: minor numbers

/etc/lvmconf/vg02.conf didn't exist; I'll reboot (and regroup).
James R. Ferguson
Acclaimed Contributor

Re: vgcreate: minor numbers

Hi Joe:

Yes, if you have found a '/dev/vgXX/group' file with the same minor number as you are using for 'vg02', and that file is not neeeded, then remove that group file and rerun your 'vgcreate'.

Regards!

...JRF...
S.K. Chan
Honored Contributor

Re: vgcreate: minor numbers

First lets clean up and try it again ..
# vgdisplay -v vg02
==> To make sure vg02 does not exist.
If vg02 does not exist .. proceed ..
# cd /dev/vg02
# rmsf group

Take note of existing already used minor number ..

# ll /dev/*/group

Recreating vg02 ..
# mknod /dev/vg02/group c 64 0x050000
==> I'm assuming 0x050000 is a unique minor number.
# vgcreate -s 16 /dev/vg02 /dev/dsk/c2t0d0

Joe Robinson_2
Super Advisor

Re: vgcreate: minor numbers

rebooting did the trick. Thanks to everyone!
Sanjay_6
Honored Contributor

Re: vgcreate: minor numbers

Hi Joe,

do a

ll /dev/*/group

and see if the minor no for one of these group files is mentioned as 0x040000. If so the vg to which this group file belongs is using the minor no 4. This is the only place the minor no of the vg is looked for.

Hope this helps.

regds