Digital Unix Device Files

Device File Creation

Before a device file is created, the OS kernel has to support the device in question.  If you are talking about disk or tape devices, this is mostly a matter of having the kernel built to know about the SCSI controller that the disk or tape drive is attached to.  If you are adding a disk or tape drive to an existing controller, you should not have to rebuild the kernel.  For more details on building kernels, see the "Building Kernels" page in this site, or look at the online html documentation from Digital.

Device files are generally created automatically at system boot up time by the /dev/MAKEDEVS script.  If you need to run this script manually, you simply run the script as root and specify what type of device you are installing and what it's SCSI target id is.

For example, to create a disk device for a SCSI disk on controller 0, target 0, and a tz tape drive on target 5:

    # cd /dev
    # ./MAKEDEV rz0
    # ./MAKEDEV tz5

I will explain the tape drive and disk drive names that are created  next.

Disk and Tape Drive Naming Conventions:

As with most Unixs, disk and tape device file names can be a little obscure.  But once you know the logic behind them, Digital Unix's names are fairly straight forward.
For disk drives, the name is a combination of the type of type of disk, the SCSI controller the disk is on, and the disk's target and LUN numbers.  This naming convention holds true whether the disk is directly attached, or if it is in a RAID device such as an EMC Symmetrix.  In the case of a RAID array, the "disk" is likely to be a logical device that is presented to the host rather than a physical disk.

Disk name format:
/dev/<device type><logical unit><target/controller number><disk slice>

For each given physical or logical disk, there will be a total of 16 device files.  One for each block device disk partition, and one for each character (raw) disk partition.

Example:  /dev/rz0a

Example 2:    /dev/rrze17e

Tape Device names
Tape devices follow a different naming convention than disks.  You cannot tell what the target number and SCSI bus number is for a tape device given just its name.  The device name will also have other modifiers that determine things like whether the tape rewinds after use, and what density and compression settings are used on the tape.

/dev/<device type><device number><density/compression flag>

Example: /dev/nrmt1h