Determining Free Disk Space On Linux

March 6th, 2006 § 0

This will let you know how to determine free disk space on a *nix box (Linux, FreeBSD, Mac OS X, Solaris, etc.) The man page for df says this:

df - report filesystem disk space usage

When I type df -k on one of my Linux machines, it tells me how much free space (in Kilobytes) I have on each of my mounted filesystems. Here is the output:

[daniel@localhost daniel]$ df -k
Filesystem 1K-blocks Used Available Use% Mounted on
/dev/hda2 76541056 31788324 40864604 44% /
/dev/hda1 101089 9272 86598 10% /boot
none 188248 0 188248 0% /dev/shm

This tells me that I have about 56% free space on my main /dev/hda2 partition, which is mounted at /. This translates into roughly 40864604 Kilobytes, or 40GB.

Your output will vary depending on the number of filesystems you have, and where they are.

Like it? Share it:
  • Print
  • Facebook
  • Twitter
  • Digg
  • LinkedIn
  • StumbleUpon
  • Reddit
  • Technorati
  • del.icio.us
  • Google Bookmarks

§ Leave a Reply

What's this?

You are currently reading Determining Free Disk Space On Linux at humandoing software.

meta