Bug#1000510: systemd: all server programs fail when they are set to specified interfaces

westlake westlake2012 at videotron.ca
Wed Nov 24 12:19:42 GMT 2021


Package: systemd
Version: 247.3-6
Severity: important

systemd-networkd causes issues around services that do not have 
"network-online.target" as part of "Wanted=" in their unit file.

For example,
apache2.service has the following under their [Unit] in apache2.service,

"After=network.target remote-fs.target nss-lookup.target"
, this is invalid, as it should rather be::
"After=network.target network-online.target remote-fs.target 
nss-lookup.target"

same goes for ssh.service
"After=network.target auditd.service",
should be
"After=network.target network-online.target auditd.service"

and for any other service omitting network-online.target..

. otherwise those services will say "fail" on boot-up.. without any 
other further detail.

journactl -xe -u doesn't show any further detail other that the service 
failed to "bind" to an address.

^ The ssh service I have set is set to bind to a "specific" interface 
that is defined by systemd-networkd's settings in /etc/systemd/network.
(networkctl was shows fully configured interfaces, so there is no issue 
happening over here)

The apache2 service is also set to bind to a "specific" interface.

^ By default these services run on 0.0.0.0 -- to run on all interfacaes, 
including 127.0.0.1 << which is pretty much ready much earlier. This 
explains as to why there is failure when the user defines specified 
interfaces later on.

..  whoever is in charge of systemd, should inform other server-package 
maintainers to add "network-online.target" as a dependency-check 
otherwise those services will fail to start when the user decides to use 
specific interfaces.


thanks



More information about the Pkg-systemd-maintainers mailing list