fstab.4 (2010 09)

f
fstab(4) fstab(4)
swapfs, the entry is ignored by the
mount and fsck commands (see mount (1M)
and fsck (1M)). fsck also ignores entries with type specified as
cdfs, nfs, memfs,
or
lofs.
options A comma-separated list of option keywords, as found in
mount
or swapon (see
mount(1M) and swapon (1M)). The keywords used depend on the parameter
specified in type .
backup frequency Reserved for possible use by future backup utilities.
pass number Used by the
fsck command to determine the order in which file system checks are
done. The root file system should be specified with a pass number of 1, to be
checked first, and other file systems should have larger numbers. (A file system
with a pass number of zero is ignored by the
fsck command.)
File systems within a drive should be assigned different pass numbers, but file sys-
tems on different drives can be checked on the same pass, to utilize possible paral-
lelism available in the hardware. If pass number is not present,
fsck checks each
such file system sequentially after all eligible file systems with pass numbers have
been checked.
comment An optional field that begins with a
# character and ends with a new-line charac-
ter. Space from the pass number to the comment field (if present) or to the new-line
is reserved for future use.
There is no limit to the number of device special file fields in
/etc/fstab.
NETWORKING FEATURES
NFS
If the field type is
nfs, a remote NFS file system is implied. For NFS file systems, the device special file
should be the serving machine name followed by ":" followed by the path on the serving machine of the
directory being served. The pass number and backup frequency fields are ignored for NFS entries.
EXAMPLES
Examples of typical
/etc/fstab entries:
Add an HFS file system at
/home using default mount options; (backup frequency 0) fsck pass 2:
/dev/dsk/c0t6d0 /home hfs defaults02#/home disk
Add a swap device to a system managed using LVM, with default options (Note, the directory field
(
/) cannot be empty, even though it is ignored):
/dev/vg01/lv10 / swap defaults00#swap device
Add a swap device on a system implementing whole-disk layout to use the space after the end of the
file system (options=end):
/dev/dsk/c0t5d0 / swap end00#swap at end of device
Add file system swap space on the file system containing directory /swap. type is swapfs; set
options to min=10, lim=4500, res=100, and pri=0 (see swapon (1M)) for explanation of
options ). device field is ignored but must not be empty:
default /swap swapfs min=10,lim=4500,res=100,pri=0 0 0
(Note that both a file system entry and a swap entry are required for devices providing both ser-
vices.)
Use a device for dump space if the system crashes. directory field is ignored but must not be empty:
/dev/dsk/c0t5d0 / dump defaults 0 0
(Note that both a swap entry and a dump entry are required for devices providing both services.)
Add a MemFS file system at
/mnt of size=100MB. The device special file field is ignored but must
not be empty:
memfs /mnt memfs size=100MB 0 0
WARNINGS
HP-UX system administration tools that provide file system mount management interfaces may read
and/or write /etc/fstab. System administrators should be careful not to simultaneously modify this
2 Hewlett-Packard Company 2 HP-UX 11i Version 3: September 2010