[Samba] winbind: does it actually depend on nmbd? and network-online?

Michael Tokarev mjt at tls.msk.ru
Thu May 2 10:44:47 UTC 2024


Hi!

In packaging/systemd/winbind.service, there's this ordering:

After=network.target nmb.service

Does winbind really need nmbd running?

Another interesting dependency here.  nmb.service (in the same directory) has

Wants=network-online.target
After=network.target network-online.target

Note nmbd needs network to be online.  While winbind only needs
network to be up.  If winbind requires nmbd, who in turn requires
network to be online, winbind will be started only with online
network.  If we drop winbind dependency on nmbd here, winbind will
be started earlier, before network is online.

Does winbind requires network to be online or just up?
I *guess* in order for winbind to be useful, network should be online,
or else it wont be able to resolve names.  On the other hand, it keeps
internal cache so once a user is looked up, winbind can return this
user from the cache without network being up.

FWIW, requiring network.target doesn't really give us much: if it needs
just basic tcp/ip to be able to bind to all-zeros address, loopback iface
is being configured much earlier than any other services.  On the other
hand, if it needs particular interfaces to be up, it should depend on
these interfaces, - after network.target is available, there's no guarantee
that all interfaces are configured.

Thanks,

/mjt

-- 
GPG Key transition (from rsa2048 to rsa4096) since 2024-04-24.
New key: rsa4096/61AD3D98ECDF2C8E  9D8B E14E 3F2A 9DD7 9199  28F1 61AD 3D98 ECDF 2C8E
Old key: rsa2048/457CE0A0804465C5  6EE1 95D1 886E 8FFB 810D  4324 457C E0A0 8044 65C5
Transition statement: http://www.corpit.ru/mjt/gpg-transition-2024.txt



More information about the samba mailing list