I have an Ubuntu server VPS with DigitalOcean. This Ubuntu server contains a very simple web server and website setup, and not much else. However, whenever I create an image of the droplet (using the DigitalOcean control panel) the size is always increasing. The last image is 13GB, up from 9GB a few weeks ago... 7GB ... 5GB... just a few months ago.
So the disk space is getting eaten up, and I'm not sure why.
The /var/
directory where the website and other related assets are, including all the log files, is only using 1.3GB. So apparently this is not the source of the problem.
how can i determine what is eating up this disk space? Yes, I known I can use du, etc., but the problem is I don't know what would normally and legitimately be taking up a lot of space and what wouldn't. I want to see where this expansion in disk usage is occurring so I can then investigate to see if I can purge old/unnecessary files.
can you tell me what directories/files on an ubuntu server typically need pruning over time to prevent wasted disk space like I am experiencing?
I have enabled automatic system security updates. Could this be contributing to the problem? How would I check this? Can I clean out old files? Where would they be?
sudo apt autoremove
, then check the space left. Space consumption should be in/var
or/boot
. Do you clean after every security update? – George Udosen Apr 10 '17 at 15:199.6M /bin 694M /boot 4.0K /dev 7.8M /etc 520K /home 4.6G /lib 4.0K /lib64 16K /lost+found 8.0K /media 4.0K /mnt 15M /opt 0 /proc 59M /root 380K /run 12M /sbin 4.0K /srv 2.1G /swapfile 0 /sys 4.0K /tmp 3.4G /usr 1.6G /var So it seems the culprits are /lib + /usr (and of course /swapfile, but i was expecting that one). – penname Apr 10 '17 at 15:27