Keeping things clean

All Gurus once were Newbies
Forum rules
There are no such things as "stupid" questions. However if you think your question is a bit stupid, then this is the right place for you to post it. Please stick to easy to-the-point questions that you feel people can answer fast. For long and complicated questions prefer the other forums within the support section.
Before you post please read this

Keeping things clean

Postby Dwood on Sun Mar 02, 2008 5:52 pm

In windows it is necessary from time to time to delete various files that build up, such as temporary files, log files, internet cache etc. to stop you hard disk getting filled up.

Is it necessary to do this with Linux?
If so what files should I be cleaning up and is there a safe way to do so?

I am sure I read somewhere that there is an 'autoclean' command for apt-get as it caches all the programmes that are downloaded and they stay there even if deleted from the system.
Dwood
Level 2
Level 2
 
Posts: 55
Joined: Thu Jun 21, 2007 12:25 pm

Linux Mint is funded by ads and donations.
 

Re: Keeping things clean

Postby proxima_centauri on Sun Mar 02, 2008 6:36 pm

sudo apt-get clean will remove all of the downloaded packages used by apt-get/synaptic to install programs. these are perfectly safe to remove since you presumable won't have to install whatever again, but even if you did, its just another download away.
sudo apt-get autoclean will remove any partially downloaded packages used by apt-get/synaptic, also safe to remove.
you can manually see these files in /var/cache/apt/archives/, you can also delete them from that location manually as root.

also in synaptic if you click on the status bar it should split up packages into installed, installed (local or obsolute)
, installed (auto removable), not installed, and residual config.
residual config and installed (auto removable) are generally safe to remove, but don't deleted installed (local or obsolute) because I know i have a couple stuff in there which I would not remove.
For a more detailed response go here http://ubuntuforums.org/showthread.php?t=140920
And read some of the following posts concerning steps 4&5 which should only be attempted if you know what you're doing.
User avatar
proxima_centauri
Level 11
Level 11
 
Posts: 3968
Joined: Tue Dec 25, 2007 3:24 pm
Location: NB, Canada

Re: Keeping things clean

Postby muskratmx on Mon Mar 03, 2008 1:05 am

You can also set your browser to cleanup after it's self each time you shut down the browser.

There is some other programs that build up. one is photo viewers have a tendency to build up a lot of thumb nails. I've found it necessary to delete these some times.
User avatar
muskratmx
Level 4
Level 4
 
Posts: 226
Joined: Sun Dec 09, 2007 1:30 pm
Location: TX/MX Gulf Coast

Re: Keeping things clean

Postby jbaerbock on Mon Mar 03, 2008 3:46 am

Been using Mint and Linux for a long time and never knew this, thanks loads. Yet another good thing about Linux hehehehe.
jbaerbock
Level 4
Level 4
 
Posts: 309
Joined: Tue Jun 05, 2007 11:31 pm
Location: St. Peter, MN

Re: Keeping things clean

Postby MagnusB on Mon Mar 03, 2008 11:15 am

proxima_centauri wrote:sudo apt-get clean will remove all of the downloaded packages used by apt-get/synaptic to install programs. these are perfectly safe to remove since you presumable won't have to install whatever again, but even if you did, its just another download away.
sudo apt-get autoclean will remove any partially downloaded packages used by apt-get/synaptic, also safe to remove.

1. apt-get autoclean also removes dated package (if you have a newer installed, then it delete the oldest package). It might be a good idea to keep a local repository if you have a slow internet connection though. Autoclean would be the way to go then.
also look at apt-get autoremove, which removes unneeded packages (I use aptitude to avoid this issue though).
Also, look at /var/cache and /home/user/.thumbnails have a tendency to take up space. I could dig up a post were I helped with similar issues.
Image
You're not drunk if you can lie on the floor without holding on.
--Dean Martin
MagnusB
Level 6
Level 6
 
Posts: 1255
Joined: Sun Nov 18, 2007 12:39 pm
Location: Norway

Re: Keeping things clean

Postby Dwood on Tue Mar 04, 2008 6:11 pm

also look at apt-get autoremove, which removes unneeded packages (I use aptitude to avoid this issue though).


What is the difference between apt-get and aptitude?
Dwood
Level 2
Level 2
 
Posts: 55
Joined: Thu Jun 21, 2007 12:25 pm

Re: Keeping things clean

Postby MagnusB on Tue Mar 04, 2008 6:20 pm

aptitude handles dependencies better, this is especially noticed when removing packages.
Image
You're not drunk if you can lie on the floor without holding on.
--Dean Martin
MagnusB
Level 6
Level 6
 
Posts: 1255
Joined: Sun Nov 18, 2007 12:39 pm
Location: Norway

Re: Keeping things clean

Postby Dwood on Tue Mar 04, 2008 7:01 pm

So when I use synaptic package manager, does that use apt-get or aptitude?
Dwood
Level 2
Level 2
 
Posts: 55
Joined: Thu Jun 21, 2007 12:25 pm

Re: Keeping things clean

Postby MagnusB on Wed Mar 05, 2008 10:17 am

apt-get, I think..
Image
You're not drunk if you can lie on the floor without holding on.
--Dean Martin
MagnusB
Level 6
Level 6
 
Posts: 1255
Joined: Sun Nov 18, 2007 12:39 pm
Location: Norway

Re: Keeping things clean

Postby Texas_Mike on Fri Mar 07, 2008 11:07 pm

When I ran pure Debian, I only used Aptitude for package management. Aptitude is the Debian preferred way of package management. If you go this route, the very first command you should enter is sudo aptitude keep-all.

I would also suggest downloading deborphan if not already installed. Then by using aptitude purge $(deborphan) will remove any orphaned packages lying around.

Also, run sudo updatedb from time to time.
Insanity: doing the same thing over and over again and expecting different results

TexasMike
Mint KDE
User avatar
Texas_Mike
Level 1
Level 1
 
Posts: 15
Joined: Tue Jan 01, 2008 5:13 pm
Location: Texas

Re: Keeping things clean

Postby boilertech on Sun Mar 09, 2008 8:35 pm

I run a program called KleanSweep. It is made for KDE but runs just fine in my Gnome machine.
KleanSweep allows you to reclaim disk space by finding unneeded files. It can search for files basing on several criterias; you can seek for:

* empty files
* empty directories
* backup files
* broken symbolic links
* broken executables (executables with missing libraries)
* dead menu entries (.desktop files pointing to non-existing executables)
* duplicated files
* orphaned files -- files not found in RPM (for rpm-based distros, e.g. Fedora Core, Suse) or DPKG (for dpkg based distros, e.g. Debian and Ubuntu) database
* obsolete thumbnails (thumbnails conforming to freedesktop.org standard, pointing to non-existing images)
Download here. http://linux.bydg.org/~yogin/# Just be careful and stick with your home directory.
User avatar
boilertech
Level 1
Level 1
 
Posts: 8
Joined: Sun Dec 31, 2006 3:37 pm

Linux Mint is funded by ads and donations.
 

Return to Newbie Questions

Who is online

Users browsing this forum: Bing [Bot], noobazoid, Pierre, Pilosopong Tasyo and 21 guests