Process "job networkmanager-wait-online.service/start running" takes too long and fails

Hello.
The process “job networkmanager-wait-online.service/start running” takes very long on boot and then fails.
I know the process waits for network and is needed by some services.
Should i disable it? How do i know if i have processes that depend on it? How to fix it?

I’m using Fedora 40 xfce.

Run

systemctl list-dependencies network-online.target

That shows the services which will wait for the network to become online.

As for fixing it, you need to check the journal to see exactly how long NetworkManager takes for the network to become online, and what is holding it up.

systemctl list-dependencies network-online.target

network-online.target
× └─NetworkManager-wait-online.service

journalctl -u NetworkManager-wait-online.service

Nov 14 10:55:06 fedora systemd[1]: Starting NetworkManager-wait-online.service - Network Manager Wait Online…
Nov 14 10:56:06 fedora systemd[1]: NetworkManager-wait-online.service: Main process exited, code=exited, status=1/FAILURE
Nov 14 10:56:06 fedora systemd[1]: NetworkManager-wait-online.service: Failed with result ‘exit-code’.
Nov 14 10:56:06 fedora systemd[1]: Failed to start NetworkManager-wait-online.service - Network Manager Wait Online.

systemd-analyze blame
1min 42ms NetworkManager-wait-online.service

systemctl status NetworkManager-wait-online.service

× NetworkManager-wait-online.service - Network Manager Wait Online
Loaded: loaded (/usr/lib/systemd/system/NetworkManager-wait-online.service; enabled; preset: enabled)
Drop-In: /usr/lib/systemd/system/service.d
└─10-timeout-abort.conf
Active: failed (Result: exit-code) since Thu 2024-11-14 10:56:06 -03; 4h 54min ago
Docs: man:NetworkManager-wait-online.service(8)
Process: 958 ExecStart=/usr/bin/nm-online -s -q (code=exited, status=1/FAILURE)
Main PID: 958 (code=exited, status=1/FAILURE)
CPU: 114ms

Nov 14 10:55:06 fedora systemd[1]: Starting NetworkManager-wait-online.service - Network Manager Wait Online…
Nov 14 10:56:06 fedora systemd[1]: NetworkManager-wait-online.service: Main process exited, code=exited, status=1/FAILURE
Nov 14 10:56:06 fedora systemd[1]: NetworkManager-wait-online.service: Failed with result ‘exit-code’.
Nov 14 10:56:06 fedora systemd[1]: Failed to start NetworkManager-wait-online.service - Network Manager Wait Online.

systemctl status NetworkManager

● NetworkManager.service - Network Manager
Loaded: loaded (/usr/lib/systemd/system/NetworkManager.service; enabled; preset: enabled)
Drop-In: /usr/lib/systemd/system/service.d
└─10-timeout-abort.conf
Active: active (running) since Thu 2024-11-14 10:55:06 -03; 5h 4min ago
Docs: man:NetworkManager(8)
Main PID: 917 (NetworkManager)
Tasks: 4 (limit: 6828)
Memory: 5.7M (peak: 10.4M swap: 1.7M swap peak: 1.9M)
CPU: 14.071s
CGroup: /system.slice/NetworkManager.service
└─917 /usr/sbin/NetworkManager --no-daemon

I don’t know exactly what this means or what to do.
Is it okay if i disable it?

systemctl list-dependencies network-online.target --reverse

That’s possible if you don’t care about the units returned by the provided command.

To actually resolve the issue, make sure NetworkManager can connect at startup when no user is logged in yet.
This may require customizing the connection permissions and the backend used to store secrets such as Wi-Fi PSK.

systemctl list-dependencies network-online.target --reverse
network-online.target
● ├─dnf-makecache.timer
○ ├─iscsi.service
○ ├─nfs-idmapd.service
○ ├─nfs-mountd.service
○ ├─nfs-server.service
● ├─rpc-statd-notify.service
○ └─rpc-statd.service

I don’t actively use any of these. They are not necessary for the system to work normally right?

So i would need to configure that for my wifi network but the slow boot would still persist every time i use a different network? If that’s the case i would prefer to disable it instead of customizing every single different network i use.

1 Like