Keeping your system up to date and doing a little maintenance from time to time. Searching on your particular distro to do this is easy enough. For a Debian based distro using apt, I've come up with my own little procedure. It may not be the best way, but works well for me. It's just my example of what i do.
Cleaning up apt, beyond just updates and upgrades....
I made it simple with one long command adding a little cli wifi info at the end just to see that my vpn is running at a glance....
sudo apt-get update; sudo apt-get dist-upgrade; sudo apt-get clean; sudo apt-get autoclean; sudo apt-get autoremove; sudo apt-get autoremove --purge; sudo apt-get check; nmcli connection show
Don't use without researching each command in the above. I use it sparingly.
Clean up some other stuff..... "sparingly^
sudo rm -rf /root/.local/share/Trash/
/*; sudo rm -rf /home/
/.local/share/Trash//*
; sudo rm -rf ~/.cache/thumbnails/
A few things not needed very often, but good to know...
If your syslog has gotten very huge and you want to start over with a clean log....
sudo sh -c 'echo > /var/log/syslog'
Or..... as root... "sudo su" can paste the following and execute...
for CLEAN in $(find /var/log/ -type f)
do
cp /dev/null $CLEAN
done
Afterwards I use bleachbit sparingly to puge misc stuff that accumilated over time.
When I'm done and after reboot, the system may react alittle slugish as if it was just installed, but quickly accumulates what it needs to take off like normal.
Maybe a overkill on my part, and is definitely not something I do a lot. Just something I like do do occasionally after a lot of installing or removing of apps and making changes, and when i feel my system is solid and could use a good cleaning.
Researching a maintenance method for your system is a good thing, whether extreme or light... Don't use mine specifically!... it's just an example I came up with for me, that takes me about 5 mins to complete and reboot.
Lastly.... a good backup plan. I like to use the app timeshift and keep a few backups. If by chance i totally screwed up enough that X doesnt start... at the flashing promt, I log in and....
sudo timeshift --restore
Luckily i haven't needed to do this yet, but researching a good backup plan is good when running Linux, especially when you open the hood as ofen as I do lately.
I like to read a a lot on a subject, then come up with a plan. It's Linux
