Bug#790262: systemd: warns that service changes on disk instead of just reloading
Felipe Sateler
fsateler at debian.org
Sat Jun 27 20:56:03 BST 2015
Control: tags -1 wontfix
Control: severity -1 wishlist
On 27 June 2015 at 16:15, brian m. carlson <sandals at crustytoothpaste.net> wrote:
> Package: systemd
> Version: 220-7
> Severity: normal
>
> If I edit a file on disk, and then attempt to use service to restart it,
> systemd warns but does not reload the file:
>
> castro ok % sudo service krb5-kdc restart
> Warning: krb5-kdc.service changed on disk. Run 'systemctl daemon-reload' to reload units.
> ^C%
>
> When I invoked service, I expected systemd to just reload the unit
> instead of warning me that it had changed. After all, I wouldn't have
> edited the file unless I wanted systemd to do something different with
> the service. systemd should just reload the file (or files)
> automatically, since that's what the user expects to happen; the
> behavior is also consistent with sysvinit.
Systemd upstream has been quite clear that they do not want
autoreloads[1]. You may want to ask the sysvinit-utils maintainers to
trigger a daemon-reload when you invoke service, but I'm not convinced
it is a good idea. The problem is that systemd has to look at the
whole conf tree (/etc/systemd and /lib/systemd), so the fact that one
file changed tells it nothing about whether the resulting
configuration is OK.
You may want to use systemctl edit, which triggers a unit reload after it exits.
[1] eg at https://bugzilla.redhat.com/show_bug.cgi?id=615527
--
Saludos,
Felipe Sateler
More information about the Pkg-systemd-maintainers
mailing list