From a99741d079bd2eda68035c61987730e61971f955 Mon Sep 17 00:00:00 2001 From: Date Huang Date: Fri, 9 Apr 2021 20:39:34 +0800 Subject: [PATCH] fix start networking.service before network is marked online ifupdown2 didn't ensure that it will start before network.target and network-online.target. after local-fs.target because ifupdown2 need to read config file from local filesystem Other network services will not start after networking.service and fail because no interface is up. (e.g isc-dhcp-server, tftp-hpa) Signed-off-by: Date Huang --- .../systemd/system/networking.service.d/switchdev-online.conf | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/builds/any/rootfs/stretch/common/overlay/etc/systemd/system/networking.service.d/switchdev-online.conf b/builds/any/rootfs/stretch/common/overlay/etc/systemd/system/networking.service.d/switchdev-online.conf index 4e9b7d40d..4bc027c64 100644 --- a/builds/any/rootfs/stretch/common/overlay/etc/systemd/system/networking.service.d/switchdev-online.conf +++ b/builds/any/rootfs/stretch/common/overlay/etc/systemd/system/networking.service.d/switchdev-online.conf @@ -1,2 +1,3 @@ [Unit] -After=network-pre.target +After=local-fs.target network-pre.target +Before=shutdown.target network.target network-online.target