|MKNOD(8)||System Manager's Manual||MKNOD(8)|
mknod — make
device special files
mknod command creates device special
files. Normally the shell script /dev/MAKEDEV is
used to create special files for commonly known devices; it executes
mknod with the appropriate arguments and can make
all the files required for the device.
The options are as follows:
+’ and ‘
-’ are interpreted relative to an initial mode of “a=rw”.
To make nodes manually, the arguments are:
b. All other devices are character type devices, such as terminal and pseudo devices, and are type
c. A FIFO (also known as a named pipe) is type
Major and minor device numbers can be given in any format acceptable to strtoul(3), so that a leading “0x” indicates a hexadecimal number, and a leading “0” will cause the number to be interpreted as octal.
As an extension,
mknod can also take
multiple lists of parameters in one go. Note that
is not reset from one list to the next so, for example, in
mknod -m 700 name b 12 5 name2 b 12 6
both name and name2 will be mode 700.
mknod command appeared in
Version 6 AT&T UNIX.
|March 5, 2016||OpenBSD-6.0|