mknod - make a special file
mknod name b major minor
mknod name c major minor
mknod name p
mknod makes a directory entry for a special file.
The {PRIV_SYS_DEVICES} privilege is required to create a block-type or character-type special file.
The following options are supported:
Create a block-type special file.
Create a character-type special file.
Create a FIFO (named pipe).
The following operands are supported:
The major device number.
The minor device number; can be either decimal or octal. The assignment of major device numbers is specific to each system.
A special file to be created.
See attributes(7) for descriptions of the following attributes:
|
ftp(1), mknod(2), symlink(2), attributes(7), privileges(7)
If mknod(2) is used to create a device, the major and minor device numbers are always interpreted by the kernel running on that machine.
With the advent of physical device naming, it would be preferable to create a symbolic link to the physical name of the device (in the /devices subtree) rather than using mknod.