On 2019-07-18 16:50:20 +0200, Michael Biebl wrote:
> My idea was, to avoid unnecessary daemon-reloads as much as possible.
> 
> If your use case is, that at some point in the future, the user might
> (re)start the service, then it is sufficient if we do a single
> daemon-reload after the dpkg run.
> 
> Let's say we have 10 packages using "--no-start
> --no-restart-after-upgrade", then a single daemon-reload at the end
> would be sufficient instead of having to directly call daemon-reload
> from postinst.
> 
> On the other hand, having a dpkg file-trigger for /lib/system/system
> would mean we trigger daemon-reload at least twice for the common case
> (one via postinst and one via file trigger).

In any case, reloading daemons during the upgrade process is current
buggy as this can yield a race for the dpkg frontend lock:

  https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1070027

Depending on which gets the lock first:
  * This can make (at least) aptitude fail, leaving the system
    in an inconsistent state.
  * This can make the apt.systemd.daily script fail.

-- 
Vincent Lefèvre <[email protected]> - Web: <https://www.vinc17.net/>
100% accessible validated (X)HTML - Blog: <https://www.vinc17.net/blog/>
Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)

Reply via email to