I tend to install a lot of stuff on my Ubuntu machines. Much of this I do for curiosity and then report it on my blog. This means that not only do I get to check out lots of interesting stuff, but my machines also start getting cluttered with stale files, old versions and orphaned files.
Here are two quick ways to help clean up your system.
First, you can use a built in apt-get feature called autoclean. Open a terminal session and type:
sudo apt-get autoclean
This will rid your system of partial packages and mucked up .deb downloads and can free up a suprising amount of space.
Another great tool is a package called Deborphan. You can either install this through Synaptic or again in a terminal session type:
sudo apt-get install deborphan
Once it’s installed, you can run it to list all of your orphaned packages. Think of them as packages that no longer serve a purpose and are not needed or used on your machine. Once you get a list, you can use apt-get to remove them.
sudo deborphan | xargs sudo apt-get -y remove –purge
Now you’ve saved yourself some space.