[Bug 2068543] Re: Config variable $nrconf{restart} is no longer accurate: it always restarts

Launchpad Bug Tracker 2068543 at bugs.launchpad.net
Fri Jun 14 17:23:36 UTC 2024


This bug was fixed in the package needrestart - 3.6-8ubuntu3

---------------
needrestart (3.6-8ubuntu3) oracular; urgency=medium

  * d/p/ubuntu-mode.patch: Don't touch /run/reboot-required on kernel updates
    (LP: #2065863)
  * Ubuntu mode: disable it if restart mode has been explicitly set
    (LP: #2068543)
  * Add some inline documentation for the Ubuntu mode (LP: #2068573)
  * Don't restart the google-guest-agent service (LP: #2063442)
  * Don't restart the GH runner provisioner (LP: #2067800)
  * tests: guard against looping when failing.

 -- Simon Chopin <schopin at ubuntu.com>  Fri, 14 Jun 2024 11:57:11 +0200

** Changed in: needrestart (Ubuntu Oracular)
       Status: Fix Committed => Fix Released

-- 
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to needrestart in Ubuntu.
https://bugs.launchpad.net/bugs/2068543

Title:
  Config variable $nrconf{restart} is no longer accurate: it always
  restarts

Status in needrestart package in Ubuntu:
  Fix Released
Status in needrestart source package in Noble:
  New
Status in needrestart source package in Oracular:
  Fix Released

Bug description:
  [Impact]
  The normal configuration knob to change the behaviour of needrestart wrt restarting services vs asking the user vs just listing them doesn't work anymore
  on Noble due to the "Ubuntu mode" changes made during that cycle.

  [Test plan]

  echo '$nrconf{restart} = "l";' > /etc/needrestart/conf.d/listmode.conf
  apt reinstall libc6
  # The previous command should not have restarted any service.

  [ Where problems could occur ]

  If the patch is buggy, automatic restart could be disabled for all
  users. However, that use case is checked by the autopkgtests.

  [Original report]
  On Ubuntu 24.04:

  The conf /etc/needrestart/needrestart.conf contains:

  # Restart mode: (l)ist only, (i)nteractive or (a)utomatically.
  #
  # ATTENTION: If needrestart is configured to run in interactive mode but is run
  # non-interactive (i.e. unattended-upgrades) it will fallback to list only mode.
  #
  #$nrconf{restart} = 'i';

  Whether that variable is left at default (commented out) or defined
  with 'l' or 'i', services are still restarted.

  This config variable conflicts with the new behavior in [1].

  To reproduce: set "$nrconf{restart} = 'l'" run 'apt reinstall
  libssl3t64' on servers with Nginx, Redis, etc.

  Not sure if this setting should be respected, changed, or removed.

  [1] https://discourse.ubuntu.com/t/needrestart-changes-in-
  ubuntu-24-04-service-restarts/44671

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/needrestart/+bug/2068543/+subscriptions




More information about the foundations-bugs mailing list