Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I need help in some linux commands regarding disk space.

When i see disk space using " df -h " it list all partitions with space left in percentage. But here are few things i need to know more .

  1. If i need to see which partition the particular dir is. For example if i want to see " /var/www/ " 's partition .

  2. And If i want to see how much space left in particular partition .


share|improve this question

migrated from Jun 21 '10 at 5:27

This question came from our site for system and network administrators.

Just add the directory in question to the command line.

For instance df /home/dspillett will tell me the amount of space available on the partition mounted as /home (which happens to contain /home/dspillett).

df will derive which filesystem the named directory is within and show you space stats for that. You can also use df . to find the available/used/free space on the filesystem containing your current working directory, whatever that happens to be.

share|improve this answer

You must log in to answer this question.