After updates

I use zypper dup exclusively to get updates. Sometimes the final line in the terminal recommends a reboot. More often, it recommends restarting processes. Running zypper ps -s often shows dozens of processes that should be restarted. My solution is always reboot. But is there another way? Log out and back in? A cli command to restart all the listed processes? Do nothing and wait until they restart in the normal course of things? Restart one or two “important” processes?

TW reboots so fast, it isn’t a burden to reboot. Still, I’d like to know the best way.

To begin with, Unix/Linux is very well adapted to let programs that are updated running without problem. In the simple case, the file with the executable will be replaced with a new one, But the old file will not be removed until no process is anymore using it. Thus a new start of a program after an update will start the new executable and an already running instance of the same program will still run from the old executable.

That said, the situation can be more difficult. When a program uses modules that it loads dynamically, the already running old executable may try to load an updated module, which may, or may not lead to problems. I often experience this with Firefox. Often while running Firefox and then updating it, a short while after i get problems with Firefox. Closing it and starting anew helps of course.
That is also the reason that when the kernel, which is very modular, is updated, a reboot is suggested.

So basically, when you know exactly what is running, and how that is “constructed”, you could exactly decide what is minimal needed to avoid problems.

I daily life, when it is mostly about user programs, logout (of all users) is enough.
This morning there was an Apache update on my system that runs a web server. I could either have waited if problems arose (of course testing if I still could get at least one page from it), or restart the Apache server , or reboot the system.

In short: it is of course again you as system manager, that should decide based on the impact system outage has on your user population if you do or not things like

  • arrange a fixed maintenance window with your users where they know they can not use the system, because you take possession and thus can make backups, update and reboot, etc. at your need.
  • check first the list of packages that are in the update queue to see if you can do most or all of them directly without disturbing the services you offer and do some, like Apache or kernel on a later time/date.
  • or, in simple situations (like one desktop delivering system with you as the normal desktop user) simply update, run happy until something breaks and then either log-out/login or reboot as you think fit.

Hi
All depends on what services need restarting… kernel update and systemd reboot, I generally restart others manually if only a couple, or just leave them running and reboot later. User ones, just restart or logout/login. It all depends on what is running and the impact.

You did not specify your use-case, so hcvv thorough explanation covers the general case including always-on servers.

For the single-user desktop daily boot/shutdown use case, it can be quite simple. As hcvv said it’s not a big deal, but you can choose one of two moments to update:

  1. At the start of the day, download and apply updates. Catch up with openSUSE news while it update, then reboot. See if everything is fine then go on with your day. Best when you have those minutes to spare.
  2. At the end of the day, download and apply updates. Shutdown. Next day just boot normally, rolling back to a previous snapshot as necessary.

I usually reboot after a Tumbleweed update.

Note, however, that I may delay updating until it is a convenient time for rebooting.

Thanks for the advice. What I failed to include is that I am just a home desktop user; surfing, email and creating documents. When I posted originally, I had completed an update with 173 files. There were dozens of processes listed in zypper ps -s. Taking the easiest route first, I logged out and back in. This time zypper ps -s showed no processes. I almost never do a log in/out. A recent update must have brought a new screen to the login/out procedure. So, I saw something new!

Next, I ran zypper dup again, moments ago, and got 22 updates. Zypper ps -s showed many processes. Once again, I did a login/out procedure and ran zypper ps -s. This time, NetworkManager remained as the only item listed. I will ignore that, as mentioned by some, until a problem arises. That may happen soon. Like others in the forum, Network Manager has been behaving oddly for me recently; connecting and disconnecting from wifi randomly. But, since I am posting right now, it is working “good enough.”

In future, I will use the recommendations you all have posted.