Devices and Device Files
dmesg |
|
Not available under AIX |
|
Display boot and other system messages. Devices are listed within the messages as the devices are detected. |
Vendor-specific device listing commands
AIX: |
|
List all devices. |
FreeBSD: |
|
List PCI devices. |
HP-UX: |
|
Display detailed device listing. |
Linux: |
|
List major devices. |
Solaris: |
|
List devices. |
Special File Formats
In all cases, the optional r in special filenames refers to the character device (i.e., raw access mode), and the other name refers to the block device.
Disk partition special filenames
AIX: |
|
|
n is the disk number. Example: /dev/hdisk1 |
FreeBSD: |
|
HP-UX: |
|
Linux: |
|
Solaris: |
|
CD-ROM device special filenames
AIX: |
/dev/cd0 |
HP-UX: |
/dev/dsk/c |
Linux: |
/dev/cdrom |
Solaris: |
/dev/dsk/c0t |
FreeBSD: |
/dev/cd0c (SCSI), /dev/acd0c (ATAPI) |
For HP-UX and Solaris, k and i have the same meanings in special filenames for both disks and CD-ROMs.
Floppy disk special filenames
AIX: |
/dev/fd0 |
FreeBSD: |
/dev/fd0 |
HP-UX: |
/dev/dsk/c0t1d0 |
Linux: |
/dev/fd0 |
Solaris: |
/dev/diskette |
|
|
Network interface names
The following list indicates the first network interface. Additional interfaces will have higher numbers (e.g., eth1).
AIX: |
en0 |
FreeBSD: |
xl0, de0 (and others) |
HP-UX: |
lan0 |
Linux: |
eth0 |
Solaris: |
hme0, dnet0, eri0, le0 (and others) |
k is the drive number, and n
means “no rewind” in all cases.
AIX: |
|
FreeBSD: |
|
HP-UX: |
|
Linux: |
|
Solaris: |
|
Default tape drive
AIX: |
/dev/rmt0 |
FreeBSD: |
/dev/rsa0 |
HP-UX: |
/dev/rmt/0m |
Linux: |
/dev/st0 |
Solaris: |
/dev/rmt/0 |
Modifying tape drive settings under AIX
lsattr -E -H -l
device
Display attributes to the specified tape drive.
chdev -l rmt
n
-a block_size=
bytes
-a compress=yes
|
no \ -a ret=yes
|
no
Change settings of the specified tape drive.
The following table gives the form for the first device of each type:
|
Serial line |
Dial-out form |
Slave pseudo terminal |
AIX: |
/dev/tty0 |
/dev/tty0 |
/dev/pts/0 |
FreeBSD: |
/dev/ttyd0 |
/dev/cuaa0 |
/dev/ttyp0 |
HP-UX: |
/dev/tty0p0 |
/dev/cua0p0 |
/dev/ttyd0p0, /dev/pts/0 |
Linux: |
/dev/ttyS0 |
/dev/ttyS0 |
/dev/ttyp0 |
Solaris: |
/dev/term/a |
/dev/cua/0 |
/dev/pts/0 |
System console: /dev/console
System console device. On AIX systems, the console device in terminal mode is /dev/lft0.
Printer special filenames
First parallel port devices:
AIX: |
/dev/lp0 |
FreeBSD: |
/dev/lpt0 |
HP-UX: |
/dev/lp |
Solaris: |
/dev/ecpp0 |
Linux: |
/dev/parport0 (usually mapped to /dev/lp0) |
USB device special files
The following list shows the first file of each type.
Mouse
FreeBSD: |
/dev/ums0 |
Solaris: |
/dev/usbms |
Linux: |
/dev/input/mouse0 and /dev/input/mice |
Zip drive
FreeBSD: |
/dev/da0s4 |
Linux: |
/dev/sda4 |
Solaris: |
/dev/dsk/c1t0d0s0:c |
|
|
Printer
FreeBSD: |
/dev/ulpt0 |
Linux: |
/dev/usblp0 |
Solaris: |
/dev/usbprn0 |
|
|
Other devices found on some systems
/dev/null
Null device (discards all output; reads return 0 bytes).
/dev/zero
Returns a zero-filler buffer.
/dev/random
Random number generator.
Get Essential System Administration Pocket Reference now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.