3.5 GB rootfs is full?


15 posts
by kghunt » Wed Jul 11, 2012 11:59 am
My rootfs is full but I have not installed much. I don't even use the gui it is headless. Any idea what could be filling it up. I deleted most of the log files.
Posts: 355
Joined: Sun Mar 04, 2012 9:28 am
by itimpi » Wed Jul 11, 2012 12:10 pm
How big is your SD card? If it is larger than 2GB, have you followed the steps for resizing the partitions to use the full card as described at http://elinux.org/RPi_Resize_Flash_Partitions
Posts: 1034
Joined: Sun Sep 25, 2011 11:44 am
Location: Potters Bar, United Kingdom
by Joe Schmoe » Wed Jul 11, 2012 12:18 pm
If it really is 3.5GB, then this is probably *not* a "failure to enlarge" problem.

AFAIK, all the distributed distros are setup as a 2G image. So, if it really is 3.5, then the OP must have already enlarged.
Never answer the question you are asked. Rather, answer the question you wish you had been asked.

- Robert S. McNamara - quoted in "Fog of War" -
Posts: 2682
Joined: Sun Jan 15, 2012 1:11 pm
by kghunt » Wed Jul 11, 2012 12:24 pm
Yes I enlarged my root partition in gparted before I first booted the Pi. I removed a load of packages and deleted some logs. I rebooted and not it is reporting 1.3 GB free? It didn't seem to update automatically until I rebooted.
Posts: 355
Joined: Sun Mar 04, 2012 9:28 am
by Mortimer » Wed Jul 11, 2012 12:31 pm
I wonder if this is the same thing I am seeing. I posted a similar issue with a new 4GB card I loaded with Wheezy yesterday.

viewtopic.php?f=50&t=8071&start=375#p120831
User avatar
Posts: 715
Joined: Sun Jun 10, 2012 3:57 pm
by Alec » Wed Jul 11, 2012 12:52 pm
Might this be related to an absence of garbage collection on the SD card? (A la TRIM, as per: http://en.wikipedia.org/wiki/TRIM )
Posts: 20
Joined: Sat Jan 14, 2012 8:18 pm
by jojopi » Wed Jul 11, 2012 1:34 pm
kghunt wrote:Yes I enlarged my root partition in gparted before I first booted the Pi. I removed a load of packages and deleted some logs. I rebooted and not it is reporting 1.3 GB free? It didn't seem to update automatically until I rebooted.
If you delete a file that is currently in use, then the space will not be freed until all processes have closed it. So if you delete a large log file you may need to restart rsyslogd. Or if you have upgraded or removed packages you may need to restart or kill the relevant applications. A log file can even continue to grow after it has been deleted, if something is still writing to it.
User avatar
Posts: 2079
Joined: Tue Oct 11, 2011 8:38 pm
by jamesh » Wed Jul 11, 2012 1:43 pm
Can you find out where all the space is being used? Not sure how to do it on the command line, some sort of disk usage analyser?
Unemployed software engineer currently specialising in camera drivers and frameworks, but can put mind to most embedded tasks. Got a job in N.Cambridge or surroundings? I'm interested!
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 11748
Joined: Sat Jul 30, 2011 7:41 pm
by asb » Wed Jul 11, 2012 1:47 pm
jamesh wrote:Can you find out where all the space is being used? Not sure how to do it on the command line, some sort of disk usage analyser?


ncdu is your friend here.
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 799
Joined: Fri Sep 16, 2011 7:16 pm
by jojopi » Wed Jul 11, 2012 2:04 pm
asb wrote:ncdu is your friend here.
This does not appear to be able to detect files with no remaining links.
User avatar
Posts: 2079
Joined: Tue Oct 11, 2011 8:38 pm
by asb » Wed Jul 11, 2012 2:10 pm
jojopi wrote:
asb wrote:ncdu is your friend here.
This does not appear to be able to detect files with no remaining links.


That's right, it won't help with the problem you answered, where you delete a large log file but it is still taking up space as the handle is still open.
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 799
Joined: Fri Sep 16, 2011 7:16 pm
by jamesh » Wed Jul 11, 2012 3:12 pm
Does a reboot close all the outstanding handles?
Unemployed software engineer currently specialising in camera drivers and frameworks, but can put mind to most embedded tasks. Got a job in N.Cambridge or surroundings? I'm interested!
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 11748
Joined: Sat Jul 30, 2011 7:41 pm
by asb » Wed Jul 11, 2012 3:29 pm
jamesh wrote:Does a reboot close all the outstanding handles?


Yep.
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 799
Joined: Fri Sep 16, 2011 7:16 pm
by felixfurtak » Thu Jul 12, 2012 11:18 am
what is the output from :-

df -h ?

you could clear some space easily using

sudo apt-get clean
Posts: 47
Joined: Wed Nov 16, 2011 10:41 am
by Killerbee » Thu Jul 12, 2012 3:19 pm
FYI

I can remember I had this PB as well. I used another linux box to check the SD card file system. I used gparted. Gparted showed me that my 4GB card was full and completely "used" :cry: I run the "check fs option" for my SD card and suddenly 2GB was free. :)
Posts: 62
Joined: Tue Sep 20, 2011 6:38 pm