ifupdown-wait-online.service (even if disabed) / xfce takes 5 mins to load

I’m using Ubuntu 22.04 right now and ifupdown-wait-online.service takes 5 mins to load,as well as xfce. I gave a :

# systemd-analyze blame

and this is the result ; is exactly like I’ve thought :

https://pastebin.ubuntu.com/p/XqMKnqNBjZ

I’ve found a possible resolution of the problem here :

https://bbs.archlinux.org/viewtopic.php?id=256366

This is what I did :

https://pastebin.ubuntu.com/p/yGRSB7WDXZ/

but no,it didn’t work. The ifupdown-wait-online.service still took 5 mins to run :

root@chromarietto:~# systemd-analyze blame

5min 1.101s ifupdown-wait-online.service

I tried another approach,but it didn’t work as well :

root@chromarietto:~# systemctl disable systemd-networkd-wait-online.service
    
Removed /etc/systemd/system/network-online.target.wants/systemd-networkd-wait-online.service.


root@chromarietto:~# systemctl stop systemd-networkd-wait-online.service
    
root@chromarietto:~# reboot

Connection to 192.168.1.6 closed by remote host. Connection to 192.168.1.6 closed.


root@Z390-AORUS-PRO-DEST:/home/ziomario# ssh -Y root@192.168.1.6
    
root@192.168.1.6's password:

"System is booting up. Unprivileged users are not permitted to log in yet. Please come back later. For technical details, see pam_nologin(8)." Warning: No xauth data; using fake authentication data for X11 forwarding.

"System is booting up. Unprivileged users are not permitted to log in yet. Please come back later. For technical details, see pam_nologin(8)."

Welcome to Ubuntu 22.04.3 LTS (GNU/Linux 5.4.244 armv7l)

    Documentation: https://help.ubuntu.com

    Management: https://landscape.canonical.com

    Support: https://ubuntu.com/advantage

Expanded Security Maintenance for Applications is not enabled.

0 updates can be applied immediately.

Enable ESM Apps to receive additional future security updates. See https://ubuntu.com/esm or run: sudo pro status

Last login: Tue Sep 12 12:14:55 2023 from 192.168.1.2


root@chromarietto:~# systemd-analyze blame

Bootup is not yet finished (org.freedesktop.systemd1.Manager.FinishTimestampMonotonic=0).

Please try again later.

Hint: Use 'systemctl list-jobs' to see active jobs


root@chromarietto:~# systemctl list-jobs

No jobs running.

UPDATE :

An ubuntu developer explained that :

ifupdown has been deprecated a long time ago in favour of
systemd-networkd/netplan in ubuntu, IIRC even debian has dropped it so
its integration with systemd might be lacking a lot …

ok,but I still don’t know how to fix this problem. He has been a little bit vague.

Asked By: Marietto

||

The solution is to disable the ifupdown-wait-online.service (not systemd-networkd-wait-online.service)

sudo systemctl disable ifupdown-wait-online.service
Answered By: Archisman Panigrahi