Search this blog

lundi 20 juin 2011

Clean Ubuntu cache

Packages cache:
sudo aptitude autoclean 
sudo aptitude clean
User's trash folder:
rm -r -f ~/.local/share/Trash/files/*
7 days-old user's thumbnails:
find ~/.thumbnails -type f -atime +7 -exec rm {} \;
Multiple Linux kernels:
  • Identify installed kernels:
sudo dpkg -l | grep linux
  • Delete kernels not used anymore but keep installed the 2 latests. Ex. to delete kernel 2.6.32-25:
sudo aptitude purge linux-headers-2.6.32-25 linux-headers-2.6.32-25-generic linux-image-2.6.32-25-generic
Configuration files (may not work):
sudo dpkg --purge $(COLUMNS=200 dpkg -l | grep "^rc" | tr -s ' ' | cut -d ' ' -f 2)
Internet programs:

Internet browsers and email clients could use lot of disk space to store browsing history, offline data or emails. Check your programs preferences to clear automatically or manually the cache. Additionally, set a limit to the amount of space that could be used for storage. For example in Firefox 5.0 see:
  • Preferences/Privacy/Clear your recent history
  • Preferences/Advanced/Network/Offline storage/
    • Clear now
    • or Limit cache to ...

Partly from: http://www.commentcamarche.net/faq/7214-faire-le-menage-dans-ubuntu-residus-de-configuration-paquets

Disable Windows 7 automatic restart after updates

  1. Click the Start menu and type "gpedit.msc" (without quotes) in the search line and press the enter key. This will launch the Local Group Policy Editor.
  2. On the left side of Local Group Policy Editor, expand to Computer Configuration > Administrative Templates > Windows Components. Then scroll down and select Windows Update.
  3. Double click "No auto-restart with logged on users for scheduled automatic updates installations" option. In the properties window that appears, change the option from "Not Configured" to "Enabled". Click "OK" and close Local Group Policy Editor. Windows will no longer prompt you to restart after automatically installing updates.
From: http://www.ehow.com/how_5573302_disable-windows-auto-update-restart.html