df

display amount of free space remaining on disk 

Command


SYNOPSIS

df [-hkPt] [-timeout seconds] [ [device] [filename] ] ...


DESCRIPTION

df shows the amount of free space left on a disk device, and the total amount available on the device (free+used). It measures space in units of 512-byte disk sectors. You can specify a device either by name, or by naming any file name on that device. If you do not give an argument, df reports space for all devices known to the system.

Options

-h 

displays file sizes using more human-friendly units. Units used are:

B       Bytes
KB      Kilobytes
MB      Megabytes
GB      Gigabytes
TB      Terabytes
PB      Petabytes
EB      Exabytes

When this option is specified, each file size is displayed using the most appropriate unit and is rounded to two decimal places.

-k 

uses 1024-byte (1K) units instead of the default 512-byte units when reporting space information.

-P 

lists complete information on space used, in the following order:

  • file system name
  • total space
  • space used
  • space free
  • percentage of space used
  • file system root
-t 

lists space used as well as space free.

-timeout seconds 

specifies the number of seconds that df has to complete the operation before timing out and issuing an error.


ENVIRONMENT VARIABLES

TK_DISPLAY_DEVICE_NAME 

When set to a non-zero value, df displays the device name (for example, C:/) in the file system column. When this variable is not set or set to zero, df displays the volume name. By default, this variable is not set.


DIAGNOSTICS

Possible exit status values are:

0 

Successful completion.

1 

Failure due to any of the following:

— cannot access filename
— cannot access device
device is not a device
2 

Invalid command line option.


PORTABILITY

POSIX.2. x/OPEN Portability Guide 4.0. All UNIX systems. Windows 7. Windows Server 2008 R2. Windows 8. Windows Server 2012. Windows 10. Windows Server 2016.


AVAILABILITY

PTC MKS Toolkit for Power Users
PTC MKS Toolkit for System Administrators
PTC MKS Toolkit for Developers
PTC MKS Toolkit for Interoperability
PTC MKS Toolkit for Professional Developers
PTC MKS Toolkit for Professional Developers 64-Bit Edition
PTC MKS Toolkit for Enterprise Developers
PTC MKS Toolkit for Enterprise Developers 64-Bit Edition


SEE ALSO

Commands:
du, ls


PTC MKS Toolkit 10.1 patch 1 Documentation Build 2.