report number of free disk blocks
df [ -B | -I |
-P | -iv | -t ] [ -fklQ ]
[ filesystem ... ]
df reports the number of free blocks and free inodes
available for on-line filesystems by examining the counts kept in
the super-blocks. You can specify the filesystems to be
examined using their device name (for example,
/dev/root). If the filesystems are not
specified, df writes the free space on all mounted
filesystems to the standard output.
Mounted filesystems are listed in /etc/mnttab.
The first set of options select the output format.
They may not be combined except -i and -v.
If none of the options are selected,
df reports the number of free blocks and inodes.
Use portable XPG4/POSIX2 output formatting (as
for option -P) but do not truncate the filesystem device
Report the percent of inodes used as well as the number of inodes
used and free. Use the -i option with the -v
option to display counts of blocks and inodes free as well as the
percentage of inodes and blocks used.
Report inode information using the same format as the -B
Use portable XPG4/POSIX2 output formatting. The
first line of the output is a header that includes the block
size. Lines following the header show the following information for
each filesystem: device name, total space, space used,
free space, percentage of space used, and mount point.
Reports the file system's total size in blocks,
total number of inodes,
and total number of free blocks and inodes
that are currently free.
Report the percent of used blocks as well as the numbers of used and
The remaining options are used to modify
Report only an actual count of the blocks in the free list (free
inodes are not reported). With this option, df reports on
Report blocks as 1024-byte logical blocks instead of default
512-byte physical blocks.
Report local resources only.
This gives faster, but potentially inaccurate, results.
df returns 0 on successful completion, or a value greater
than 0 if an error occurred.
Errors may occur for the following reasons:
use of mutually exclusive command options
inability to obtain status information on a filesystem
user authorization is inadequate to obtain status information on a
The following example writes portable information about the
df -P /u
If the -k option is not specified,
df reports filesystem usage
in 512-byte physical blocks.
The filesystem, however,
allocates logical blocks of size 1024 bytes to files.
If a file of size 500 bytes is created,
df reports 2 blocks
less free space (rather than 1 block),
since the filesystem allocates one 1024-byte block to the file.
df prints the actual block size reported when the
-B or -P option is used.
Also see ``Limitations'' under
The behavior of this utility is affected by assignment of the
queryspace authorization for the backup subsystem in
for more details.
Differences between versions
The -Q (quick) option is provided
only for SCO OpenServer Release 5.0.6 and later.
For releases prior to SCO OpenServer Release 5.0.6,
the -f and -l options are ignored
when used with -B, -I, and -P;
the -B and -P options
cannot be used with any other options except -k,
and the -I option cannot be combined with any other.
df is conformant with:
ISO/IEC DIS 99452:1992, Information technology Portable Operating System Interface (POSIX) Part 2: Shell and Utilities (IEEE Std 1003.21992);
AT&T SVID Issue 2;
X/Open CAE Specification, Commands and Utilities, Issue 4, 1992.
A version of df
that can handle files greater than 2GB
is available in /u95/bin. See
for more information.
© 2005 The SCO Group, Inc. All rights reserved.
SCO OpenServer Release 6.0.0 -- 03 June 2005