Re: Is NetworkManager-wait-online.service necessary by default?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Di, 22.02.22 09:38, Chris Murphy (lists@xxxxxxxxxxxxxxxxx) wrote:

> Do any of Fedora desktop spins and Workstation edition need
> NetworkManager-wait-online.service enabled by default?
>
> Fedora 35 Workstation (updated, default "preset-all" service units)
> $ systemd-analyze
> Startup finished in 1.330s (kernel) + 1.284s (initrd) + 12.256s
> (userspace) = 14.871s
> graphical.target reached after 12.232s in userspace
>
> Fedora 35 Workstation, same as above except
> NetworkManager-wait-online.service is disabled
> $ systemd-analyze
> Startup finished in 1.294s (kernel) + 1.243s (initrd) + 5.704s
> (userspace) = 8.242s
> graphical.target reached after 5.670s in userspace
>
> 6.6s longer to wait for what? Is this service enabled just in case
> someone adds an NFS or Samba mount to fstab? I'm not sure why this
> service unit is enabled by default; and if we can either go without it
> on the desktop, or if there's some other way to make it better,
> because nearly doubling the boot time doesn't seem reasonable.

The idea is that it is only pulled into the bootup transaction if
something needs it. Typically that's stuff like NFS/SMB mounts listed
in /etc/fstab or so.

Note that the fact that the unit is enabled, doesn't mean it's
automatically in the boot transaction! That's because it (correctly)
hooks itself into network-online.target (rather than multi-user.target
or so) — and that target is only pulled in when something actually
needs it.

LTDR: figure our which service pulls in network-online.target for
you. A command like this should work:

    systemctl show -p WantedBy,RequiredBy network-online.target

Summary: NM-w-o.s being enabled is not a bug, if you use NM for
         network management.

         And: NM-w-o.s actually being pulled in *is* a bug, unless you
         have something like configured NFS/SMB mounts in /etc/fstab,
         that really cannot work without the network actually being
         up. There might be other valid candidates for this,
         i.e. other network client stuff that is really important for
         the boot to be up.

Lennart

--
Lennart Poettering, Berlin
_______________________________________________
devel mailing list -- devel@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to devel-leave@xxxxxxxxxxxxxxxxxxxxxxx
Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: https://lists.fedoraproject.org/archives/list/devel@xxxxxxxxxxxxxxxxxxxxxxx
Do not reply to spam on the list, report it: https://pagure.io/fedora-infrastructure




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Fedora Announce]     [Fedora Users]     [Fedora Kernel]     [Fedora Testing]     [Fedora Formulas]     [Fedora PHP Devel]     [Kernel Development]     [Fedora Legacy]     [Fedora Maintainers]     [Fedora Desktop]     [PAM]     [Red Hat Development]     [Gimp]     [Yosemite News]

  Powered by Linux