Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Seperate options for provide_xfr and notify #18

Open
htj opened this issue Jan 28, 2020 · 3 comments
Open

Seperate options for provide_xfr and notify #18

htj opened this issue Jan 28, 2020 · 3 comments

Comments

@htj
Copy link

htj commented Jan 28, 2020

Hi

I have a case where I need to provide XFR to two IPs, but only notify one of them.

It has to do with an multi homed host with an anycast address. This config is perfectly in the nsd.conf file, but not currently possible with the puppet-nsd module, as the list of provide_xfrs is also used for the notify list.

@b4ldr
Copy link
Contributor

b4ldr commented Jan 29, 2020

@htj Im curious if this actually causes an issue in your config? Anyway that aside you can abuse the fact that if you provide a prefix as the remote then the notify is not configured e.g.

nsd::remotes:
  slave_notify:
    address4: 192.0.2.1
    address6: 2001:db8::1
  slave_no_notify: 
    address4: 192.0.2.2/32
    address6: 2001:db8::2/128
  lax.xfr.dns.icann.org:
    address4: 192.0.32.132
  iad.xfr.dns.icann.org:
    address4: 192.0.32.132
nsd::default_masters:
  -  lax.xfr.dns.icann.org
  -  iad.xfr.dns.icann.org
nsd::default_provide_xfrs:
  - slave_notify
  - slave_no_notify
nsd::zones:
  example.org: {}

@htj
Copy link
Author

htj commented Jan 31, 2020

Hi

So things do work, but I get these in the log (IP/zone name been changed):

xfrd: zone example.net: max notify send count reached, 10.0.0.70 unreachable
Jan 31 12:32:41 ns-master nsd[16029]: [2020-01-31 12:32:41.700] nsd[16029]: error: xfrd: zone example.net: max notify send count reached, 10.0.0.70 unreachable

And similar for v6. And I get these for each zone reload.

in nsd.conf I end up with something like this:

pattern:
name: ns1_service-provide-xfr
notify: 10.0.6.161 NOKEY
provide-xfr: 10.0.6.161 NOKEY

pattern:
name: ns1_vm-provide-xfr
notify: 10.0.0.70 NOKEY
provide-xfr: 10.0.0.70 NOKEY

zone:
name: "example.net"
zonefile: "/var/lib/nsd/zone/example.net"
include-pattern: ns1_service-provide-xfr
include-pattern: ns1_vm-provide-xfr

The 10.0.6.161 and 10.0.0.70 IPs are on the same host, with the first being anycasted. There is an underlying problem in NSD with notifications not being send from the interface the service is bound, that forces me into this slightly weird setup.

While stuff works, I'm not a fan of not being able to configure the service so that there are no errors in the log.

I got the / thing to work. It is not what I would call an obvious design though. I'd much prefer explicit provide and notify keys.

@b4ldr
Copy link
Contributor

b4ldr commented Jan 31, 2020

I got the / thing to work. It is not what I would call an obvious design though. I'd much prefer explicit provide and notify keys.

Im sure the project would be more then happy to receive a pull request

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants