• Home
  • Help
  • Search
  • Login
  • Register
Pages: [1]
Author Topic: rootfs size  (Read 1103 times)
androidcoolguy
Newbie
*

Karma: 0
Posts: 13


View Profile
« on: April 29, 2011, 11:27:02 AM »

I am not sure I remember correctly, but I read before that the total size of a brand new guruplug server plus's root directory i.e. / is like 250MB. Mine is like 500MB, do you know what could have occupied so much space?

Thanks.
Logged

androidcoolguy
Newbie
*

Karma: 0
Posts: 13


View Profile
« Reply #1 on: April 29, 2011, 03:57:49 PM »

I am new to Linux too. So this is another question.  I noticed when I started couples of weeks back, the rootfs / was around 250MB. I performed multiple soft links e.g.

ln -s /media/usb0 /disk1

ln -s /media/usb1 /disk2

ln -s /media/usb3 /disk3

I remove some of the above USBs, but I don't think I unmount it properly. Could that contributed to some extra large file (corruption) in the rootfs?

Thanks for any insight.
Logged

spinifex
Full Member
***

Karma: 8
Posts: 167



View Profile WWW
« Reply #2 on: April 29, 2011, 04:27:44 PM »

Start with

Code:
# du -sh /var

Logged

androidcoolguy
Newbie
*

Karma: 0
Posts: 13


View Profile
« Reply #3 on: April 29, 2011, 04:30:37 PM »

It showed 178MB.  Almost accounts for the "missing" space, can I remove anything under /var?

Thanks.
Logged

spinifex
Full Member
***

Karma: 8
Posts: 167



View Profile WWW
« Reply #4 on: April 30, 2011, 07:41:35 PM »

Experiment. Backup before you try anything.

Code:
du -h --max-depth 1 /var

1. log

Refine your /etc/rsyslog.conf and /etc/logrotate.conf setups to minimize the size of your logs. You can delete logfiles that are not in use.

2.  apt

Try

Code:
# apt-get autoremove
# apt-get autoclean

The largest directory generated by apt is usually  /var/cache/apt

3.   Doc.

If you do not want man pages and docs you can delete files in the following directories
/usr/share/doc
/usr/share/man
/usr/share/doc-base


You might also check out localepurge

Logged

androidcoolguy
Newbie
*

Karma: 0
Posts: 13


View Profile
« Reply #5 on: May 01, 2011, 06:30:33 AM »

/var/log is only around 6MB, but localepurge helped to cut another 33MB! Thanks for that. There are still another 200 to 250 MB unaccounted for. I used some script to scan for largest files, could not find any suspicious candidate to remove.

Might it be that there are thousands of small files lying somewhere that I do not know how to scan for?
Logged

spinifex
Full Member
***

Karma: 8
Posts: 167



View Profile WWW
« Reply #6 on: May 01, 2011, 03:38:37 PM »

du reports the size directory contents so -

Code:
# du -sh /var |grep M

should nail it
Logged

Pages: [1]
Print
Jump to: