Tumbleweed (and Leap) maintenance best practices

I’d like to know how veteran openSUSErs maintain their systems. Are there utilities that you run regularly, directories that you regularly trim?

The reason I ask:

If I hadn’t stumbled across this recent thread:

http://lists.opensuse.org/opensuse-factory/2020-02/msg00025.html

I might never have heard of .rpmnew files, or been motivated to investigate the related utilities rpmconfigcheck.
(I just found one mention of rcrpmconfigcheck at: https://en.opensuse.org/SDB:Offline_upgrade , but can’t remember seeing it mentioned elsewhere in openSUSE documentation.)

Imagine my surprise when I finally ran rpmconfigcheck a few days ago! I had over twenty .rpmnew and .rpmsave files accumulated since I adopted Tumbleweed more than two years ago. I’ll be sure to run it from now on, but would like to know if there are other maintenance steps I should be taking that I’m not taking now.

I always use zypper dup with Tumbleweed, never zypper up.

I installed tmpwatch, run it regularly, and also prune logs with journalctl --vacuum-time.

For me, that’s about it.

Hi
Only when something goes funky :wink: then use diff -Naur <old_file> <new_file> to see what changed. Moving forward with files moving to /usr/etc the files in /etc (under admin control) should be the ones tweaked. Likewise for services or timers to override /usr/lib/systemd/system copy them to /etc/systemd/system and tweak as required (eg purge-kernels.service).

I do configure “/tmp” to be mounted from tmpfs (i.e. in effect it is a ramdisk). That keeps “/tmp” reasonably clean.

On Tumbleweed, I occasionally run “rpmconfigcheck”. Here occasionally means when I think of it (which is not often), or when something breaks. If there are changes, I use “diff” to compare the old and new, and then attempt to come up with a suitably merged results. I’m never sure whether I get it right.

Yes, I did recently deal with “nsswitch.conf”, so I did not run into problems with the last update. But I’ll check closely on a system that I have not yet updated.

For Leap, I rarely bother with “rpmconfigcheck”. But then I usually do a clean install for each release (but keeping “/home”. If I were upgrading, then an “rpmconfigcheck” would be appropriate.

I occasionally run:

zypper packages --orphaned

and then remove any orphaned packages (unless that causes a conflict).

And yes, “zypper dup” for updating Tumbleweed. For leap, I normally use Yast online update followed by “zypper up”.

Thanks for your feedback, malcolmlewis and nrickert. I just ran zypper packages --orphaned and found over thirty, although some belong to programs acquired outside of the repos, like Crossover and Master PDF Editor. I’ll see what I can remove.

FWIW, I hunted online after reading your post and found another linux utility, rpmorphan, that reported even more orphaned packages. I’m inclined to play it safe and stick with the zypper command. I’m not short of disk space.

Of course, I am not suggesting that you remove programs that you want.

What sometimes happens, though, is that an older program is superseded by a newer one with a slightly different name. So the older version, if still installed, is just clutter that can lead to dependency conflicts in future.

A couple more commands:

$ echo 'Listing failed services...'
$ systemctl -a --state=failed
# echo 'Listing errors from the journal'
# journalctl -xb -p 0..3

Update of rstudio failed. Removing rstudio with its 181 dependencies and reinstalling fixed that. :wink: