Operating System - HP-UX
1753368 Members
5149 Online
108792 Solutions
New Discussion юеВ

Re: delete special file created with mknod

 
SILVERSTAR
Frequent Advisor

delete special file created with mknod

Hi,

I am at the preliminary steps to create a new volume group.


I have done
mknod /dev/vginfydv/group/ c 64 0x0e000

and I see
crw-rw-r-- 1 root sys 64 0x00e000 Jun 23 16:04 vginfydv/group

that seems to be not correct, is it true ?


What I can do to delete that and create a new one.

Please it is urgent.

thanks
Angelo
5 REPLIES 5
A. Clay Stephenson
Acclaimed Contributor

Re: delete special file created with mknod

You are off by a factor of 10 (hex). Simply
"rm /dev/vginfydv/group" and recreate the node via mknod using the correct value "0x0e0000". Before you do that, however, do an "ls -l /dev/vg*/group" and make sure that 0x0e0000 is not in use by any other volume group. This minor device number must be unique.
If it ain't broke, I can fix that.
James R. Ferguson
Acclaimed Contributor

Re: delete special file created with mknod

Hi:

Well, that's fine as long as your kernel 'maxvgs' is set to fourteen (14) or greater, since '0x0e' = decimal 14.

By default, the 'maxvgs' value is decimal 10.

You can remove the file with 'rm' if you goofed.

Regards!

...JRF...
SILVERSTAR
Frequent Advisor

Re: delete special file created with mknod

are you sure to command to use is rm and notrmsf ?

thanks
Angelo
Victor BERRIDGE
Honored Contributor

Re: delete special file created with mknod

Hi Angelo,
In your case you use rm...


All the best
Victor
A. Clay Stephenson
Acclaimed Contributor

Re: delete special file created with mknod

The command is rm. Back in the dim mists of time before there were special commands like insf and rmsf, real UNIX admins only had mknod and rm. In a few special cases, you must use insf and rmsf to create device nodes (notably tape drives) because there are more options than there are low-order bits in the minor device numbers but for LVM rm/mknod will do everything you need.
If it ain't broke, I can fix that.