cloudfoundry / bosh-dns-release

BOSH DNS release
Apache License 2.0
18 stars 36 forks source link

Log failed recurser requests at Error level #61

Closed beyhan closed 4 years ago

beyhan commented 4 years ago

Current version of bosh-dns requires DEBUG level for recursor errors. It is not easy to reproduce recursor errors and DEBUG level is too noisy as production configuration. That is why it will be better to log recursor failures at ERROR level. This change will log all recursor errors at ERROR level beside the "NXDOMAIN" errror, which I think is easy for debugging and could be too noise.

To test the new log level execute following commands on a BOSH VM, where bosh-dns is running:

iptables -A INPUT -p udp -s <recursor-ip> -j DROP
iptables -A INPUT -p tcp -s <recursor-ip> -j DROP

nslookup <public-domain>

# in ==> bosh_dns.stdout.log <==
[ForwardHandler] 2020/05/07 16:45:49 ERROR - error recursing for <public-domain>. to "<recursor-ip>:53": read udp <instance-ip>:33697-><recursor-ip>:53: i/o timeout

fixises #60

cf-gitbot commented 4 years ago

We have created an issue in Pivotal Tracker to manage this:

https://www.pivotaltracker.com/story/show/173074645

The labels on this github issue will be updated when the story is started.