timesyncd manager_connect exhaust server and add unneeded delay
(too old to reply)
Belisko Marek
2021-03-19 13:57:21 UTC

I'm using a bit older systemd 234 and debugging issues when on
connection lost/recover timesyncd wait some until it makes actual
server connection again.

My theory: When connection is established
manager_network_event_handler is called and check online/connected. In
case of unplug cable it's online but not connected and it call
manager_connect which then fails to resolve an server addresses (IMO
connection was reported fine by resolver is not yet ready( and in this
case all ntp addresses fails and I'm getting message:
log_info("Waiting after exhausting servers."); which is 64secs , then
continue with *2 wait timeouts. I'm using systemd-networkd for network
connection. I'm not sure if such an issue was reported (maybe this
one: https://github.com/systemd/systemd/issues/16529).

To avoid adding extra timeout waiting for ntp option would be to try
to resolve server before (if online) and if it fails just wait and
retry or so? Any idea if it's fixed in newer version of systemd?

Thanks and BR,

as simple and primitive as possible
Marek Belisko - OPEN-NANDRA
Freelance Developer

Ruska Nova Ves 219 | Presov, 08005 Slovak Republic
Tel: +421 915 052 184
skype: marekwhite
twitter: #opennandra
web: http://open-nandra.com