IDMKNOD(1M) INTERACTIVE UNIX System IDMKNOD(1M)
NAME
idmknod - removes nodes and reads specifications of nodes
SYNOPSIS
/etc/conf/bin/idmknod
DESCRIPTION
This command performs the following functions:
Removes the nodes for non-required devices (those that
do not have an `r' in field 3 of the the device's mdev-
ice entry) from /dev. Ordinary files will not be
removed. If the /dev directory contains subdirec-
tories, those subdirectories will be transversed and
nodes found for non-required devices will be removed as
well. If empty subdirectories result due to the remo-
val of nodes, the subdirectories are then removed.
Reads the specifications of nodes given in the files
contained in /etc/conf/node.d and installs these nodes
in /dev. If the node specification defines a path con-
taining subdirectories, the subdirectories will be made
automatically.
Returns 0 on success and a positive number on error.
The idmknod command is run automatically upon entering init
state 2 on the next system reboot after a kernel reconfi-
guration to establish the correct representation of device
nodes in the /dev directory for the running /unix kernel.
idmknod can be called as a user level command to test modif-
ication of the /dev directory before a DSP is actually
built. It is also useful in installation scripts that do
not reconfigure the kernel, but need to create /dev entries.
The files in /etc/conf/node.d are copies of the Node modules
installed by device Driver Software Packages (DSP). There
is at most one file per DSP. Each file contains one line
for each node that is to be installed. The format of each
line is:
Name of device entry (field 1) in the mdevice file (The
mdevice entry will be the line installed by the DSP
from its Master module). This field must be from 1 to
8 characters in length. The first character must be a
letter. The others may be letters, digits, or under-
scores.
Name of node to be inserted in /dev. The first charac-
ter must be a letter. The others may be letters,
digits, or underscores. This field can be a path rela-
tive to /dev, and idmknod will create subdirectories as
needed.
The character b or c. A b indicates that the node is a
`block' type device and c indicates `character' type
device.
Rev. Base System Page 1
IDMKNOD(1M) INTERACTIVE UNIX System IDMKNOD(1M)
Minor device number. This value must be between 0 and
255. If this field is a non-numeric, it is assumed to
be a request for a streams clone device node, and idmk-
nod will set the minor number to the value of the major
number of the device specified.
Rev. Base System Page 2
IDMKNOD(1M) INTERACTIVE UNIX System IDMKNOD(1M)
Some example node file entries are as follows:
asy tty00 c 1
makes /dev/tty00 for device `asy' using minor device 1.
qt rmt/c0s0 c 4
makes /dev/rmt/c0s0 for device `qt' using minor device
4.
clone net/nau/clone c nau
makes /dev/net/nau/clone for device `clone'. The minor
device number is set to the major device number of dev-
ice `nau'.
The command line options are:
-o directory Nodes will be installed in the directory
specified rather than /dev.
-i directory The file mdevice which normally resides in
/etc/conf/cf.d, can be found in the directory
specified.
-e directory The Node modules that normally reside in
/etc/conf/node.d can be found in the direc-
tory specified.
-s Suppress removing nodes (just add new nodes).
ERROR MESSAGES
An exit value of zero indicates success. If an error was
encountered due to a syntax or format error in a node entry,
an advisory message will be printed to stdout and the com-
mand will continue. If a serious error is encountered
(i.e., a required file cannot be found), idmknod will exit
with a non-zero value and report an error message. All
error messages are designed to be self-explanatory.
SEE ALSO
idinstall(1M), idmkinit(1M).
mdevice(4), sdevice(4) in the INTERACTIVE SDS Guide and
Programmer's Reference Manual.
Rev. Base System Page 3