BIND client log error "query_find: query_getdb failed"
If you see an error message like this one in the BIND DNS server's client log, it may be harmless:
24-May-2019 21:00:05.019 client: error: (example.com/A): query_find: query_getdb failed
I couldn't find anything explaining the error (hence this post) so I looked at the source; this message comes from query.c. What's happening here is that BIND is trying to figure out which zone contains the answer it needs, but it can't find the zone, so
query_getdb failed is logged and a
SERVFAIL response is sent to the client.
As it turns out, the timing of this error in the log coincides exactly with the BIND service being restarted. In this case I had just upgraded a server from 9.11.6-P1 to 9.11.7 and bounced the service. At the precise moment the logged query arrived, BIND hadn't loaded that zone yet, so of course it couldn't be located in memory. The zone in question was loaded a few millis later:
24-May-2019 21:00:05.026 general: info: zone example.com/IN (signed): loaded serial 2019021705 (DNSSEC signed)
..after which, no subsequent
query_getdb failed errors were logged.