System Administration Guide: Devices and File Systems

Commands for File System Administration

Most commands for file system administration have both a generic component and a file system–specific component. Whenever possible, you should use the generic commands, which call the file system–specific component. The following table lists the generic commands for file system administration, which are located in the /usr/sbin directory.

Table 15–1 Generic Commands for File System Administration

Command 

Man Page 

Description 

clri

clri(1M)

Clears inodes 

df

df(1M)

Reports the number of free disk blocks and files 

ff

ff(1M)

Lists file names and statistics for a file system 

fsck

fsck(1M)

Checks the integrity of a file system and repairs any damage found 

fsdb

fsdb(1M)

Debugs the file system 

fstyp

fstyp(1M)

Determines the file system type 

labelit

labelit(1M)

Lists or provides labels for file systems when they are copied to tape (for use by the volcopy command only)

mkfs

mkfs(1M)

Creates a new file system 

mount

mount(1M)

Mounts local and remote file systems 

mountall

mountall(1M)

Mounts all file systems that are specified in the virtual file system table (/etc/vfstab)

ncheck

ncheck(1M)

Generates a list of path names with their inode numbers 

umount

mount(1M)

Unmounts local and remote file systems 

umountall

mountall(1M)

Unmounts all file systems that are specified in a virtual file system table (/etc/vfstab)

volcopy

volcopy(1M)

Creates an image copy of a file system 

How File System Commands Determine the File System Type

The generic file system commands determine the file system type by following this sequence:

  1. From the -F option, if supplied.

  2. By matching a special device with an entry in the /etc/vfstab file (if special is supplied). For example, fsck first looks for a match against the fsck device field. If no match is found, it then checks the special device field.

  3. By using the default specified in the /etc/default/fs file for local file systems and in the /etc/dfs/fstypes file for remote file systems.

Manual Pages for Generic and Specific Commands

Both the generic commands and specific commands have manual pages in the man pages section 1M: System Administration Commands. The manual page for the generic file system commands provide information about generic command options only. The manual page for a specific file system command has specific information about options for that file system. To look at a specific manual page, append an underscore and the abbreviation for the file system type to the generic command name. For example, to see the specific manual page for mounting a UFS file system, type the following:


$ man mount_ufs