Bryan Duff
2010-Jun-10 23:52 UTC
[nsd-users] changing zones in the nsd.conf and 'nsdc reload'
If I add or rename a zone, 'nsdc rebuild; nsdc reload' does not work (me adding zone 'test2.com': //start snip nsd # nsdc rebuild zonec: reading zone "test.com". zonec: processed 5 RRs in "test.com". zonec: reading zone "test2.com". zonec: processed 5 RRs in "test2.com". zonec: done with 0 errors. nsd # nsdc reload [1276213295] nsd[24483]: warning: signal received, reloading... [1276213295] nsd[15882]: error: cannot load database. Zone test2.com. in db /var/db/nsd/nsd.db, but not in config file (might happen if you edited the config file). Please rebuild database and start again. [1276213295] nsd[15882]: error: unable to reload the database: Interrupted system call [1276213295] nsd[24483]: error: handle_reload_cmd: reload closed cmd channel [1276213295] nsd[24483]: warning: Reload process 15882 failed with status 256, continuing with old database //end snip Shucks.>From the README://start snip To restart the daemon (should never be necessary, unless you do some development work) nsdc restart //end snip Needless to say, I disagree with the README file; only 'nsdc restart' seems to fix that little problem. Only then does test2.com return answers (via drill). Looking at the code this seems to make sense. 'killall -SIGHUP nsd' appears to only reload the db, but not re-read the config file (nsd.conf). -Bryan
Jaap Akkerhuis
2010-Jun-11 07:33 UTC
[nsd-users] changing zones in the nsd.conf and 'nsdc reload'
Looking at the code this seems to make sense. 'killall -SIGHUP nsd' appears to only reload the db, but not re-read the config file (nsd.conf). Yes, that is also what the manual page says: reload: Initiate nsd(8) name space database reload by sending SIGHUP. There is no way to reconfigure nsd on the fly. jaap