Dracut NM module

Andrei Borzenkov arvidjaar at gmail.com
Mon Sep 16 14:36:24 UTC 2024


On Mon, Sep 16, 2024 at 4:43 PM Thomas HUMMEL <thomas.hummel at pasteur.fr> wrote:
>
> On 9/16/24 3:24 PM, Andrei Borzenkov wrote:
> > On Mon, Sep 16, 2024 at 3:48 PM Thomas HUMMEL <thomas.hummel at pasteur.fr> wrote:
>
> Thanks for your reply.
>
>
> > Normally modules that need networking are supposed to depend on the
> > network which will pick up the backend in order of preference (it will
> > prefer NetwoekManager if available). If you explicitly added a
> > networking backend already, the network module will respect it.
>
> You mean - that's what I saw at least - passing a "handler" to the
> network module + interfaces as arguments so the network module is
> somewhat a generic hook ?
>

I am afraid I don't quite understand what you mean. dracut module can
depend on other dracut modules. Dracut network module will
conditionally add network-manager module (or systemd-netword or
connman) to initrd.

> Is this order of preference expressed in a config somewhere ?
>

No, it is hardcoded in the network module.

>
> > Generated connection profiles are stored in /run and so should survive
> > switching to the real root.
>
> Ok.
>
> And in the case of dracut with legacy module, one switched to the new
> root, NM would I guess still consider the connection as externally
> managed (assuming no one manipulate it with NM afterwards), correct ?
>

That is what I expect. IIRC NetworkManager will compare the current
settings with connection profiles and if some will match implicitly
consider device activated using this profile.


More information about the Networkmanager mailing list