On 2015-09-01, Edgar Pettijohn <[email protected]> wrote: > Might need to add the -P flag to specify a different pid. What happens > if you start the second instance with the -d flag?
Currently the rc.d script for NSD starts the program via nsd-control which only offers the -c flag. (otherwise we run into problems with the process name not matching if you restart with nsd-control rather than through rc.d, so the rc script can no longer control it). AFAIK all the command-line flags have alternatives in nsd.conf though (like pidfile, no-inet4, no-inet6, etc). > On 08/31/15 19:04, Gabriel Kuri wrote: >> In migrating from bind to nsd, I currently have split views in bind and >> need to run multiple instances of nsd to accomplish the same thing. What's >> the best way to start multiple instances of nsd? I tried copying >> /etc/rc.d/nsd to /etc/rc.d/nsd-internal and in the rc script I changed >> daemon_flags to "-c /var/nsd/etc/nsd-internal.conf" to reflect the new >> config name, but it doesn't work, that instance of nsd doesn't start and >> there's no errors in /var/log/daemon and I have no idea why it's not >> starting. As Antoine mentioned the problem is the '-'. But I'll add, if this is only for overriding a couple of hosts for users behind your own resolver/s, it may be simpler to use unbound local-data config. (also it's often better to set daemonname_flags in rc.conf.local rather than editing the script itself).

