Clearing Package Cache on Debian/Ubuntu

Written by on Sunday, February 8, 2009 12:51 - 0 Comments

If you are running Debian or Ubuntu on a small hard drive, it might be helpful to delete the cache of package files. These tend to build up over time, because the apt will keep all packages it has downloaded by default, in case they may be needed again in the future.

Use: apt-get

This will clear the local repository of all retrieved package files. This means that it will remove everything except the lock file from two directories:

/var/cache/apt/archives/
and
/var/cache/apt/archives/partial/.

To clear the cache from the command line, type:

$ sudo apt-get clean
OR
# apt-get clean

If you are not running APT very often, it may be a good idea to use the command line options periodically, which will clean up out-dated and no longer available packages which are simply taking up space.

Article written by MyComputerAid.com



Leave a Reply

You must be logged in to post a comment.

2003 server - Sep 30, 2008 22:34 - 0 Comments

instant messaging srv records

More In Computers & PC


Microsoft Outlook - Mar 22, 2009 11:22 - 0 Comments

Outlook: Duplicates in Mailbox

More In Computers & PC