OK, I can't be the only one that wants to be able to set daemon=0 in the conf file. I searched the forum real quick and didn't see this issue in the archives. As it stands now, if you set daemon=0 in the conf file, it gets set to the minimum value (60). If you don't set it in the conf file or do set it on the command line, you can force it to be 0. Here is the patch I did to make it work. Essentially, when checking the sanity of the conf file, it will allow daemon to remain at 0 if set to 0, otherwise it will behave as before:
--- ddclient.orig 2005-01-16 15:18:36.485003496 -0500
+++ ddclient 2005-01-16 15:19:15.628052848 -0500
@@ -924,6 +924,12 @@
my $def = $variables{'merged'}{$k};
my $ovalue = define($globals{$k}, $def->{'default'});
my $value = check_value($ovalue, $def);
+
+ # we should really be allowed to set daemon to 0 in the config file
+ if ($k eq 'daemon' && $ovalue == 0) {
+ $value = $ovalue;
+ }
+
if ($def->{'required'} && !defined $value) {
$value = default($k);
warning("'%s=%s' is an invalid %s. (using default of %s)", $k, $ovalue, $def->{'type'}, $value);
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I'm afraid you're the only one. :-) The deamon mode is pretty cool: you start ddclient and your dyndns-setting stay up to date...
But anyway, thanks for the patch.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I admit the daemon mode is pretty cool. What I like better is the ability to only run when my DHCP client changes state. And even then, it only calls it when the IP address has changed. The nice thing is I don't have to set a short sleep state, the update is instantaneous. Combined with reasonably short TTL values, I'm never on the wrong IP for more than a minute. Plus, one less running process to worry about! :) Thanks, and the patch wasn't too hard once I figured out what was going on.
- hoffer
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
OK, I can't be the only one that wants to be able to set daemon=0 in the conf file. I searched the forum real quick and didn't see this issue in the archives. As it stands now, if you set daemon=0 in the conf file, it gets set to the minimum value (60). If you don't set it in the conf file or do set it on the command line, you can force it to be 0. Here is the patch I did to make it work. Essentially, when checking the sanity of the conf file, it will allow daemon to remain at 0 if set to 0, otherwise it will behave as before:
--- ddclient.orig 2005-01-16 15:18:36.485003496 -0500
+++ ddclient 2005-01-16 15:19:15.628052848 -0500
@@ -924,6 +924,12 @@
my $def = $variables{'merged'}{$k};
my $ovalue = define($globals{$k}, $def->{'default'});
my $value = check_value($ovalue, $def);
+
+ # we should really be allowed to set daemon to 0 in the config file
+ if ($k eq 'daemon' && $ovalue == 0) {
+ $value = $ovalue;
+ }
+
if ($def->{'required'} && !defined $value) {
$value = default($k);
warning("'%s=%s' is an invalid %s. (using default of %s)", $k, $ovalue, $def->{'type'}, $value);
I'm afraid you're the only one. :-) The deamon mode is pretty cool: you start ddclient and your dyndns-setting stay up to date...
But anyway, thanks for the patch.
I admit the daemon mode is pretty cool. What I like better is the ability to only run when my DHCP client changes state. And even then, it only calls it when the IP address has changed. The nice thing is I don't have to set a short sleep state, the update is instantaneous. Combined with reasonably short TTL values, I'm never on the wrong IP for more than a minute. Plus, one less running process to worry about! :) Thanks, and the patch wasn't too hard once I figured out what was going on.
- hoffer