ddclient / ddclient

Ddclient updates dynamic DNS entries for accounts on a wide range of dynamic DNS services.

Home Page:https://ddclient.net

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Using retry=yes results in a silent failure

f1sherman opened this issue · comments

I'm on version 3.11.2.

I'm using the command ddclient -daemon=0 -verbose -noquiet for testing.

My /etc/ddclient/ddclient.conf:

daemon=5m
mail-failure=root
ssl=yes
pid=/var/run/ddclient.pid
usev4=webv4
webv4=ipify-ipv4
protocol=cloudflare
login=token
zone=<REDACTED>
password=<REDACTED>
<REDACTED>

All works fine unless I add retry=yes to the config. If I do that and run the command above, I get no output and an exit code of 1.

If I'm reading the code correctly, the --retry option does not do what --help says it does. It does not cause ddclient to automatically retry failed updates; instead, it causes ddclient to forever ignore any hosts whose cache status was "good" (successfully updated) when ddclient started. If all hosts were marked as "good", then there are no hosts to update so ddclient exits with a non-zero exit code. It should log a warning ("no hosts to update") in this case, but a bug in the warning line prevents it from outputting anything.

It looks like the --retry option is not intended to be used with --daemon; instead, it is used to initiate an immediate one-time update attempt for each previously failed update.