[ Previous | Next | Contents | Glossary | Home | Search ]
AIX Version 4.3 Commands Reference, Volume 2

ff Command

Purpose

Lists the file names and statistics for a file system.

Syntax

ff [ -a Number ] [ -c Number ] [ -I ] [ -l ] [ -m Number ] [ -n File ] [ -o Option ] [ -p Prefix ] [ -s ] [ -u ] [ -V VFSName ] [ -i I-Number [ ,I-Number ... ] ] [ FileSystem ]

Description

The ff command reads the i-nodes in the file system specified by the FileSystem parameter and then writes information about them to standard output. It assumes the FileSystem is a file system, which is referenced in the /etc/filesystems file, and saves i-node data for files specified by flags.

The output from the ff command consists of the path name for each requested i-node number, in addition to other file information that you can request using the flags. The output is listed in order by i-node number, with tabs between all fields. The default line produced by the ff command includes the path name and i-node number fields. With all flags enabled, the output fields include path name, i-node number, size, and UID (user ID).

The Number parameter is a decimal number that specifies a number of days. It is prefixed by a + or - (plus or minus sign). Therefore, +3 means more than 3 days, -3 means less than 3 days, and 3 means 3 days, where a day is defined as a 24-hour period.

The ff command lists only a single path name out of many possible ones for an i-node with more than one link, unless you specify the -l flag. With the -l flag, the ff command lists all links.

Flags

-a Number Displays the file if it has been accessed within the number of days specified by the Number parameter.
-c Number Displays the file if its i-node has been changed within the number of days specified by the Number parameter.
-i I-Number Displays the files corresponding to the i-node numbers specified by the I-Number parameter. The i-node numbers listed must be separated by a comma.
-I (This flag is an uppercase i.) Does not display the i-node after each path name.
-l (This flag is a lowercase L.) Additionally displays a list of pathnames for files with more than one link.
-m Number Displays the file if it has been modified within the number of days specified by the Number parameter.
-n File Displays the file if it has been modified more recently than the file specified by the File parameter.
-o Options Specifies file system implementation-specific options.
-p Prefix Adds the prefix specified by the Prefix parameter to each path name. The default prefix is . (dot).
-s Writes the file size, in bytes, after each path name.
-u Writes the owner's login name after each path name.
-V VFSName Instructs the ff command to assume the file system is of type VFSName, overriding the value in the /etc/filesystems file.

Examples

  1. To list the path names of all files in a given file system, enter:
    ff    -I    /dev/hd0
    This displays the path names of the files on the /dev/hd0 device. If you do not specify the -I flag, the ff command also displays the i-node number of each file.
  2. To list files that have been modified recently, enter:
    ff    -m    -2    -u    /dev/hd0
    This displays the path name, i-node number, and owner's user name (the -u flag) of each file on the /dev/hd0 device that has been modified within the last two days (-m -2).
  3. To list files that have not been used recently, enter:
    ff    -a    +30    /dev/hd0
    This displays the path name and i-node of each file that was last accessed more than 30 days ago (-a +30).
  4. To find out the paths corresponding to certain i-node numbers, enter:
    ff    -l    -i    451,76    /dev/hd0
    This displays all the path names (-l) associated with i-nodes 451 and 76.

Files

/etc/vfs Contains descriptions of virtual file system types.
/etc/filesystems Lists the known file systems and defines their characteristics.

Related Information

The find command, ncheck command.

The File Systems Overview for System Management in AIX Version 4.3 System Management Guide: Operating System and Devices explains file system types, management, structure, and maintenance.


[ Previous | Next | Contents | Glossary | Home | Search ]