Cache and system cleaning maintenance

As much as I want to argue that everything should be backed up, I realize that consumption devices would be a waste of time to backup if you are careful not to create any new data on them.

I have a couple of Linux Mint Debian Edition instances that I intentionally do not back up. I have Android devices (including Kindles) that I do not back up.

As long as the person is rigid in not creating data on the ‘disposable’ systems, I agree with you.

1 Like

Insightful..!
Thanks for sharing..!

Probably a bit extreme but another approach worth mentioning is mounting ~/.cache as tmpfs. Instead of cleaning it periodically, you just let the OS handle it by wiping it on every reboot automatically.

You can do it by adding something like this to your /etc/fstab:

tmpfs /home/yourusername/.cache tmpfs noatime,nosuid,nodev,size=2G 0 0

The downside is you lose anything apps were persisting there across reboots, like font caches, thumbnail caches, or shader caches if you’re gaming.

Most apps rebuild their cache pretty quickly on first launch so it really depends on what you are running.

1 Like

Dropping the contents of “.cache” is a neat idea, especially from a privacy perspective; however, there may be some downsides. I perused the subfolders and found KeePassXC “.ini” files, and many logs most notably for “virt-manager”.

1 Like

Nope. :slight_smile:

I only backup my /home partition (only the important directories) and some /etc files that I changed from the default.

As you say: “A fresh install is just as fast as restoring a backup” with as extra bonus that you can use the same “backup” for a newer OS version.

4 Likes