fury
Posts: 15
Joined: Thu Sep 20, 2012 4:37 pm

Why am I missing about 90MB? / Stripping unneeded things out

Sun Oct 07, 2012 3:16 pm

I have a 2gb Sandisk SD card. It's not much, but it's the only one I have at the moment.

I have been working with it for a while with no issues, but last night I ran into an out of space error while doing apt-get upgrade. It was only updating libSDL-mixer, so I was surprised that it had space to download the package list but not install a single package like that.

I checked df and much to my surprise, it shows rootfs at 100% full even though Used is less than 1K-blocks.

I cleared out a few files (deleted quake 3 source, did an apt-get clean) and this is how it is now:

Code: Select all

Filesystem  1K-blocks    Used Available Use% Mounted on
rootfs        1804128 1659960     52520  97% /
Where did the other 91,648 1K blocks go? (I did reboot, and it's about the same, a few hundred K more used)

Money's tight, I don't know when I'll get a chance to get a bigger SD card, so I want to make this one work in the meantime.

I have looked through ncdu to find the biggest users of space

What all is safe to delete out of the following, if not all?

/usr/share/icons/HighContrast/icon-theme.cache -- 73.4 mb (I don't use the high contrast theme, though I did try it once)
/usr/share/locale/everything except the language I'm using -- 147 mb
/lib/modules.bak -- 48.8 mb (presumably left over from an rpi-update)
/root/.rpi-firmware -- 98 mb (are these cache files from the rpi-update?)
/var/lib/apt/lists -- 33 mb (I thought this gets cleared out with apt-get clean)

Anything obvious that I missed?

Thanks in advance

User avatar
Jade
Posts: 17
Joined: Wed Dec 28, 2011 12:49 am
Location: Russia

Re: Why am I missing about 90MB? / Stripping unneeded things

Sun Oct 07, 2012 10:56 pm

everything you listed can be deleted, but the apt stuff will come back next time you run apt-

User avatar
jackokring
Posts: 816
Joined: Tue Jul 31, 2012 8:27 am
Location: London, UK
Contact: ICQ

Re: Why am I missing about 90MB? / Stripping unneeded things

Sun Oct 07, 2012 10:58 pm

google "inodes linux filesystem"
Pi[NFA]=B256R0USB CL4SD8GB Raspbian Stock.
Pi[Work]=A+256 CL4SD8GB Raspbian Stock.
My favourite constant 1.65056745028

JamesRonald
Posts: 7
Joined: Fri Aug 31, 2012 8:55 pm

Re: Why am I missing about 90MB? / Stripping unneeded things

Sun Oct 07, 2012 11:32 pm

By default a certain percent of the file system blocks are reserved for root so that root can still logon and do cleanup or such should the system run out of space. You can use sudo tune2fs /dev/mmcblk0p2 -1 to see how many blocks are being reserved. And use sudo tune2fs /dev/mmcblk0p2 -r0 to free the reserved blocks.

fury
Posts: 15
Joined: Thu Sep 20, 2012 4:37 pm

Re: Why am I missing about 90MB? / Stripping unneeded things

Wed Oct 10, 2012 10:23 pm

Thanks! Sure enough, it is reserving 22,912 blocks. I'll let it keep that. Now that I have over 400mb free, I feel like I could compile the whole world :D

Return to “Raspbian”