Advertising

Welcome to SparkyLinux forums
Zapraszamy również na polsko-języczne Forum https://forum.linuxiarze.pl

safest cleaning

Started by nixio, May 27, 2016, 01:42:58 AM

Previous topic - Next topic

nixio

Hi all
Please, tell me a safe method for cleaning the Sparkylinux from the accumulated debris (on disk or in the repositories), preferably, by using the Terminal (command line).
p.s.
BleachBit and(or) HDD formatting are not desirable (;
Thanks & Sorry for my dirty English ;)

paxmark1

Well - command  "apt-get autoclean"  (info via "man apt-get")  is pretty safe.   
Search forum for "More info easier via inxi"    If requested -  no inxi, no help for you by  me.

nixio

Much earlier, when I was still using Ubuntu, then for a "small cleaning" my system I used the following commands (running them from a Terminal) :
1)
sudo apt-get autoclean
It is recommended to run this command periodically to clean my system from ".deb" packages that are no longer needed.
2)
sudo apt-get autoremove
This command clears dependences after removing some packages.
3)
sudo apt-get clean
Cleaning the folder /var/cache/apt/archives/

Please, somebody, explain, may I use this (similar) scheme for the quick cleaning of my system, taking into account the peculiarities of Sparkylinux (differences from Ubuntu)?

paxmark1

YES.  Those steps are as close to perfect as you will find.  They are very "straight forward" and they are a logical sequence of events. 

The tendency  (and my usage) is to use apt-get in testing and unstable.  Aptitude is a more "thoughtful" - it puts "weights" on various paths of upgrading and when there are conflicts it will offer you solutions (full and/or partial), one at a time.  But in the much more "fluid" or moving environment of testing/unstable, apt-get is better more often. 

For autoremove, I usually wait a day, and if somehow the programs to be removed  does not feel right, I might investigate in forums or watch #debian-next on irc. 

For a little more power usage of the command line and apt-get - "apt-get -s install blah"  gives a simulation. This is quite uselful if I do not know what dependencies of a program I am installing, maybe I do not want 100mb of other programs.   "apt-get -d dist-upgrade" performs only the download of the dist-upgrade.   This allows a person using Debian testing (which Sparky uses) to look at the programs to be installed and if I choose I can look if people had problems with them 5 or more days ago in forums dedicated to unstable where they appeared before.

Best resource I know for command line updates, upgrades, dist-upgrades, etc. in a Debian testing or unstable enviroment is
http://sidu-manual/sys-admin-apt

It is a little outdated after the semi-recent changes to apt.  The references to init 3 and 5 are not useful, usage of systemctl is the proper way to enter an Xorg free tty and possibly never needed in testing. Some users in Debian unstable for major dist-upgrades in xorg or C++ (last year was a major dist-upgrade there) will do the apt-get dist-upgrade in a tty with xorg suspended via systemctl.  I doubt that many in testing do their dist-upgrades in a tty however. 

But everything else should be valid today for apt-get. 
Search forum for "More info easier via inxi"    If requested -  no inxi, no help for you by  me.

View the most recent posts on the forum