Re: tinydns to nsd
Andreas Schwarz via nsd-users <[email protected]> Sat, 28 Dec 2019 22:39:05 +0100
| Newsgroups | gmane.network.dns.nsd.general |
|---|---|
| Message-ID | <[email protected]> |
--===============4514786597249704547==
Content-Type: multipart/alternative; boundary="----NX771G0S59MWJHRVV0EQ8ZC2NILQVG"
Content-Transfer-Encoding: 7bit
------NX771G0S59MWJHRVV0EQ8ZC2NILQVG
Content-Type: text/plain;
charset=utf-8
Content-Transfer-Encoding: quoted-printable
On the "nsd-control addzone/delzone": it works a bit different from definin=
g zones in your configuration, just as the error message says=2E
It is rather intended to be used with patterns=2E You configure a pattern =
in your configuration, then you tell nsd via nsd-control addzone to use a s=
pecific pattern for a specific zone=2E nsd keeps track of these assignments=
in a file usually in "/var/lib/nsd/zone=2Elist" (configurable via "zonelis=
tfile")=2E
Zones can be added/removed pretty dynamically that way=2E What nsd does in=
ternally when receiving the addzone/delzone I haven't cared about so far=2E
On the config in general:
"server-count" should be set to the number of CPUs of the respective machi=
ne=2E And, if you have this set to more than 1 and run it on Linux, you mig=
ht also want to consider setting "reuseport" to "yes"=2E I have more experi=
ence with this option from a high performance unbound system, but activatin=
g this option helped improve performance by a margin of 30-40%=2E I think i=
t has a similar impact on nsd when a high amount of requests has to be serv=
ed=2E
Am 28=2E Dezember 2019 22:15:54 MEZ schrieb richard lucassen via nsd-users=
<nsd-users@lists=2Enlnetlabs=2Enl>:
>On Sat, 28 Dec 2019 17:02:09 +0100
>richard lucassen via nsd-users <nsd-users@lists=2Enlnetlabs=2Enl> wrote:
>
>> The problem is (was) that I used "include:" statements in nsd=2Econf
>> to load zone information=2E Apparently nsd does not reread the include
>> files upon a SIGHUP=2E I scripted everything into 1 file and a HUP
>> rereads the zone info now=2E
>
>Wrong, I made a mistake it does not=2E A SIGHUP does not make nsd reread
>it's config file=2E When using nsd-control I get an error:
>
># nsd-control delzone test=2Exaq=2Enl
>error zone defined in nsd=2Econf, cannot delete it in this manner: remove
>it from nsd=2Econf yourself and repattern
>
>The output of "nsd-checkconf -v /etc/nsd/nsd=2Econf":
>server:
> debug-mode: no
> ip-transparent: no
> ip-freebind: no
> reuseport: no
> do-ip4: yes
> do-ip6: no
> hide-version: yes
> database: ""
> #identity:
> #version:
> #nsid:
> #logfile:
> server-count: 1
> tcp-count: 100
> tcp-query-count: 0
> tcp-timeout: 120
> tcp-mss: 0
> outgoing-tcp-mss: 0
> ipv4-edns-size: 4096
> ipv6-edns-size: 4096
> pidfile: "/var/lib/nsd/nsd=2Epid"
> port: "53"
> statistics: 0
> chroot: "/var/lib/nsd/"
> username: "nsd"
> zonesdir: "/var/lib/nsd/domains/"
> xfrdfile: ""
> zonelistfile: "/var/lib/nsd/zone=2Elist"
> xfrdir: "/var/lib/nsd/tmp/"
> xfrd-reload-timeout: 1
> log-time-ascii: yes
> round-robin: yes
> verbosity: 0
> ip-address: "127=2E0=2E0=2E53"
> rrl-size: 1000000
> rrl-ratelimit: 200
> rrl-slip: 2
> rrl-ipv4-prefix-length: 24
> rrl-ipv6-prefix-length: 64
> rrl-whitelist-ratelimit: 2000
> zonefiles-check: yes
> zonefiles-write: 3600
>
>remote-control:
> control-enable: yes
> control-port: 8952
> server-key-file: "/etc/nsd/nsd_server=2Ekey"
> server-cert-file: "/etc/nsd/nsd_server=2Epem"
> control-key-file: "/etc/nsd/nsd_control=2Ekey"
> control-cert-file: "/etc/nsd/nsd_control=2Epem"
>
>zone:
> name: test=2Exaq=2Enl
> zonefile: /var/lib/nsd/domains/nl/xaq/test/zone
>
>(and a lot of other zones)
>
>BTW, a "control-enable: no" gives a config error=2E Any hints?
>
>And perhaps some more comments on the config? Note: this is a
>supervised version running under "runit"
>
>R=2E
>
>--=20
>richard lucassen
>http://contact=2Exaq=2Enl/
>
>_______________________________________________
>nsd-users mailing list
>nsd-users@lists=2Enlnetlabs=2Enl
>https://lists=2Enlnetlabs=2Enl/mailman/listinfo/nsd-users
------NX771G0S59MWJHRVV0EQ8ZC2NILQVG
Content-Type: text/html;
charset=utf-8
Content-Transfer-Encoding: quoted-printable
<html><head></head><body>On the "nsd-control addzone/delzone": it works a b=
it different from defining zones in your configuration, just as the error m=
essage says=2E<br><br>It is rather intended to be used with patterns=2E You=
configure a pattern in your configuration, then you tell nsd via nsd-contr=
ol addzone to use a specific pattern for a specific zone=2E nsd keeps track=
of these assignments in a file usually in "/var/lib/nsd/zone=2Elist" (conf=
igurable via "zonelistfile")=2E<br><br>Zones can be added/removed pretty dy=
namically that way=2E What nsd does internally when receiving the addzone/d=
elzone I haven't cared about so far=2E<br><br>On the config in general:<br>=
"server-count" should be set to the number of CPUs of the respective machin=
e=2E And, if you have this set to more than 1 and run it on Linux, you migh=
t also want to consider setting "reuseport" to "yes"=2E I have more experie=
nce with this option from a high performance unbound system, but activating=
this option helped improve performance by a margin of 30-40%=2E I think it=
has a similar impact on nsd when a high amount of requests has to be serve=
d=2E<br><br><div class=3D"gmail_quote">Am 28=2E Dezember 2019 22:15:54 MEZ =
schrieb richard lucassen via nsd-users <nsd-users@lists=2Enlnetlabs=2Enl=
>:<blockquote class=3D"gmail_quote" style=3D"margin: 0pt 0pt 0pt 0=2E8ex=
; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<pre class=3D"k9mail">On Sat, 28 Dec 2019 17:02:09 +0100<br>richard lucass=
en via nsd-users <nsd-users@lists=2Enlnetlabs=2Enl> wrote:<br><br><bl=
ockquote class=3D"gmail_quote" style=3D"margin: 0pt 0pt 1ex 0=2E8ex; border=
-left: 1px solid #729fcf; padding-left: 1ex;">The problem is (was) that I u=
sed "include:" statements in nsd=2Econf<br>to load zone information=2E Appa=
rently nsd does not reread the include<br>files upon a SIGHUP=2E I scripted=
everything into 1 file and a HUP<br>rereads the zone info now=2E<br></bloc=
kquote><br>Wrong, I made a mistake it does not=2E A SIGHUP does not make ns=
d reread<br>it's config file=2E When using nsd-control I get an error:<br><=
br># nsd-control delzone test=2Exaq=2Enl<br>error zone defined in nsd=2Econ=
f, cannot delete it in this manner: remove<br>it from nsd=2Econf yourself a=
nd repattern<br><br>The output of "nsd-checkconf -v /etc/nsd/nsd=2Econf":<b=
r>server:<br> debug-mode: no<br> ip-transparent: no<br> =
ip-freebind: no<br> reuseport: no<br> do-ip4: yes<br> =
do-ip6: no<br> hide-version: yes<br> database: ""<br> =
#identity:<br> #version:<br> #nsid:<br> #logfile:<br=
> server-count: 1<br> tcp-count: 100<br> tcp-query-cou=
nt: 0<br> tcp-timeout: 120<br> tcp-mss: 0<br> outgoing=
-tcp-mss: 0<br> ipv4-edns-size: 4096<br> ipv6-edns-size: 4096=
<br> pidfile: "/var/lib/nsd/nsd=2Epid"<br> port: "53"<br> =
statistics: 0<br> chroot: "/var/lib/nsd/"<br> username: "=
nsd"<br> zonesdir: "/var/lib/nsd/domains/"<br> xfrdfile: ""<b=
r> zonelistfile: "/var/lib/nsd/zone=2Elist"<br> xfrdir: "/var=
/lib/nsd/tmp/"<br> xfrd-reload-timeout: 1<br> log-time-ascii:=
yes<br> round-robin: yes<br> verbosity: 0<br> ip-addr=
ess: "127=2E0=2E0=2E53"<br> rrl-size: 1000000<br> rrl-ratelim=
it: 200<br> rrl-slip: 2<br> rrl-ipv4-prefix-length: 24<br> =
rrl-ipv6-prefix-length: 64<br> rrl-whitelist-ratelimit: 2000<br=
> zonefiles-check: yes<br> zonefiles-write: 3600<br><br>remot=
e-control:<br> control-enable: yes<br> control-port: 8952<br>=
server-key-file: "/etc/nsd/nsd_server=2Ekey"<br> server-cert=
-file: "/etc/nsd/nsd_server=2Epem"<br> control-key-file: "/etc/nsd/n=
sd_control=2Ekey"<br> control-cert-file: "/etc/nsd/nsd_control=2Epem=
"<br><br>zone:<br> name: test=2Exaq=2Enl<br> zonefile: /var/l=
ib/nsd/domains/nl/xaq/test/zone<br><br>(and a lot of other zones)<br><br>BT=
W, a "control-enable: no" gives a config error=2E Any hints?<br><br>And per=
haps some more comments on the config? Note: this is a<br>supervised versio=
n running under "runit"<br><br>R=2E<br></pre></blockquote></div></body></ht=
ml>
------NX771G0S59MWJHRVV0EQ8ZC2NILQVG--
--===============4514786597249704547==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline
_______________________________________________
nsd-users mailing list
[email protected]
https://lists.nlnetlabs.nl/mailman/listinfo/nsd-users
--===============4514786597249704547==--