Mismatch between total filesystem capacity and actual usage

Asked by Michael Rodden on 2008-01-23

Sorry! Newbie! My system informs me that my hard disk is full, and I am having problems functioning. I can't even power down properly. Disk Usage Analyser shows that 'Total file system capacity: 35.2 GB (used: 34.3 GB available 827.5 MB). However in the detail the / capacity totals 9.1 GB! Where has all the other capacity gone? I have Gutsy. Any help appreciated. I have an IBM T40 and have had less than successful attempts at hibernate/suspend modes and wondered if it might be to do with that...

Question information

English Edit question
Ubuntu Edit question
No assignee Edit question
Solved by:
Michael Rodden
Last query:
Last reply:

You can clear out old packages to give you some room to breath with these two commands executed from a terminal.

sudo apt-get autoclean
sudo apt-get autoremove

Michael Rodden (mrodden) said : #2

Thanks Alan but hasn't done a lot of good. Still 25 GB adrift! And there all
sorts of odd things going on with Firefox and history and remembered
passwords... Keeping calm and hoping backup is up to date!

------ Original Message ------
Received: Wed, 23 Jan 2008 01:06:16 PM GMT
From: Alan Pope <email address hidden>
To: <email address hidden>
Subject: Re: [Question #22881]: Mismatch between total filesystem capacity and
actual usage

Your question #22881 on Ubuntu changed:

    Status: Open => Answered

Alan Pope proposed the following answer:
You can clear out old packages to give you some room to breath with
these two commands executed from a terminal.

sudo apt-get autoclean
sudo apt-get autoremove

If this answers your question, please go to the following page to let us
know that it is solved:

If you still need help, you can reply to this email or go to the
following page to enter your feedback:

You received this question notification because you are a direct
subscriber of the question.

Michael Rodden (mrodden) said : #3

Not sure what else I can do...

Helton Dória (helton-doria) said : #4


You can verify the real ocupation of your hard disk by typing the command "df -h" in your terminal. If you indeed need more free space, you will need to remove old data or unused applications.



Michael Rodden (mrodden) said : #5

Thanks Helton and this shows that all 35 GB have been used. But I don't know what to remove because Disk Usage Analyser shows only 9 GB used. I don't know where the other 25 GB is, so I can't remove it.

Helton Dória (helton-doria) said : #6


You have two ways to discovery this: through Disk Usage Analyser or through the command line. In the frist one, you need to click on the button "Scan Filesystem" to see the used spaces of the sub-directories. In the second way, you need to open a terminal, navigate to the root directory and type
"sudo du -h --max-depth=1 > disk_usage.txt". All the disk usage statistic will be writed in the disk_usage.txt file.

To see more details, raise the value of --max-depth. If you want to know the usage of a especific directory, put the full path of the directory after --max-depth=X (like "sudo du -h --max-depth=1 /home").



Michael Rodden (mrodden) said : #7

Helton you are a star! Scan Filesystem doesn't pick up anything but the du command you gave me showed that the missing 23 GB are in a backup directory /var/backup This is a sbackup directory that I had set up and forgot about and it has been building up for some time. Only problem now is that I cannot access the directory to delete the files! And rm doesn't work either. Any ideas?

Hans van den Bogert (hbogert) said : #8

what do you mean by access?
are you sure you're using a sudo in front of rm? as well as the ' -r ' parameter (-r deletes recursive/directories)

Michael Rodden (mrodden) said : #9

Helton, I think I have done it by purging the old backups. It looks like my space is back! Many thanks for your help. If you are ever in Yorkshire I owe you a pint or two!