BIND issueshttps://gitlab.isc.org/isc-projects/bind9/-/issues2021-06-09T20:25:04Zhttps://gitlab.isc.org/isc-projects/bind9/-/issues/2647named crash in interfacemgr.c if killed while creating interfaces2021-06-09T20:25:04ZOndřej Surýnamed crash in interfacemgr.c if killed while creating interfacesAnd if you wait a bit more longer and press Ctrl-C:
```
^C21-Apr-2021 20:49:34.063 listening on IPv4 interface lo, 10.53.2.2#12345
21-Apr-2021 20:49:34.063 ns_clientmgr_create() failed: not found
21-Apr-2021 20:49:34.063 creating IPv4 in...And if you wait a bit more longer and press Ctrl-C:
```
^C21-Apr-2021 20:49:34.063 listening on IPv4 interface lo, 10.53.2.2#12345
21-Apr-2021 20:49:34.063 ns_clientmgr_create() failed: not found
21-Apr-2021 20:49:34.063 creating IPv4 interface lo failed; interface ignored
21-Apr-2021 20:49:34.079 listening on IPv4 interface eno1, 10.10.10.20#12345
21-Apr-2021 20:49:34.079 ns_clientmgr_create() failed: not found
21-Apr-2021 20:49:34.079 creating IPv4 interface eno1 failed; interface ignored
21-Apr-2021 20:49:34.079 listening on IPv4 interface docker0, 172.17.0.1#12345
21-Apr-2021 20:49:34.079 ns_clientmgr_create() failed: not found
21-Apr-2021 20:49:34.079 creating IPv4 interface docker0 failed; interface ignored
21-Apr-2021 20:49:34.079 IPv6 socket API is incomplete; explicitly binding to each IPv6 address separately
21-Apr-2021 20:49:34.079 listening on IPv6 interface lo, fd92:7065:b8e:ff::2#12345
21-Apr-2021 20:49:34.079 ns_clientmgr_create() failed: not found
21-Apr-2021 20:49:34.079 creating IPv6 interface lo failed; interface ignored
21-Apr-2021 20:49:34.083 listening on IPv6 interface lo, fd92:7065:b8e:ff::1#12345
21-Apr-2021 20:49:34.083 ns_clientmgr_create() failed: not found
21-Apr-2021 20:49:34.083 creating IPv6 interface lo failed; interface ignored
21-Apr-2021 20:49:34.083 listening on IPv6 interface lo, fd92:7065:b8e:99ff::2#12345
21-Apr-2021 20:49:34.083 ns_clientmgr_create() failed: not found
21-Apr-2021 20:49:34.083 creating IPv6 interface lo failed; interface ignored
21-Apr-2021 20:49:34.083 listening on IPv6 interface lo, fd92:7065:b8e:99ff::1#12345
21-Apr-2021 20:49:34.083 ns_clientmgr_create() failed: not found
21-Apr-2021 20:49:34.087 creating IPv6 interface lo failed; interface ignored
21-Apr-2021 20:49:34.087 listening on IPv6 interface lo, fd92:7065:b8e:ffff::10#12345
21-Apr-2021 20:49:34.087 ns_clientmgr_create() failed: not found
21-Apr-2021 20:49:34.087 creating IPv6 interface lo failed; interface ignored
21-Apr-2021 20:49:34.087 listening on IPv6 interface lo, fd92:7065:b8e:ffff::9#12345
21-Apr-2021 20:49:34.087 ns_clientmgr_create() failed: not found
21-Apr-2021 20:49:34.087 creating IPv6 interface lo failed; interface ignored
21-Apr-2021 20:49:34.087 listening on IPv6 interface lo, fd92:7065:b8e:ffff::8#12345
21-Apr-2021 20:49:34.087 ns_clientmgr_create() failed: not found
21-Apr-2021 20:49:34.087 creating IPv6 interface lo failed; interface ignored
21-Apr-2021 20:49:34.087 listening on IPv6 interface lo, fd92:7065:b8e:ffff::7#12345
21-Apr-2021 20:49:34.087 ns_clientmgr_create() failed: not found
21-Apr-2021 20:49:34.087 creating IPv6 interface lo failed; interface ignored
21-Apr-2021 20:49:34.087 listening on IPv6 interface lo, fd92:7065:b8e:ffff::6#12345
21-Apr-2021 20:49:34.087 ns_clientmgr_create() failed: not found
21-Apr-2021 20:49:34.087 creating IPv6 interface lo failed; interface ignored
21-Apr-2021 20:49:34.087 listening on IPv6 interface lo, fd92:7065:b8e:ffff::5#12345
21-Apr-2021 20:49:34.087 ns_clientmgr_create() failed: not found
21-Apr-2021 20:49:34.087 creating IPv6 interface lo failed; interface ignored
21-Apr-2021 20:49:34.087 listening on IPv6 interface lo, fd92:7065:b8e:ffff::4#12345
21-Apr-2021 20:49:34.087 ns_clientmgr_create() failed: not found
21-Apr-2021 20:49:34.087 creating IPv6 interface lo failed; interface ignored
21-Apr-2021 20:49:34.087 listening on IPv6 interface lo, fd92:7065:b8e:ffff::3#12345
21-Apr-2021 20:49:34.087 ns_clientmgr_create() failed: not found
21-Apr-2021 20:49:34.087 creating IPv6 interface lo failed; interface ignored
21-Apr-2021 20:49:34.087 listening on IPv6 interface lo, fd92:7065:b8e:ffff::2#12345
21-Apr-2021 20:49:34.087 ns_clientmgr_create() failed: not found
21-Apr-2021 20:49:34.087 creating IPv6 interface lo failed; interface ignored
21-Apr-2021 20:49:34.087 listening on IPv6 interface lo, fd92:7065:b8e:ffff::1#12345
21-Apr-2021 20:49:34.087 ns_clientmgr_create() failed: not found
21-Apr-2021 20:49:34.087 creating IPv6 interface lo failed; interface ignored
21-Apr-2021 20:49:34.087 listening on IPv6 interface lo, ::1#12345
21-Apr-2021 20:49:34.087 ns_clientmgr_create() failed: not found
21-Apr-2021 20:49:34.087 creating IPv6 interface lo failed; interface ignored
21-Apr-2021 20:49:34.087 listening on IPv6 interface eno1, fe80::56b2:3ff:fe08:4718%2#12345
21-Apr-2021 20:49:34.087 ns_clientmgr_create() failed: not found
21-Apr-2021 20:49:34.087 creating IPv6 interface eno1 failed; interface ignored
21-Apr-2021 20:49:34.087 listening on IPv6 interface docker0, 2001:db8:1::1#12345
21-Apr-2021 20:49:34.087 ns_clientmgr_create() failed: not found
21-Apr-2021 20:49:34.087 creating IPv6 interface docker0 failed; interface ignored
21-Apr-2021 20:49:34.087 listening on IPv6 interface docker0, fe80::1%4#12345
21-Apr-2021 20:49:34.087 ns_clientmgr_create() failed: not found
21-Apr-2021 20:49:34.087 creating IPv6 interface docker0 failed; interface ignored
21-Apr-2021 20:49:34.091 interfacemgr.c:768: INSIST((__builtin_expect(!!((ifp) != ((void*)0)), 1) && __builtin_expect(!!(((const isc__magic_t *)(ifp))->magic == ((('I') << 24 | (':') << 16 | ('-') << 8 | (')')))), 1))) failed, back trace
21-Apr-2021 20:49:34.091 /home/ondrej/Projects/bind9/lib/isc/.libs/libisc-9.17.11.so(isc_backtrace_gettrace+0x37) [0x7fb6366e6e87]
21-Apr-2021 20:49:34.091 /home/ondrej/Projects/bind9/bin/named/.libs/named() [0x4dbfdc]
21-Apr-2021 20:49:34.091 /home/ondrej/Projects/bind9/lib/isc/.libs/libisc-9.17.11.so(isc_assertion_failed+0x3e) [0x7fb6366e686e]
21-Apr-2021 20:49:34.091 /home/ondrej/Projects/bind9/lib/ns/.libs/libns-9.17.11.so(+0x187dd) [0x7fb6363857dd]
21-Apr-2021 20:49:34.091 /home/ondrej/Projects/bind9/lib/ns/.libs/libns-9.17.11.so(+0x1a009) [0x7fb636387009]
21-Apr-2021 20:49:34.091 /home/ondrej/Projects/bind9/lib/ns/.libs/libns-9.17.11.so(ns_interfacemgr_scan+0x3f) [0x7fb636385d2f]
21-Apr-2021 20:49:34.091 /home/ondrej/Projects/bind9/bin/named/.libs/named() [0x4eff99]
21-Apr-2021 20:49:34.091 /home/ondrej/Projects/bind9/bin/named/.libs/named() [0x4de290]
21-Apr-2021 20:49:34.091 /home/ondrej/Projects/bind9/lib/isc/.libs/libisc-9.17.11.so(isc_task_run+0x266) [0x7fb6367117c6]
21-Apr-2021 20:49:34.091 /home/ondrej/Projects/bind9/lib/isc/.libs/libisc-9.17.11.so(+0x344ee) [0x7fb6366b44ee]
21-Apr-2021 20:49:34.091 /home/ondrej/Projects/bind9/lib/isc/.libs/libisc-9.17.11.so(+0x2e4e3) [0x7fb6366ae4e3]
21-Apr-2021 20:49:34.091 /home/ondrej/Projects/bind9/lib/isc/.libs/libisc-9.17.11.so(+0x28d28) [0x7fb6366a8d28]
21-Apr-2021 20:49:34.091 /home/ondrej/.tsan/lib/libuv.so.1(+0x1538a) [0x7fb635cd938a]
21-Apr-2021 20:49:34.091 /home/ondrej/.tsan/lib/libuv.so.1(uv__io_poll+0x687) [0x7fb635cf2bb7]
21-Apr-2021 20:49:34.091 /home/ondrej/.tsan/lib/libuv.so.1(uv_run+0xcd) [0x7fb635cd99ad]
21-Apr-2021 20:49:34.091 /home/ondrej/Projects/bind9/lib/isc/.libs/libisc-9.17.11.so(+0x28eae) [0x7fb6366a8eae]
21-Apr-2021 20:49:34.091 /home/ondrej/Projects/bind9/lib/isc/.libs/libisc-9.17.11.so(isc__trampoline_run+0xad) [0x7fb63671715d]
21-Apr-2021 20:49:34.091 /home/ondrej/Projects/bind9/bin/named/.libs/named() [0x43e18d]
21-Apr-2021 20:49:34.091 /lib/x86_64-linux-gnu/libpthread.so.0(+0x8ea7) [0x7fb635a97ea7]
21-Apr-2021 20:49:34.091 /lib/x86_64-linux-gnu/libc.so.6(clone+0x3f) [0x7fb63585ddef]
21-Apr-2021 20:49:34.091 exiting (due to assertion failure)
```May 2021 (9.11.32, 9.11.32-S1, 9.16.16, 9.16.16-S1, 9.17.13)https://gitlab.isc.org/isc-projects/bind9/-/issues/2646named crash in task.c when stopped while creating interfaces2021-06-09T20:24:44ZOndřej Surýnamed crash in task.c when stopped while creating interfacesHow to reproduce:
1. Start named with many threads `-n 64`
2. Press Ctrl-C as soon as it starts
3. Succ^HCrash
```
21-Apr-2021 20:41:40.779 found 8 CPUs, using 64 worker threads
21-Apr-2021 20:41:40.779 using 8 UDP listeners per interf...How to reproduce:
1. Start named with many threads `-n 64`
2. Press Ctrl-C as soon as it starts
3. Succ^HCrash
```
21-Apr-2021 20:41:40.779 found 8 CPUs, using 64 worker threads
21-Apr-2021 20:41:40.779 using 8 UDP listeners per interface
^C21-Apr-2021 20:41:42.171 using up to 21000 sockets
21-Apr-2021 20:41:42.191 task.c:1097: REQUIRE((__builtin_expect(!!((mgr) != ((void*)0)), 1) && __builtin_expect(!!(((const isc__magic_t *)(mgr))->magic == ((('T') << 24 | ('S') << 16 | ('K') << 8 | ('M')))), 1))) failed, back trace
21-Apr-2021 20:41:42.191 /home/ondrej/Projects/bind9/lib/isc/.libs/libisc-9.17.11.so(isc_backtrace_gettrace+0x37) [0x7f4bf36a5e87]
21-Apr-2021 20:41:42.191 /home/ondrej/Projects/bind9/bin/named/.libs/named() [0x4dbfdc]
21-Apr-2021 20:41:42.191 /home/ondrej/Projects/bind9/lib/isc/.libs/libisc-9.17.11.so(isc_assertion_failed+0x3e) [0x7f4bf36a586e]
21-Apr-2021 20:41:42.191 /home/ondrej/Projects/bind9/lib/isc/.libs/libisc-9.17.11.so(isc_taskmgr_excltask+0x117) [0x7f4bf36d1657]
21-Apr-2021 20:41:42.191 /home/ondrej/Projects/bind9/lib/ns/.libs/libns-9.17.11.so(ns_interfacemgr_create+0x122) [0x7f4bf3343922]
21-Apr-2021 20:41:42.191 /home/ondrej/Projects/bind9/bin/named/.libs/named() [0x4de0d6]
21-Apr-2021 20:41:42.191 /home/ondrej/Projects/bind9/lib/isc/.libs/libisc-9.17.11.so(isc_task_run+0x266) [0x7f4bf36d07c6]
21-Apr-2021 20:41:42.191 /home/ondrej/Projects/bind9/lib/isc/.libs/libisc-9.17.11.so(+0x344ee) [0x7f4bf36734ee]
21-Apr-2021 20:41:42.191 /home/ondrej/Projects/bind9/lib/isc/.libs/libisc-9.17.11.so(+0x2e4e3) [0x7f4bf366d4e3]
21-Apr-2021 20:41:42.191 /home/ondrej/Projects/bind9/lib/isc/.libs/libisc-9.17.11.so(+0x28d28) [0x7f4bf3667d28]
21-Apr-2021 20:41:42.191 /home/ondrej/.tsan/lib/libuv.so.1(+0x1538a) [0x7f4bf2c9838a]
21-Apr-2021 20:41:42.191 /home/ondrej/.tsan/lib/libuv.so.1(uv__io_poll+0x687) [0x7f4bf2cb1bb7]
21-Apr-2021 20:41:42.191 /home/ondrej/.tsan/lib/libuv.so.1(uv_run+0xcd) [0x7f4bf2c989ad]
21-Apr-2021 20:41:42.191 /home/ondrej/Projects/bind9/lib/isc/.libs/libisc-9.17.11.so(+0x28eae) [0x7f4bf3667eae]
21-Apr-2021 20:41:42.191 /home/ondrej/Projects/bind9/lib/isc/.libs/libisc-9.17.11.so(isc__trampoline_run+0xad) [0x7f4bf36d615d]
21-Apr-2021 20:41:42.191 /home/ondrej/Projects/bind9/bin/named/.libs/named() [0x43e18d]
21-Apr-2021 20:41:42.191 /lib/x86_64-linux-gnu/libpthread.so.0(+0x8ea7) [0x7f4bf2a56ea7]
21-Apr-2021 20:41:42.191 /lib/x86_64-linux-gnu/libc.so.6(clone+0x3f) [0x7f4bf281cdef]
21-Apr-2021 20:41:42.191 exiting (due to assertion failure)
```May 2021 (9.11.32, 9.11.32-S1, 9.16.16, 9.16.16-S1, 9.17.13)https://gitlab.isc.org/isc-projects/bind9/-/issues/2645Add builtin kasp policy "insecure"2021-05-11T07:03:39ZMatthijs Mekkingmatthijs@isc.orgAdd builtin kasp policy "insecure"Currently when you want to unsign your zone you just reconfigure `dnssec-policy` from whatever you are using to `none`. This will gracefully unsign your zone. To allow for a graceful transition, DNSSEC maintenance is still required for t...Currently when you want to unsign your zone you just reconfigure `dnssec-policy` from whatever you are using to `none`. This will gracefully unsign your zone. To allow for a graceful transition, DNSSEC maintenance is still required for the zone.
This means that with `dnssec-policy none;` the keymgr still needs to run for the zone if there are key state files present. The presence of such files is an indication that the graceful transition is not yet done.
This introduces some corner cases that are becoming somewhat a maintenance burden. So we will introduce an operational change when going to insecure:
1. Instead of reconfigure `dnssec-policy` to `none`, you should now reconfigure to `insecure`.
2. Once the transition is completed, you can remove the key state files (and the public and private key files too).
3. Then reconfigure once more to `dnssec-policy none;` to disable DNSSEC maintenance.
- [x] Update the code
- [x] Update the tests
- [x] Update the documentation
- [x] Update the DNSSEC guideMay 2021 (9.11.32, 9.11.32-S1, 9.16.16, 9.16.16-S1, 9.17.13)Matthijs Mekkingmatthijs@isc.orgMatthijs Mekkingmatthijs@isc.orghttps://gitlab.isc.org/isc-projects/bind9/-/issues/2644connectcb could be called with empty handle on socket failure2021-06-09T20:23:53ZOndřej Surýconnectcb could be called with empty handle on socket failureHappens on macOS, but it will probably also happen on BSDs where the socket call might fail:
```
netmgr/netmgr.c:2510: REQUIRE(((__builtin_expect(!!((uvreq->handle) != ((void*)0)), 1) && __builtin_expect(!!(((const isc__magic_t *)(uvreq-...Happens on macOS, but it will probably also happen on BSDs where the socket call might fail:
```
netmgr/netmgr.c:2510: REQUIRE(((__builtin_expect(!!((uvreq->handle) != ((void*)0)), 1) && __builtin_expect(!!(((const isc__magic_t *)(uvreq->handle))->magic == ((('N') << 24 | ('M') << 16 | ('H') << 8 | ('D')))), 1)) && __c11_atomic_load(&(uvreq->handle)->references, 5) > 0)) failed, back trace
netmgr/netmgr.c:2510: REQUIRE(((__builtin_expect(!!((uvreq->handle) != ((void*)0)), 1) && __builtin_expect(!!(((const isc__magic_t *)(uvreq->handle))->magic == ((('N') << 24 | ('M') << 16 | ('H') << 8 | ('D')))), 1)) && __c11_atomic_load(&(uvreq->handle)->references, 5) > 0)) failed, back trace
0 libisc-9.17.11.dylib 0x00000001081d08d1 default_callback + 81
1 libisc-9.17.11.dylib 0x00000001081d085a isc_assertion_failed + 10
2 libisc-9.17.11.dylib 0x00000001081ac1e1 isc__nm_connectcb + 193
3 netmgr_test 0x000000010814dcbc isc_nm_udpconnect + 380
4 netmgr_test 0x0000000108155c93 udp_connect + 51
5 netmgr_test 0x0000000108155bf9 connect_thread + 137
6 libisc-9.17.11.dylib 0x00000001081ef7fe isc__trampoline_run + 62
7 libsystem_pthread.dylib 0x00007fff20594950 _pthread_start + 224
8 libsystem_pthread.dylib 0x00007fff2059047b thread_start + 15
0 libisc-9.17.11.dylib 0x00000001081d08d1 default_callback + 81
1 libisc-9.17.11.dylib 0x00000001081d085a isc_assertion_failed + 10
2 libisc-9.17.11.dylib 0x00000001081ac1e1 isc__nm_connectcb + 193
3 netmgr_test 0x000000010814dcbc isc_nm_udpconnect + 380
4 netmgr_test 0x0000000108155c93 udp_connect + 51
5 netmgr_test 0x0000000108155bf9 connect_thread + 137
6 libisc-9.17.11.dylib 0x00000001081ef7fe isc__trampoline_run + 62
7 libsystem_pthread.dylib 0x00007fff20594950 _pthread_start + 224
8 libsystem_pthread.dylib 0x00007fff2059047b thread_start + 15
Abort trap: 6
```May 2021 (9.11.32, 9.11.32-S1, 9.16.16, 9.16.16-S1, 9.17.13)https://gitlab.isc.org/isc-projects/bind9/-/issues/2643'rndc config' timed out.2022-01-07T12:21:54ZMark Andrews'rndc config' timed out.Job [#1654624](https://gitlab.isc.org/isc-projects/bind9/-/jobs/1654624) failed for 855897ff575d0af0e90d91bfc61ccad3d577aa0e:
Is the timeout too short?
```
8466I:rndc:test 'rndc reconfig' with loading of a large zone (52)
8467I:rndc:re...Job [#1654624](https://gitlab.isc.org/isc-projects/bind9/-/jobs/1654624) failed for 855897ff575d0af0e90d91bfc61ccad3d577aa0e:
Is the timeout too short?
```
8466I:rndc:test 'rndc reconfig' with loading of a large zone (52)
8467I:rndc:reloading config
8468I:rndc:failed
8469I:rndc:check if zone load was scheduled (53)
8470I:rndc:failed
8471I:rndc:check if query for the zone returns SERVFAIL (54)
8472I:rndc:failed (ignored)
8473I:rndc:wait for the zones to be loaded (55)
8474I:rndc:check if query for the zone returns NOERROR (56)
```
rndc.out.1.test52
```
rndc: recv failed: timed out
```
named.run:
```
21-Apr-2021 02:26:05.662 managed-keys-zone: dns_journal_compact: success
21-Apr-2021 02:26:24.021 allocate new control connection
21-Apr-2021 02:26:24.025 received control channel command 'reconfig'
21-Apr-2021 02:26:24.025 loading configuration from '/builds/isc-projects/bind9/bin/tests/system/rndc/ns6/named.conf'
21-Apr-2021 02:26:24.025 unable to open '/builds/isc-projects/bind9/.local/etc/bind.keys'; using built-in keys instead
21-Apr-2021 02:26:24.033 set maximum stack size to 18446744073709551615: success
21-Apr-2021 02:26:24.033 set maximum data size to 18446744073709551615: success
21-Apr-2021 02:26:24.033 set maximum core size to 18446744073709551615: success
21-Apr-2021 02:26:24.033 set maximum open files to 18446744073709551615: success
...
21-Apr-2021 02:26:24.097 scheduled loading new zones
...
21-Apr-2021 02:27:43.745 zone huge.zone/IN: loaded serial 1397051952
21-Apr-2021 02:27:43.745 zone_postload: zone huge.zone/IN: done
21-Apr-2021 02:27:43.745 any newly configured zones are now loaded
```June 2021 (9.11.33, 9.11.33-S1, 9.16.17/9.16.18, 9.16.17-S1/9.16.18-S1, 9.17.14/9.17.15)https://gitlab.isc.org/isc-projects/bind9/-/issues/2642Reduce the maximum NSEC3 iterations that can be configured2021-04-30T01:16:31ZMark AndrewsReduce the maximum NSEC3 iterations that can be configuredMay 2021 (9.11.32, 9.11.32-S1, 9.16.16, 9.16.16-S1, 9.17.13)https://gitlab.isc.org/isc-projects/bind9/-/issues/2639bind 9.16.11 memory leak on FreeBSD2021-05-04T09:54:12ZVsevolod Volkovbind 9.16.11 memory leak on FreeBSD<!--
If the bug you are reporting is potentially security-related - for example,
if it involves an assertion failure or other crash in `named` that can be
triggered repeatedly - then please do *NOT* report it here, but send an
email to [...<!--
If the bug you are reporting is potentially security-related - for example,
if it involves an assertion failure or other crash in `named` that can be
triggered repeatedly - then please do *NOT* report it here, but send an
email to [security-officer@isc.org](security-officer@isc.org).
-->
### Summary
In some cases on FreeBSD 12.2 bind 9.16.11 and newer leaks memory until it has consumed all the available RAM and swap. I've 3 bare metal servers with FreeBSD 12.2 and named 9.16.13 configured to provide primary zones. Two of them leaks memory fast enough. Another one doesn't leak memory at all.
### BIND version used
```
BIND 9.16.13 (Stable Release) <id:072e758>
running on FreeBSD amd64 12.2-RELEASE FreeBSD 12.2-RELEASE r366954 GENERIC
built by make with '--disable-linux-caps' '--localstatedir=/var' '--sysconfdir=/usr/local/etc/namedb' '--with-dlopen=yes' '--with-libxml2' '--with-openssl=/usr' '--with-readline=-L/usr/local/lib -ledit' '--with-dlz-filesystem=yes' '--enable-dnstap' '--disable-fixed-rrset' '--disable-geoip' '--without-maxminddb' '--without-gssapi' '--with-libidn2=/usr/local' '--with-json-c' '--disable-largefile' '--with-lmdb=/usr/local' '--disable-native-pkcs11' '--without-python' '--disable-querytrace' '--enable-tcp-fastopen' '--disable-symtable' '--prefix=/usr/local' '--mandir=/usr/local/man' '--infodir=/usr/local/share/info/' '--build=amd64-portbld-freebsd12.2' 'build_alias=amd64-portbld-freebsd12.2' 'CC=cc' 'CFLAGS=-O2 -pipe -DLIBICONV_PLUG -fstack-protector-strong -isystem /usr/local/include -fno-strict-aliasing ' 'LDFLAGS= -L/usr/local/lib -ljson-c -fstack-protector-strong ' 'LIBS=-L/usr/local/lib' 'CPPFLAGS=-DLIBICONV_PLUG -isystem /usr/local/include' 'CPP=cpp' 'PKG_CONFIG=pkgconf'
compiled by CLANG FreeBSD Clang 10.0.1 (git@github.com:llvm/llvm-project.git llvmorg-10.0.1-0-gef32c611aa2)
compiled with OpenSSL version: OpenSSL 1.1.1h-freebsd 22 Sep 2020
linked to OpenSSL version: OpenSSL 1.1.1h-freebsd 22 Sep 2020
compiled with libuv version: 1.41.0
linked to libuv version: 1.41.0
compiled with libxml2 version: 2.9.10
linked to libxml2 version: 20910
compiled with json-c version: 0.15
linked to json-c version: 0.15
compiled with zlib version: 1.2.11
linked to zlib version: 1.2.11
compiled with protobuf-c version: 1.3.2
linked to protobuf-c version: 1.3.2
threads support is enabled
default paths:
named configuration: /usr/local/etc/namedb/named.conf
rndc configuration: /usr/local/etc/namedb/rndc.conf
DNSSEC root key: /usr/local/etc/namedb/bind.keys
nsupdate session key: /var/run/named/session.key
named PID file: /var/run/named/pid
named lock file: /var/run/named/named.lock
```
### Steps to reproduce
1. pkg install bind916
2. Add to /usr/local/etc/namedb/named.conf primary zone(s).
3. service named start
### Relevant configuration file
```
options {
directory "/usr/local/etc/namedb/working";
dump-file "/var/dump/named_dump.db";
listen-on {
<IP1>/32;
};
pid-file "/var/run/named/pid";
statistics-file "/var/run/named/stats";
allow-recursion {
<IP1>/32;
<IP2>/32;
<IP3>/32;
};
check-names master ignore;
disable-empty-zone "255.255.255.255.IN-ADDR.ARPA";
disable-empty-zone "0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.IP6.ARPA";
disable-empty-zone "1.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.IP6.ARPA";
max-cache-size 268435456;
query-source <IP1>;
allow-query {
"any";
};
allow-transfer {
<IP1>/32;
<IP4>/32;
<IP5>/32;
<IP6>/32;
<IP3>/32;
};
also-notify {
<IP4>;
<IP2>;
};
notify explicit;
notify-source <IP1>;
transfer-source <IP1>;
};
zone "." {
type hint;
file "/usr/local/etc/namedb/named.root";
};
zone "localhost" {
type master;
file "/usr/local/etc/namedb/master/localhost-forward.db";
};
zone "127.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/localhost-reverse.db";
};
zone "255.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "0.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/localhost-reverse.db";
};
zone "0.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "10.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "16.172.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "17.172.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "18.172.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "19.172.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "20.172.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "21.172.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "22.172.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "23.172.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "24.172.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "25.172.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "26.172.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "27.172.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "28.172.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "29.172.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "30.172.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "31.172.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "168.192.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "64.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "65.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "66.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "67.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "68.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "69.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "70.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "71.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "72.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "73.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "74.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "75.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "76.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "77.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "78.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "79.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "80.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "81.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "82.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "83.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "84.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "85.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "86.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "87.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "88.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "89.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "90.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "91.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "92.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "93.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "94.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "95.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "96.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "97.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "98.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "99.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "100.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "101.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "102.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "103.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "104.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "105.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "106.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "107.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "108.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "109.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "110.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "111.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "112.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "113.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "114.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "115.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "116.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "117.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "118.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "119.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "120.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "121.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "122.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "123.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "124.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "125.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "126.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "127.100.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "254.169.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "0.0.192.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "2.0.192.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "100.51.198.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "113.0.203.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "8.b.d.0.1.0.0.2.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "18.198.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "19.198.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "240.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "241.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "242.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "243.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "244.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "245.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "246.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "247.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "248.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "249.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "250.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "251.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "252.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "253.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "254.in-addr.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "1.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "3.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "4.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "5.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "6.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "7.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "8.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "9.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "a.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "b.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "c.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "d.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "e.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "0.f.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "1.f.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "2.f.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "3.f.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "4.f.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "5.f.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "6.f.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "7.f.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "8.f.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "9.f.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "a.f.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "b.f.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "0.e.f.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "1.e.f.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "2.e.f.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "3.e.f.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "4.e.f.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "5.e.f.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "6.e.f.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "7.e.f.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "c.f.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "d.f.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "8.e.f.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "9.e.f.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "a.e.f.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "b.e.f.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "c.e.f.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "d.e.f.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "e.e.f.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "f.e.f.ip6.arpa" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "ip6.int" {
type master;
file "/usr/local/etc/namedb/master/empty.db";
};
zone "domain1" {
type master;
file "/usr/local/etc/namedb/master/domain1";
};
zone "domain2" {
type master;
file "/usr/local/etc/namedb/master/domain2";
};
zone "domain3" {
type master;
file "/usr/local/etc/namedb/master/domain3";
};
.....
```
### Relevant logs
```
Apr 1 18:25:54 src named[54966]: starting BIND 9.16.13 (Stable Release) <id:072e758>
Apr 1 18:25:54 src named[54966]: running on FreeBSD amd64 12.2-RELEASE-p3 FreeBSD 12.2-RELEASE-p3 GENERIC
Apr 1 18:25:54 src named[54966]: built with '--disable-linux-caps' '--localstatedir=/var' '--sysconfdir=/usr/local/etc/namedb' '--with-dlopen=yes' '--with-libxml2' '--with-openssl=/usr' '--with-readline=-L/usr/local/lib -ledit' '--with-dlz-filesystem=yes' '--enable-dnstap' '--disable-fixed-rrset' '--disable-geoip' '--without-maxminddb' '--without-gssapi' '--with-libidn2=/usr/local' '--with-json-c' '--disable-largefile' '--with-lmdb=/usr/local' '--disable-native-pkcs11' '--without-python' '--disable-querytrace' '--enable-tcp-fastopen' '--disable-symtable' '--prefix=/usr/local' '--mandir=/usr/local/man' '--infodir=/usr/local/share/info/' '--build=amd64-portbld-freebsd12.2' 'build_alias=amd64-portbld-freebsd12.2' 'CC=cc' 'CFLAGS=-O2 -pipe -DLIBICONV_PLUG -fstack-protector-strong -isystem /usr/local/include -fno-strict-aliasing ' 'LDFLAGS= -L/usr/local/lib -ljson-c -fstack-protector-strong ' 'LIBS=-L/usr/local/lib' 'CPPFLAGS=-DLIBICONV_PLUG -isystem /usr/local/include' 'CPP=cpp' 'PKG_CONFIG=pkgconf'
Apr 1 18:25:54 src named[54966]: running as: named -u bind -c /usr/local/etc/namedb/named.conf
Apr 1 18:25:54 src named[54966]: compiled by CLANG FreeBSD Clang 10.0.1 (git@github.com:llvm/llvm-project.git llvmorg-10.0.1-0-gef32c611aa2)
Apr 1 18:25:54 src named[54966]: compiled with OpenSSL version: OpenSSL 1.1.1h-freebsd 22 Sep 2020
Apr 1 18:25:54 src named[54966]: linked to OpenSSL version: OpenSSL 1.1.1h-freebsd 22 Sep 2020
Apr 1 18:25:54 src named[54966]: compiled with libxml2 version: 2.9.10
Apr 1 18:25:54 src named[54966]: linked to libxml2 version: 20910
Apr 1 18:25:54 src named[54966]: compiled with json-c version: 0.15
Apr 1 18:25:54 src named[54966]: linked to json-c version: 0.15
Apr 1 18:25:54 src named[54966]: compiled with zlib version: 1.2.11
Apr 1 18:25:54 src named[54966]: linked to zlib version: 1.2.11
Apr 1 18:25:54 src named[54966]: ----------------------------------------------------
Apr 1 18:25:54 src named[54966]: BIND 9 is maintained by Internet Systems Consortium,
Apr 1 18:25:54 src named[54966]: Inc. (ISC), a non-profit 501(c)(3) public-benefit
Apr 1 18:25:54 src named[54966]: corporation. Support and training for BIND 9 are
Apr 1 18:25:54 src named[54966]: available at https://www.isc.org/support
Apr 1 18:25:54 src named[54966]: ----------------------------------------------------
Apr 1 18:25:54 src named[54966]: found 24 CPUs, using 24 worker threads
Apr 1 18:25:54 src named[54966]: using 24 UDP listeners per interface
Apr 1 18:25:54 src named[54966]: using up to 21000 sockets
Apr 1 18:25:54 src named[54966]: loading configuration from '/usr/local/etc/namedb/named.conf'
Apr 1 18:25:54 src named[54966]: reading built-in trust anchors from file '/usr/local/etc/namedb/bind.keys'
Apr 1 18:25:54 src named[54966]: using default UDP/IPv4 port range: [49152, 65535]
Apr 1 18:25:54 src named[54966]: using default UDP/IPv6 port range: [49152, 65535]
Apr 1 18:25:54 src named[54966]: listening on IPv4 interface em0, NNN.NNN.NNN.NNN#53
Apr 1 18:25:54 src named[54966]: IPv6 socket API is incomplete; explicitly binding to each IPv6 address separately
Apr 1 18:25:54 src named[54966]: listening on IPv6 interface lo0, ::1#53
Apr 1 18:25:54 src named[54966]: creating IPv6 interface lo0 failed; interface ignored
Apr 1 18:25:54 src named[54966]: listening on IPv6 interface lo0, fe80::1%3#53
Apr 1 18:25:54 src named[54966]: generating session key for dynamic DNS
Apr 1 18:25:54 src named[54966]: sizing zone task pool based on 419 zones
Apr 1 18:25:55 src named[54966]: obtaining root key for view _default from '/usr/local/etc/namedb/bind.keys'
Apr 1 18:25:55 src named[54966]: set up managed keys zone for view _default, file 'managed-keys.bind'
Apr 1 18:25:55 src named[54966]: automatic empty zone: EMPTY.AS112.ARPA
Apr 1 18:25:55 src named[54966]: automatic empty zone: HOME.ARPA
Apr 1 18:25:55 src named[54966]: configuring command channel from '/usr/local/etc/namedb/rndc.key'
Apr 1 18:25:55 src named[54966]: command channel listening on 127.0.0.1#953
Apr 1 18:25:55 src named[54966]: configuring command channel from '/usr/local/etc/namedb/rndc.key'
Apr 1 18:25:55 src named[54966]: command channel listening on ::1#953
Apr 1 18:25:55 src named[54966]: additionally listening on IPv6 interface lo0, ::1#53
Apr 1 18:25:55 src named[54966]: creating IPv6 interface lo0 failed; interface ignored
...
Apr 3 12:32:40 src named[54966]: listening on IPv6 interface lo0, ::1#53
<<< Here process was killed by kernel >>>
Apr 3 14:11:52 src named[1430]: starting BIND 9.16.10 (Stable Release) <id:fac8def>
```
### Possible fixes
The problem should be looked for in changes between 9.16.10 and 9.16.11.https://gitlab.isc.org/isc-projects/bind9/-/issues/2638Run internal tasks on top of network manager worker loops2021-09-02T09:40:28ZOndřej SurýRun internal tasks on top of network manager worker loopsAfter the networking manager was introduced, the existing taskmgr kept its own set of worker threads competing with the netmgr threads. This issue is about moving the tasks to run on top of netmgr loops while keeping the existing interfa...After the networking manager was introduced, the existing taskmgr kept its own set of worker threads competing with the netmgr threads. This issue is about moving the tasks to run on top of netmgr loops while keeping the existing interface.
---
The primary merge requests implementing this change are:
- !4918
- !4983
The above changes required some follow-up tweaks, which were implemented in:
- !4980
- !4981
- !4982
- !5006
- !5008
- !5009
- !5010May 2021 (9.11.32, 9.11.32-S1, 9.16.16, 9.16.16-S1, 9.17.13)Ondřej SurýOndřej Surýhttps://gitlab.isc.org/isc-projects/bind9/-/issues/2637ThreadSanitizer: lock-order-inversion (potential deadlock) in zone_refreshkeys2021-04-26T12:50:30ZOndřej SurýThreadSanitizer: lock-order-inversion (potential deadlock) in zone_refreshkeys```
WARNING: ThreadSanitizer: lock-order-inversion (potential deadlock)
Cycle in lock order graph: M1 (0x000000000001) => M2 (0x000000000000) => M1
Mutex M2 acquired here while holding mutex M1 in thread T1:
#0 pthread_mutex_loc...```
WARNING: ThreadSanitizer: lock-order-inversion (potential deadlock)
Cycle in lock order graph: M1 (0x000000000001) => M2 (0x000000000000) => M1
Mutex M2 acquired here while holding mutex M1 in thread T1:
#0 pthread_mutex_lock <null>
#1 dns_view_findzonecut lib/dns/view.c:1326:2
#2 fctx_create lib/dns/resolver.c:5144:13
#3 dns_resolver_createfetch lib/dns/resolver.c:10977:12
#4 zone_refreshkeys lib/dns/zone.c:10830:13
#5 zone_maintenance lib/dns/zone.c:11065:5
#6 zone_timer lib/dns/zone.c:14652:2
#7 task_run lib/isc/task.c:857:5
#8 isc_task_run lib/isc/task.c:944:10
#9 isc__nm_async_task lib/isc/netmgr/netmgr.c:730:24
#10 process_netievent lib/isc/netmgr/netmgr.c
#11 process_queue lib/isc/netmgr/netmgr.c:885:8
#12 process_tasks_queue lib/isc/netmgr/netmgr.c:756:10
#13 process_queues lib/isc/netmgr/netmgr.c:772:7
#14 async_cb lib/isc/netmgr/netmgr.c:671:2
#15 uv__async_io /home/ondrej/Projects/tsan/libuv/src/unix/async.c:163:5
#16 uv__io_poll /home/ondrej/Projects/tsan/libuv/src/unix/linux-core.c:462:11
#17 uv_run /home/ondrej/Projects/tsan/libuv/src/unix/core.c:392:5
#18 nm_thread lib/isc/netmgr/netmgr.c:597:11
#19 isc__trampoline_run lib/isc/trampoline.c:184:11
Mutex M1 previously acquired by the same thread here:
#0 pthread_mutex_lock <null>
#1 zone_refreshkeys lib/dns/zone.c:10717:2
#2 zone_maintenance lib/dns/zone.c:11065:5
#3 zone_timer lib/dns/zone.c:14652:2
#4 task_run lib/isc/task.c:857:5
#5 isc_task_run lib/isc/task.c:944:10
#6 isc__nm_async_task lib/isc/netmgr/netmgr.c:730:24
#7 process_netievent lib/isc/netmgr/netmgr.c
#8 process_queue lib/isc/netmgr/netmgr.c:885:8
#9 process_tasks_queue lib/isc/netmgr/netmgr.c:756:10
#10 process_queues lib/isc/netmgr/netmgr.c:772:7
#11 async_cb lib/isc/netmgr/netmgr.c:671:2
#12 uv__async_io /home/ondrej/Projects/tsan/libuv/src/unix/async.c:163:5
#13 uv__io_poll /home/ondrej/Projects/tsan/libuv/src/unix/linux-core.c:462:11
#14 uv_run /home/ondrej/Projects/tsan/libuv/src/unix/core.c:392:5
#15 nm_thread lib/isc/netmgr/netmgr.c:597:11
#16 isc__trampoline_run lib/isc/trampoline.c:184:11
Mutex M1 acquired here while holding mutex M2 in thread T2:
#0 pthread_mutex_lock <null>
#1 dns_zone_flush lib/dns/zone.c:11443:2
#2 view_flushanddetach lib/dns/view.c:657:5
#3 dns_view_flushanddetach lib/dns/view.c:690:2
#4 shutdown_server bin/named/server.c:10056:4
#5 task_run lib/isc/task.c:857:5
#6 isc_task_run lib/isc/task.c:944:10
#7 isc__nm_async_task lib/isc/netmgr/netmgr.c:730:24
#8 process_netievent lib/isc/netmgr/netmgr.c
#9 process_queue lib/isc/netmgr/netmgr.c:885:8
#10 process_tasks_queue lib/isc/netmgr/netmgr.c:756:10
#11 process_queues lib/isc/netmgr/netmgr.c:772:7
#12 async_cb lib/isc/netmgr/netmgr.c:671:2
#13 uv__async_io /home/ondrej/Projects/tsan/libuv/src/unix/async.c:163:5
#14 uv__io_poll /home/ondrej/Projects/tsan/libuv/src/unix/linux-core.c:462:11
#15 uv_run /home/ondrej/Projects/tsan/libuv/src/unix/core.c:392:5
#16 nm_thread lib/isc/netmgr/netmgr.c:597:11
#17 isc__trampoline_run lib/isc/trampoline.c:184:11
Mutex M2 previously acquired by the same thread here:
#0 pthread_mutex_lock <null>
#1 view_flushanddetach lib/dns/view.c:645:3
#2 dns_view_flushanddetach lib/dns/view.c:690:2
#3 shutdown_server bin/named/server.c:10056:4
#4 task_run lib/isc/task.c:857:5
#5 isc_task_run lib/isc/task.c:944:10
#6 isc__nm_async_task lib/isc/netmgr/netmgr.c:730:24
#7 process_netievent lib/isc/netmgr/netmgr.c
#8 process_queue lib/isc/netmgr/netmgr.c:885:8
#9 process_tasks_queue lib/isc/netmgr/netmgr.c:756:10
#10 process_queues lib/isc/netmgr/netmgr.c:772:7
#11 async_cb lib/isc/netmgr/netmgr.c:671:2
#12 uv__async_io /home/ondrej/Projects/tsan/libuv/src/unix/async.c:163:5
#13 uv__io_poll /home/ondrej/Projects/tsan/libuv/src/unix/linux-core.c:462:11
#14 uv_run /home/ondrej/Projects/tsan/libuv/src/unix/core.c:392:5
#15 nm_thread lib/isc/netmgr/netmgr.c:597:11
#16 isc__trampoline_run lib/isc/trampoline.c:184:11
Thread T2 (running) created by main thread at:
#0 pthread_create <null>
#1 isc_thread_create lib/isc/pthreads/thread.c:79:8
#2 isc_nm_start lib/isc/netmgr/netmgr.c:303:3
#3 create_managers bin/named/main.c:957:15
#4 setup bin/named/main.c:1267:11
#5 main bin/named/main.c:1558:2
Thread T2 (running) created by main thread at:
#0 pthread_create <null>
#1 isc_thread_create lib/isc/pthreads/thread.c:79:8
#2 isc_nm_start lib/isc/netmgr/netmgr.c:303:3
#3 create_managers bin/named/main.c:957:15
#4 setup bin/named/main.c:1267:11
#5 main bin/named/main.c:1558:2
SUMMARY: ThreadSanitizer: lock-order-inversion (potential deadlock) in __interceptor_pthread_mutex_lock
```May 2021 (9.11.32, 9.11.32-S1, 9.16.16, 9.16.16-S1, 9.17.13)https://gitlab.isc.org/isc-projects/bind9/-/issues/2636timing race in setnsec3param task2021-04-19T09:49:09ZOndřej Surýtiming race in setnsec3param taskIn `zone_postload()` the queued `zone->setnsec3param_queue` get scheduled as regular tasks:
> /*
> * Process any queued NSEC3PARAM change requests. Only for dynamic
> * zones, an inline-signing zone will perfor...In `zone_postload()` the queued `zone->setnsec3param_queue` get scheduled as regular tasks:
> /*
> * Process any queued NSEC3PARAM change requests. Only for dynamic
> * zones, an inline-signing zone will perform this action when
> * receiving the secure db (receive_secure_db).
> */
However, the original reason why the NSEC3PARAM change requests were originally queued depends on following code:
> /*
> * setnsec3param() will silently return early if the zone does not yet
> * have a database. Prevent that by queueing the event up if zone->db
> * is NULL. All events queued here are subsequently processed by
> * receive_secure_db() if it ever gets called or simply freed by
> * zone_free() otherwise.
> */
So, when all the queued events gets scheduled as tasks in the `zone_postload()` and the tasks are fired up, the `zone->db` still might be `NULL`. Due to a difference in scheduling this doesn't really happen with the old (separate) task manager, but it's very easy to trigger in the taskmgr@netmgr.May 2021 (9.11.32, 9.11.32-S1, 9.16.16, 9.16.16-S1, 9.17.13)Ondřej SurýOndřej Surýhttps://gitlab.isc.org/isc-projects/bind9/-/issues/2635Update default primary server list for the root zone2021-09-08T10:44:18ZMichał KępieńUpdate default primary server list for the root zone`DEFAULT_IANA_ROOT_ZONE_PRIMARIES` should be updated. This was [pointed
out][1] by @rocharj (thanks!).
AFAICT, only the `b.root-servers.net` addresses are outdated, but
perhaps there are other adjustments that can be made (e.g. adding ...`DEFAULT_IANA_ROOT_ZONE_PRIMARIES` should be updated. This was [pointed
out][1] by @rocharj (thanks!).
AFAICT, only the `b.root-servers.net` addresses are outdated, but
perhaps there are other adjustments that can be made (e.g. adding new
addresses providing root zone AXFRs?), so I decided to create an issue
for this task.
[1]: https://gitlab.isc.org/isc-projects/bind9/-/commit/2c69734bcf00feef18eb61fbf48324a4688296c5#note_207300October 2021 (9.11.36, 9.11.36-S1, 9.16.22, 9.16.22-S1, 9.17.19)Arаm SаrgsyаnArаm Sаrgsyаnhttps://gitlab.isc.org/isc-projects/bind9/-/issues/2634"tkey-gssapi-credential" is broken in BIND 9.16.14 and 9.11.302021-04-26T08:06:09ZMichał Kępień"tkey-gssapi-credential" is broken in BIND 9.16.14 and 9.11.30!4855 & !4857 left a bit of code in internal GSSAPI-related BIND headers
which causes the `GSS_SPNEGO_MECHANISM` preprocessor macro to be defined
to `NULL` if it is not defined by the headers provided by the
Kerberos/GSSAPI library used....!4855 & !4857 left a bit of code in internal GSSAPI-related BIND headers
which causes the `GSS_SPNEGO_MECHANISM` preprocessor macro to be defined
to `NULL` if it is not defined by the headers provided by the
Kerberos/GSSAPI library used. This ultimately leads to the
`dst_gssapi_acquirecred()` function always failing, preventing any
`named` instance using `tkey-gssapi-credential` from working.
This is a regression since BIND 9.16.13 & 9.11.29.
See: https://support.isc.org/Ticket/Display.html?id=18298May 2021 (9.11.32, 9.11.32-S1, 9.16.16, 9.16.16-S1, 9.17.13)Michał KępieńMichał Kępieńhttps://gitlab.isc.org/isc-projects/bind9/-/issues/2632doh_test keeps failing in doh_half_recv_send_GET_TLS on FreeBSD 13.02021-05-11T08:57:09ZMichal Nowakdoh_test keeps failing in doh_half_recv_send_GET_TLS on FreeBSD 13.0The `doh_test` always fails in the `doh_half_recv_send_GET_TLS` test on FreeBSD 13.0, preventing us from adding FreeBSD 13.0.
```
[==========] Running 32 test(s).
[ RUN ] mock_doh_uv_tcp_bind
[ OK ] mock_doh_uv_tcp_bind
[ RUN ...The `doh_test` always fails in the `doh_half_recv_send_GET_TLS` test on FreeBSD 13.0, preventing us from adding FreeBSD 13.0.
```
[==========] Running 32 test(s).
[ RUN ] mock_doh_uv_tcp_bind
[ OK ] mock_doh_uv_tcp_bind
[ RUN ] doh_parse_GET_query_string
[ OK ] doh_parse_GET_query_string
[ RUN ] doh_base64url_to_base64
[ OK ] doh_base64url_to_base64
[ RUN ] doh_base64_to_base64url
[ OK ] doh_base64_to_base64url
[ RUN ] doh_noop_POST
[ OK ] doh_noop_POST
[ RUN ] doh_noop_GET
[ OK ] doh_noop_GET
[ RUN ] doh_noresponse_POST
[ OK ] doh_noresponse_POST
[ RUN ] doh_noresponse_GET
[ OK ] doh_noresponse_GET
[ RUN ] doh_recv_one_POST
[ OK ] doh_recv_one_POST
[ RUN ] doh_recv_one_GET
[ OK ] doh_recv_one_GET
[ RUN ] doh_recv_one_POST_TLS
[ OK ] doh_recv_one_POST_TLS
[ RUN ] doh_recv_one_GET_TLS
[ OK ] doh_recv_one_GET_TLS
[ RUN ] doh_recv_two_POST
[ OK ] doh_recv_two_POST
[ RUN ] doh_recv_two_GET
[ OK ] doh_recv_two_GET
[ RUN ] doh_recv_two_POST_TLS
[ OK ] doh_recv_two_POST_TLS
[ RUN ] doh_recv_two_GET_TLS
[ OK ] doh_recv_two_GET_TLS
[ RUN ] doh_recv_send_GET
[ OK ] doh_recv_send_GET
[ RUN ] doh_recv_send_POST
[ OK ] doh_recv_send_POST
[ RUN ] doh_recv_send_GET_TLS
[ OK ] doh_recv_send_GET_TLS
[ RUN ] doh_recv_send_POST_TLS
[ OK ] doh_recv_send_POST_TLS
[ RUN ] doh_recv_half_send_GET
[ OK ] doh_recv_half_send_GET
[ RUN ] doh_recv_half_send_POST
[ OK ] doh_recv_half_send_POST
[ RUN ] doh_recv_half_send_GET_TLS
[ OK ] doh_recv_half_send_GET_TLS
[ RUN ] doh_recv_half_send_POST_TLS
[ OK ] doh_recv_half_send_POST_TLS
[ RUN ] doh_half_recv_send_GET
[ OK ] doh_half_recv_send_GET
[ RUN ] doh_half_recv_send_POST
[ OK ] doh_half_recv_send_POST
[ RUN ] doh_half_recv_send_GET_TLS
netmgr/netmgr.c:497: INSIST(references == 1) failed, back trace
0x8002d4007 <isc_assertion_setcallback+0x57> at /usr/home/newman/bind9/lib/isc/.libs/libisc-9.17.11.so
0x8002d3faa <isc_assertion_failed+0xa> at /usr/home/newman/bind9/lib/isc/.libs/libisc-9.17.11.so
0x8002adf17 <isc_nm_destroy+0xc7> at /usr/home/newman/bind9/lib/isc/.libs/libisc-9.17.11.so
0x20ce59 <nm_teardown+0x19> at /usr/home/newman/bind9/lib/isc/tests/.libs/doh_test
0x800262613 <_run_group_tests+0x7c3> at /usr/local/lib/libcmocka.so.0
0x80026054f <_cmocka_run_group_tests+0x73f> at /usr/local/lib/libcmocka.so.0
I:doh_test:Core dump found: ./core.74014
D:doh_test:backtrace from ./core.74014 start
[New LWP 101440]
[New LWP 109163]
[New LWP 109164]
[New LWP 109165]
[New LWP 109166]
Core was generated by `/usr/home/newman/bind9/lib/isc/tests/.libs/doh_test'.
Program terminated with signal SIGABRT, Aborted.
#0 0x0000000800a242ea in thr_kill () from /lib/libc.so.7
[Current thread is 1 (LWP 101440)]
Thread 5 (LWP 109166 "isc-net-0003"):
#0 0x00000008002e19b6 in delete_trace_entry (mctx=mctx@entry=0x8010d1000, ptr=0x82d5d36c8, size=<optimized out>, size@entry=264, file=0x80028be6f "netmgr/netmgr.c", line=998) at mem.c:311
idx = <optimized out>
hash = <optimized out>
dl = <optimized out>
#1 0x00000008002e1857 in isc__mem_free (ctx=0x8010d1000, ptr=0x0, file=0x801052000 "\360B\262\020\b", file@entry=0x80028be6f "netmgr/netmgr.c", line=3540050681, line@entry=998) at mem.c:1009
call_water = false
size = 264
si = 0x82d5d36c0
#2 0x00000008002b3225 in nmsocket_cleanup (sock=sock@entry=0x82ce3f000, dofree=true) at netmgr/netmgr.c:998
uvreq = <optimized out>
handle = <optimized out>
#3 0x00000008002b0018 in nmsocket_maybe_destroy (sock=sock@entry=0x82ce3f000) at netmgr/netmgr.c:1069
destroy = <optimized out>
active_handles = 0
#4 0x00000008002afead in isc___nmsocket_prep_destroy (sock=0x82ce3f000) at netmgr/netmgr.c:1131
No locals.
#5 0x00000008002ae1ad in isc___nmsocket_detach (sockp=<optimized out>) at netmgr/netmgr.c:1158
sock = <optimized out>
rsock = 0x7b984e362165e5ec
#6 0x00000008002af166 in isc__nm_put_netievent_httpclose (nm=0x801024200, ievent=ievent@entry=0x806846080) at netmgr/netmgr.c:824
No locals.
#7 0x00000008002afccc in process_netievent (worker=worker@entry=0x801c55b10, ievent=0x806846080) at netmgr/netmgr.c:740
No locals.
#8 0x00000008002b2db8 in process_queue (worker=worker@entry=0x801c55b10, queue=0x806a6b180) at netmgr/netmgr.c:766
ievent = 0x70
#9 0x00000008002b2de0 in process_normal_queue (worker=0x7b984e362165e5ec, worker@entry=0x801c55b10) at netmgr/netmgr.c:652
No locals.
#10 0x00000008002b2d7a in process_queues (worker=0x801c55b10) at netmgr/netmgr.c:660
No locals.
#11 0x00000008002ad000 in async_cb (handle=<optimized out>) at netmgr/netmgr.c:618
worker = 0x7b984e362165e5ec
#12 0x00000008004df1da in ?? () from /usr/local/lib/libuv.so.1
No symbol table info available.
#13 0x00000008004f044b in uv.io_poll () from /usr/local/lib/libuv.so.1
No symbol table info available.
#14 0x00000008004df751 in uv_run () from /usr/local/lib/libuv.so.1
No symbol table info available.
#15 0x00000008002ad07b in nm_thread (worker0=0x801c55b10) at netmgr/netmgr.c:558
r = <optimized out>
worker = 0x801c55b10
mgr = 0x801024200
#16 0x00000008002f35c5 in isc__trampoline_run (arg=0x80275afa0) at trampoline.c:184
trampoline = 0x80275afa0
result = <optimized out>
#17 0x00000008008cd82b in ?? () from /lib/libthr.so.3
No symbol table info available.
#18 0x0000000000000000 in ?? ()
No symbol table info available.
Backtrace stopped: Cannot access memory at address 0x7fffdf9fb000
Thread 4 (LWP 109165 "isc-net-0002"):
#0 0x00000008008cab3a in ?? () from /lib/libthr.so.3
No symbol table info available.
#1 0x00000008008da2f0 in ?? () from /lib/libthr.so.3
No symbol table info available.
#2 0x00000008008d2eec in ?? () from /lib/libthr.so.3
No symbol table info available.
#3 0x00000008008d1cf9 in pthread_mutex_lock () from /lib/libthr.so.3
No symbol table info available.
#4 0x00000008002e192d in delete_trace_entry (mctx=mctx@entry=0x8010d1000, ptr=0x11, ptr@entry=0x868a1e800, size=1976, file=0x80028be6f "netmgr/netmgr.c", line=992) at mem.c:287
idx = <optimized out>
hash = <optimized out>
dl = <optimized out>
#5 0x00000008002e35a5 in isc__mempool_put (mpctx=0x801024000, mem=0x868a1e800, file=0x0, file@entry=0x80028be6f "netmgr/netmgr.c", line=0, line@entry=992) at mem.c:1405
item = 0x0
mctx = 0x8010d1000
freecount = 4096
freemax = 4096
#6 0x00000008002b31d9 in nmsocket_cleanup (sock=sock@entry=0x817085000, dofree=true) at netmgr/netmgr.c:992
uvreq = 0x1c6
handle = <optimized out>
#7 0x00000008002b0018 in nmsocket_maybe_destroy (sock=sock@entry=0x817085000) at netmgr/netmgr.c:1069
destroy = <optimized out>
active_handles = 0
#8 0x00000008002afead in isc___nmsocket_prep_destroy (sock=0x817085000) at netmgr/netmgr.c:1131
No locals.
#9 0x00000008002ae1ad in isc___nmsocket_detach (sockp=<optimized out>) at netmgr/netmgr.c:1158
sock = <optimized out>
rsock = 0x801600108
#10 0x00000008002af166 in isc__nm_put_netievent_httpclose (nm=0x801024200, ievent=ievent@entry=0x805e87c80) at netmgr/netmgr.c:824
No locals.
#11 0x00000008002afccc in process_netievent (worker=worker@entry=0x801c55760, ievent=0x805e87c80) at netmgr/netmgr.c:740
No locals.
#12 0x00000008002b2db8 in process_queue (worker=worker@entry=0x801c55760, queue=0x806a6ae80) at netmgr/netmgr.c:766
ievent = 0x1c6
#13 0x00000008002b2de0 in process_normal_queue (worker=0x801600108, worker@entry=0x801c55760) at netmgr/netmgr.c:652
No locals.
#14 0x00000008002b2d7a in process_queues (worker=0x801c55760) at netmgr/netmgr.c:660
No locals.
#15 0x00000008002ad000 in async_cb (handle=<optimized out>) at netmgr/netmgr.c:618
worker = 0x801600108
#16 0x00000008004df1da in ?? () from /usr/local/lib/libuv.so.1
No symbol table info available.
#17 0x00000008004f044b in uv.io_poll () from /usr/local/lib/libuv.so.1
No symbol table info available.
#18 0x00000008004df751 in uv_run () from /usr/local/lib/libuv.so.1
No symbol table info available.
#19 0x00000008002ad07b in nm_thread (worker0=0x801c55760) at netmgr/netmgr.c:558
r = <optimized out>
worker = 0x801c55760
mgr = 0x801024200
#20 0x00000008002f35c5 in isc__trampoline_run (arg=0x80109d140) at trampoline.c:184
trampoline = 0x80109d140
result = <optimized out>
#21 0x00000008008cd82b in ?? () from /lib/libthr.so.3
No symbol table info available.
#22 0x0000000000000000 in ?? ()
No symbol table info available.
Backtrace stopped: Cannot access memory at address 0x7fffdfbfc000
Thread 3 (LWP 109164 "isc-net-0001"):
#0 0x00000008008cab3a in ?? () from /lib/libthr.so.3
No symbol table info available.
#1 0x00000008008da2f0 in ?? () from /lib/libthr.so.3
No symbol table info available.
#2 0x00000008008d2eec in ?? () from /lib/libthr.so.3
No symbol table info available.
#3 0x00000008008d1cf9 in pthread_mutex_lock () from /lib/libthr.so.3
No symbol table info available.
#4 0x00000008002e192d in delete_trace_entry (mctx=mctx@entry=0x8010d1000, ptr=0x11, ptr@entry=0x8527f8100, size=size@entry=360, file=0x80028be6f "netmgr/netmgr.c", line=1460) at mem.c:287
idx = <optimized out>
hash = <optimized out>
dl = <optimized out>
#5 0x00000008002e2250 in isc__mem_put (ctx=0x8010d1000, ptr=ptr@entry=0x8527f8100, size=size@entry=360, file=0x0, line=0, line@entry=1460) at mem.c:781
call_water = false
si = <optimized out>
#6 0x00000008002b33a9 in nmhandle_free (sock=sock@entry=0x824f06800, handle=0x8527f8100) at netmgr/netmgr.c:1460
extra = <optimized out>
#7 0x00000008002b312b in nmsocket_cleanup (sock=sock@entry=0x824f06800, dofree=true) at netmgr/netmgr.c:976
uvreq = 0x0
handle = 0x1c6
#8 0x00000008002b0018 in nmsocket_maybe_destroy (sock=sock@entry=0x824f06800) at netmgr/netmgr.c:1069
destroy = <optimized out>
active_handles = 0
#9 0x00000008002afead in isc___nmsocket_prep_destroy (sock=0x824f06800) at netmgr/netmgr.c:1131
No locals.
#10 0x00000008002ae1ad in isc___nmsocket_detach (sockp=<optimized out>) at netmgr/netmgr.c:1158
sock = <optimized out>
rsock = 0x801600108
#11 0x00000008002af166 in isc__nm_put_netievent_httpclose (nm=0x801024200, ievent=ievent@entry=0x856235e80) at netmgr/netmgr.c:824
No locals.
#12 0x00000008002afccc in process_netievent (worker=worker@entry=0x801c553b0, ievent=0x856235e80) at netmgr/netmgr.c:740
No locals.
#13 0x00000008002b2db8 in process_queue (worker=worker@entry=0x801c553b0, queue=0x806a6ab80) at netmgr/netmgr.c:766
ievent = 0x1c6
#14 0x00000008002b2de0 in process_normal_queue (worker=0x801600108, worker@entry=0x801c553b0) at netmgr/netmgr.c:652
No locals.
#15 0x00000008002b2d7a in process_queues (worker=0x801c553b0) at netmgr/netmgr.c:660
No locals.
#16 0x00000008002ad000 in async_cb (handle=<optimized out>) at netmgr/netmgr.c:618
worker = 0x801600108
#17 0x00000008004df1da in ?? () from /usr/local/lib/libuv.so.1
No symbol table info available.
#18 0x00000008004f044b in uv.io_poll () from /usr/local/lib/libuv.so.1
No symbol table info available.
#19 0x00000008004df751 in uv_run () from /usr/local/lib/libuv.so.1
No symbol table info available.
#20 0x00000008002ad07b in nm_thread (worker0=0x801c553b0) at netmgr/netmgr.c:558
r = <optimized out>
worker = 0x801c553b0
mgr = 0x801024200
#21 0x00000008002f35c5 in isc__trampoline_run (arg=0x80109db60) at trampoline.c:184
trampoline = 0x80109db60
result = <optimized out>
#22 0x00000008008cd82b in ?? () from /lib/libthr.so.3
No symbol table info available.
#23 0x0000000000000000 in ?? ()
No symbol table info available.
Backtrace stopped: Cannot access memory at address 0x7fffdfdfd000
Thread 2 (LWP 109163 "isc-net-0000"):
#0 0x00000008008cab3a in ?? () from /lib/libthr.so.3
No symbol table info available.
#1 0x00000008008da2f0 in ?? () from /lib/libthr.so.3
No symbol table info available.
#2 0x00000008008d2eec in ?? () from /lib/libthr.so.3
No symbol table info available.
#3 0x00000008008d1cf9 in pthread_mutex_lock () from /lib/libthr.so.3
No symbol table info available.
#4 0x00000008002e192d in delete_trace_entry (mctx=mctx@entry=0x8010d1000, ptr=0x11, ptr@entry=0x862626d00, size=size@entry=360, file=0x80028be6f "netmgr/netmgr.c", line=1460) at mem.c:287
idx = <optimized out>
hash = <optimized out>
dl = <optimized out>
#5 0x00000008002e2250 in isc__mem_put (ctx=0x8010d1000, ptr=ptr@entry=0x862626d00, size=size@entry=360, file=0x0, line=0, line@entry=1460) at mem.c:781
call_water = false
si = <optimized out>
#6 0x00000008002b33a9 in nmhandle_free (sock=sock@entry=0x837431800, handle=0x862626d00) at netmgr/netmgr.c:1460
extra = <optimized out>
#7 0x00000008002b312b in nmsocket_cleanup (sock=sock@entry=0x837431800, dofree=true) at netmgr/netmgr.c:976
uvreq = 0x0
handle = 0x1c6
#8 0x00000008002b0018 in nmsocket_maybe_destroy (sock=sock@entry=0x837431800) at netmgr/netmgr.c:1069
destroy = <optimized out>
active_handles = 0
#9 0x00000008002afead in isc___nmsocket_prep_destroy (sock=0x837431800) at netmgr/netmgr.c:1131
No locals.
#10 0x00000008002ae1ad in isc___nmsocket_detach (sockp=<optimized out>) at netmgr/netmgr.c:1158
sock = <optimized out>
rsock = 0x801600108
#11 0x00000008002af166 in isc__nm_put_netievent_httpclose (nm=0x801024200, ievent=ievent@entry=0x84fb10980) at netmgr/netmgr.c:824
No locals.
#12 0x00000008002afccc in process_netievent (worker=worker@entry=0x801c55000, ievent=0x84fb10980) at netmgr/netmgr.c:740
No locals.
#13 0x00000008002b2db8 in process_queue (worker=worker@entry=0x801c55000, queue=0x806a6a880) at netmgr/netmgr.c:766
ievent = 0x1c6
#14 0x00000008002b2de0 in process_normal_queue (worker=0x801600108, worker@entry=0x801c55000) at netmgr/netmgr.c:652
No locals.
#15 0x00000008002b2d7a in process_queues (worker=0x801c55000) at netmgr/netmgr.c:660
No locals.
#16 0x00000008002ad000 in async_cb (handle=<optimized out>) at netmgr/netmgr.c:618
worker = 0x801600108
#17 0x00000008004df1da in ?? () from /usr/local/lib/libuv.so.1
No symbol table info available.
#18 0x00000008004f044b in uv.io_poll () from /usr/local/lib/libuv.so.1
No symbol table info available.
#19 0x00000008004df751 in uv_run () from /usr/local/lib/libuv.so.1
No symbol table info available.
#20 0x00000008002ad07b in nm_thread (worker0=0x801c55000) at netmgr/netmgr.c:558
r = <optimized out>
worker = 0x801c55000
mgr = 0x801024200
#21 0x00000008002f35c5 in isc__trampoline_run (arg=0x80275abc0) at trampoline.c:184
trampoline = 0x80275abc0
result = <optimized out>
#22 0x00000008008cd82b in ?? () from /lib/libthr.so.3
No symbol table info available.
#23 0x0000000000000000 in ?? ()
No symbol table info available.
Backtrace stopped: Cannot access memory at address 0x7fffdfffe000
Thread 1 (LWP 101440):
#0 0x0000000800a242ea in thr_kill () from /lib/libc.so.7
No symbol table info available.
#1 0x0000000800999064 in raise () from /lib/libc.so.7
No symbol table info available.
#2 0x0000000800a4df29 in abort () from /lib/libc.so.7
No symbol table info available.
#3 0x00000008002d3faf in isc_assertion_failed (file=<optimized out>, line=line@entry=497, type=type@entry=isc_assertiontype_insist, cond=<optimized out>) at assertions.c:47
No locals.
#4 0x00000008002adf17 in isc_nm_destroy (mgr0=mgr0@entry=0x801a39128) at netmgr/netmgr.c:497
counter = <optimized out>
mgr = 0x801024200
references = 0
#5 0x000000000020ce59 in nm_teardown (state=<optimized out>) at doh_test.c:329
i = <optimized out>
nm = 0x801a39120
#6 0x0000000800262613 in ?? () from /usr/local/lib/libcmocka.so.0
No symbol table info available.
#7 0x000000080026054f in _cmocka_run_group_tests () from /usr/local/lib/libcmocka.so.0
No symbol table info available.
#8 0x000000000020cbe3 in main () at doh_test.c:1704
tests_short = {{name = 0x2047c6 "mock_doh_uv_tcp_bind", test_func = 0x20cbf0 <mock_doh_uv_tcp_bind>, setup_func = 0x20cc80 <nm_setup>, teardown_func = 0x20ce40 <nm_teardown>, initial_state = 0x0}, {name = 0x2050e8 "doh_parse_GET_query_string", test_func = 0x20cee0 <doh_parse_GET_query_string>, setup_func = 0x0, teardown_func = 0x0, initial_state = 0x0}, {name = 0x2048c2 "doh_base64url_to_base64", test_func = 0x20dc30 <doh_base64url_to_base64>, setup_func = 0x0, teardown_func = 0x0, initial_state = 0x0}, {name = 0x2044b0 "doh_base64_to_base64url", test_func = 0x20e440 <doh_base64_to_base64url>, setup_func = 0x0, teardown_func = 0x0, initial_state = 0x0}, {name = 0x205773 "doh_noop_POST", test_func = 0x20ec70 <doh_noop_POST>, setup_func = 0x20cc80 <nm_setup>, teardown_func = 0x20ce40 <nm_teardown>, initial_state = 0x0}, {name = 0x2047db "doh_noop_GET", test_func = 0x20ec90 <doh_noop_GET>, setup_func = 0x20cc80 <nm_setup>, teardown_func = 0x20ce40 <nm_teardown>, initial_state = 0x0}, {name = 0x2044c8 "doh_noresponse_POST", test_func = 0x20ecb0 <doh_noresponse_POST>, setup_func = 0x20cc80 <nm_setup>, teardown_func = 0x20ce40 <nm_teardown>, initial_state = 0x0}, {name = 0x2051ca "doh_noresponse_GET", test_func = 0x20ecd0 <doh_noresponse_GET>, setup_func = 0x20cc80 <nm_setup>, teardown_func = 0x20ce40 <nm_teardown>, initial_state = 0x0}}
tests_long = {{name = 0x2047c6 "mock_doh_uv_tcp_bind", test_func = 0x20cbf0 <mock_doh_uv_tcp_bind>, setup_func = 0x20cc80 <nm_setup>, teardown_func = 0x20ce40 <nm_teardown>, initial_state = 0x0}, {name = 0x2050e8 "doh_parse_GET_query_string", test_func = 0x20cee0 <doh_parse_GET_query_string>, setup_func = 0x0, teardown_func = 0x0, initial_state = 0x0}, {name = 0x2048c2 "doh_base64url_to_base64", test_func = 0x20dc30 <doh_base64url_to_base64>, setup_func = 0x0, teardown_func = 0x0, initial_state = 0x0}, {name = 0x2044b0 "doh_base64_to_base64url", test_func = 0x20e440 <doh_base64_to_base64url>, setup_func = 0x0, teardown_func = 0x0, initial_state = 0x0}, {name = 0x205773 "doh_noop_POST", test_func = 0x20ec70 <doh_noop_POST>, setup_func = 0x20cc80 <nm_setup>, teardown_func = 0x20ce40 <nm_teardown>, initial_state = 0x0}, {name = 0x2047db "doh_noop_GET", test_func = 0x20ec90 <doh_noop_GET>, setup_func = 0x20cc80 <nm_setup>, teardown_func = 0x20ce40 <nm_teardown>, initial_state = 0x0}, {name = 0x2044c8 "doh_noresponse_POST", test_func = 0x20ecb0 <doh_noresponse_POST>, setup_func = 0x20cc80 <nm_setup>, teardown_func = 0x20ce40 <nm_teardown>, initial_state = 0x0}, {name = 0x2051ca "doh_noresponse_GET", test_func = 0x20ecd0 <doh_noresponse_GET>, setup_func = 0x20cc80 <nm_setup>, teardown_func = 0x20ce40 <nm_teardown>, initial_state = 0x0}, {name = 0x205103 "doh_recv_one_POST", test_func = 0x20ecf0 <doh_recv_one_POST>, setup_func = 0x20cc80 <nm_setup>, teardown_func = 0x20ce40 <nm_teardown>, initial_state = 0x0}, {name = 0x2043c2 "doh_recv_one_GET", test_func = 0x20ed10 <doh_recv_one_GET>, setup_func = 0x20cc80 <nm_setup>, teardown_func = 0x20ce40 <nm_teardown>, initial_state = 0x0}, {name = 0x20463d "doh_recv_one_POST_TLS", test_func = 0x20ed30 <doh_recv_one_POST_TLS>, setup_func = 0x20cc80 <nm_setup>, teardown_func = 0x20ce40 <nm_teardown>, initial_state = 0x0}, {name = 0x20545f "doh_recv_one_GET_TLS", test_func = 0x20ed50 <doh_recv_one_GET_TLS>, setup_func = 0x20cc80 <nm_setup>, teardown_func = 0x20ce40 <nm_teardown>, initial_state = 0x0}, {name = 0x2048da "doh_recv_two_POST", test_func = 0x20ed70 <doh_recv_two_POST>, setup_func = 0x20cc80 <nm_setup>, teardown_func = 0x20ce40 <nm_teardown>, initial_state = 0x0}, {name = 0x20467f "doh_recv_two_GET", test_func = 0x20ed90 <doh_recv_two_GET>, setup_func = 0x20cc80 <nm_setup>, teardown_func = 0x20ce40 <nm_teardown>, initial_state = 0x0}, {name = 0x205474 "doh_recv_two_POST_TLS", test_func = 0x20edb0 <doh_recv_two_POST_TLS>, setup_func = 0x20cc80 <nm_setup>, teardown_func = 0x20ce40 <nm_teardown>, initial_state = 0x0}, {name = 0x204d63 "doh_recv_two_GET_TLS", test_func = 0x20edd0 <doh_recv_two_GET_TLS>, setup_func = 0x20cc80 <nm_setup>, teardown_func = 0x20ce40 <nm_teardown>, initial_state = 0x0}, {name = 0x20424b "doh_recv_send_GET", test_func = 0x20edf0 <doh_recv_send_GET>, setup_func = 0x20cc80 <nm_setup>, teardown_func = 0x20ce40 <nm_teardown>, initial_state = 0x0}, {name = 0x204d78 "doh_recv_send_POST", test_func = 0x20ee10 <doh_recv_send_POST>, setup_func = 0x20cc80 <nm_setup>, teardown_func = 0x20ce40 <nm_teardown>, initial_state = 0x0}, {name = 0x20531f "doh_recv_send_GET_TLS", test_func = 0x20ee30 <doh_recv_send_GET_TLS>, setup_func = 0x20cc80 <nm_setup>, teardown_func = 0x20ce40 <nm_teardown>, initial_state = 0x0}, {name = 0x205115 "doh_recv_send_POST_TLS", test_func = 0x20ee50 <doh_recv_send_POST_TLS>, setup_func = 0x20cc80 <nm_setup>, teardown_func = 0x20ce40 <nm_teardown>, initial_state = 0x0}, {name = 0x204aa6 "doh_recv_half_send_GET", test_func = 0x20ee70 <doh_recv_half_send_GET>, setup_func = 0x20cc80 <nm_setup>, teardown_func = 0x20ce40 <nm_teardown>, initial_state = 0x0}, {name = 0x2055fd "doh_recv_half_send_POST", test_func = 0x20ee90 <doh_recv_half_send_POST>, setup_func = 0x20cc80 <nm_setup>, teardown_func = 0x20ce40 <nm_teardown>, initial_state = 0x0}, {name = 0x20548a "doh_recv_half_send_GET_TLS", test_func = 0x20eeb0 <doh_recv_half_send_GET_TLS>, setup_func = 0x20cc80 <nm_setup>, teardown_func = 0x20ce40 <nm_teardown>, initial_state = 0x0}, {name = 0x2051dd "doh_recv_half_send_POST_TLS", test_func = 0x20eed0 <doh_recv_half_send_POST_TLS>, setup_func = 0x20cc80 <nm_setup>, teardown_func = 0x20ce40 <nm_teardown>, initial_state = 0x0}, {name = 0x204abd "doh_half_recv_send_GET", test_func = 0x20eef0 <doh_half_recv_send_GET>, setup_func = 0x20cc80 <nm_setup>, teardown_func = 0x20ce40 <nm_teardown>, initial_state = 0x0}, {name = 0x204690 "doh_half_recv_send_POST", test_func = 0x20ef10 <doh_half_recv_send_POST>, setup_func = 0x20cc80 <nm_setup>, teardown_func = 0x20ce40 <nm_teardown>, initial_state = 0x0}, {name = 0x2042ea "doh_half_recv_send_GET_TLS", test_func = 0x20ef30 <doh_half_recv_send_GET_TLS>, setup_func = 0x20cc80 <nm_setup>, teardown_func = 0x20ce40 <nm_teardown>, initial_state = 0x0}, {name = 0x204f07 "doh_half_recv_send_POST_TLS", test_func = 0x20ef50 <doh_half_recv_send_POST_TLS>, setup_func = 0x20cc80 <nm_setup>, teardown_func = 0x20ce40 <nm_teardown>, initial_state = 0x0}, {name = 0x204148 "doh_half_recv_half_send_GET", test_func = 0x20ef70 <doh_half_recv_half_send_GET>, setup_func = 0x20cc80 <nm_setup>, teardown_func = 0x20ce40 <nm_teardown>, initial_state = 0x0}, {name = 0x205512 "doh_half_recv_half_send_POST", test_func = 0x20ef90 <doh_half_recv_half_send_POST>, setup_func = 0x20cc80 <nm_setup>, teardown_func = 0x20ce40 <nm_teardown>, initial_state = 0x0}, {name = 0x2054a5 "doh_half_recv_half_send_GET_TLS", test_func = 0x20efb0 <doh_half_recv_half_send_GET_TLS>, setup_func = 0x20cc80 <nm_setup>, teardown_func = 0x20ce40 <nm_teardown>, initial_state = 0x0}, {name = 0x2053d3 "doh_half_recv_half_send_POST_TLS", test_func = 0x20efd0 <doh_half_recv_half_send_POST_TLS>, setup_func = 0x20cc80 <nm_setup>, teardown_func = 0x20ce40 <nm_teardown>, initial_state = 0x0}}
result = 0
D:doh_test:backtrace from ./core.74014 end
FAIL doh_test (exit status: 134)
```
Core file (1.8 G uncompressed): [core.74014.gz](/uploads/dad9a1a3ec0a480b454dece13a663045/core.74014.gz)May 2021 (9.11.32, 9.11.32-S1, 9.16.16, 9.16.16-S1, 9.17.13)Artem BoldarievArtem Boldarievhttps://gitlab.isc.org/isc-projects/bind9/-/issues/2631keymgr2kasp intermittent test failure Job Failed #16331842021-04-26T13:50:16ZMatthijs Mekkingmatthijs@isc.orgkeymgr2kasp intermittent test failure Job Failed #1633184Job [#1633184](https://gitlab.isc.org/isc-projects/bind9/-/jobs/1633184) failed for dfcef387b89420ffb3163b00717ec6204180ba3c:
```
I:keymgr2kasp:check CDS and CDNSKEY rrset are signed correctly for zone view-rsasha256.kasp (131)
I:keymgr2...Job [#1633184](https://gitlab.isc.org/isc-projects/bind9/-/jobs/1633184) failed for dfcef387b89420ffb3163b00717ec6204180ba3c:
```
I:keymgr2kasp:check CDS and CDNSKEY rrset are signed correctly for zone view-rsasha256.kasp (131)
I:keymgr2kasp:error: missing CDS record in response for key 49765
I:keymgr2kasp:error: CDS RRset not signed with key 49765
I:keymgr2kasp:error: missing CDNSKEY record in response for key 49765
I:keymgr2kasp:error: CDNSKEY RRset not signed with key 49765
I:keymgr2kasp:failed
```May 2021 (9.11.32, 9.11.32-S1, 9.16.16, 9.16.16-S1, 9.17.13)Matthijs Mekkingmatthijs@isc.orgMatthijs Mekkingmatthijs@isc.orghttps://gitlab.isc.org/isc-projects/bind9/-/issues/2630TSAN error in xfrin.c2021-04-20T12:13:37ZMark AndrewsTSAN error in xfrin.cJob [#1632017](https://gitlab.isc.org/isc-projects/bind9/-/jobs/1632017) failed for a0075ea9dd301707ec115c254d8f493d42a0c78f:
Pre netmgr xfrin was task constrained, this is no longer true.
```
WARNING: ThreadSanitizer: data race
Rea...Job [#1632017](https://gitlab.isc.org/isc-projects/bind9/-/jobs/1632017) failed for a0075ea9dd301707ec115c254d8f493d42a0c78f:
Pre netmgr xfrin was task constrained, this is no longer true.
```
WARNING: ThreadSanitizer: data race
Read of size 8 at 0x000000000001 by thread T1:
#0 xfrin_fail lib/dns/xfrin.c:808
#1 xfrin_recv_done lib/dns/xfrin.c:1485
#2 isc__nm_async_readcb netmgr/netmgr.c:2411
#3 process_netievent netmgr/netmgr.c:743
#4 process_queue netmgr/netmgr.c:766
#5 process_normal_queue netmgr/netmgr.c:652
#6 process_queues netmgr/netmgr.c:660
#7 async_cb netmgr/netmgr.c:618
#8 <null> <null>
#9 isc__trampoline_run lib/isc/trampoline.c:184
#10 <null> <null>
Previous write of size 8 at 0x000000000001 by thread T2:
#0 xfrin_fail lib/dns/xfrin.c:810
#1 dns_xfrin_shutdown lib/dns/xfrin.c:725
#2 zone_shutdown lib/dns/zone.c:14648
#3 dispatch lib/isc/task.c:1153
#4 run lib/isc/task.c:1345
#5 isc__trampoline_run lib/isc/trampoline.c:184
#6 <null> <null>
Location is heap block of size 1352 at 0x000000000015 allocated by thread T3:
#0 malloc <null>
#1 default_memalloc lib/isc/mem.c:411
#2 mem_get lib/isc/mem.c:343
#3 mem_allocateunlocked lib/isc/mem.c:918
#4 isc__mem_allocate lib/isc/mem.c:935
#5 isc__mem_get lib/isc/mem.c:740
#6 xfrin_create lib/dns/xfrin.c:825
#7 dns_xfrin_create lib/dns/xfrin.c:679
#8 got_transfer_quota lib/dns/zone.c:17798
#9 dispatch lib/isc/task.c:1153
#10 run lib/isc/task.c:1345
#11 isc__trampoline_run lib/isc/trampoline.c:184
#12 <null> <null>
Thread T1 (running) created by main thread at:
#0 pthread_create <null>
#1 isc_thread_create pthreads/thread.c:79
#2 isc_nm_start netmgr/netmgr.c:293
#3 create_managers bin/named/main.c:954
#4 setup bin/named/main.c:1268
#5 main bin/named/main.c:1559
Thread T2 (running) created by main thread at:
#0 pthread_create <null>
#1 isc_thread_create pthreads/thread.c:79
#2 isc_taskmgr_create lib/isc/task.c:1435
#3 create_managers bin/named/main.c:960
#4 setup bin/named/main.c:1268
#5 main bin/named/main.c:1559
Thread T3 (running) created by main thread at:
#0 pthread_create <null>
#1 isc_thread_create pthreads/thread.c:79
#2 isc_taskmgr_create lib/isc/task.c:1435
#3 create_managers bin/named/main.c:960
#4 setup bin/named/main.c:1268
#5 main bin/named/main.c:1559
SUMMARY: ThreadSanitizer: data race lib/dns/xfrin.c:808 in xfrin_fail
```
also
```
WARNING: ThreadSanitizer: data race
Write of size 1 at 0x000000000001 by thread T1:
#0 xfrin_fail lib/dns/xfrin.c:812
#1 dns_xfrin_shutdown lib/dns/xfrin.c:725
#2 zone_shutdown lib/dns/zone.c:14648
#3 dispatch lib/isc/task.c:1153
#4 run lib/isc/task.c:1345
#5 isc__trampoline_run lib/isc/trampoline.c:184
#6 <null> <null>
Previous read of size 1 at 0x000000000001 by thread T2:
#0 xfrin_recv_done lib/dns/xfrin.c:1215
#1 isc__nm_async_readcb netmgr/netmgr.c:2411
#2 process_netievent netmgr/netmgr.c:743
#3 process_queue netmgr/netmgr.c:766
#4 process_normal_queue netmgr/netmgr.c:652
#5 process_queues netmgr/netmgr.c:660
#6 async_cb netmgr/netmgr.c:618
#7 <null> <null>
#8 isc__trampoline_run lib/isc/trampoline.c:184
#9 <null> <null>
Thread T1 (running) created by main thread at:
#0 pthread_create <null>
#1 isc_thread_create pthreads/thread.c:79
#2 isc_taskmgr_create lib/isc/task.c:1435
#3 create_managers bin/named/main.c:960
#4 setup bin/named/main.c:1268
#5 main bin/named/main.c:1559
Thread T2 (running) created by main thread at:
#0 pthread_create <null>
#1 isc_thread_create pthreads/thread.c:79
#2 isc_nm_start netmgr/netmgr.c:293
#3 create_managers bin/named/main.c:954
#4 setup bin/named/main.c:1268
#5 main bin/named/main.c:1559
SUMMARY: ThreadSanitizer: data race lib/dns/xfrin.c:812 in xfrin_fail
```May 2021 (9.11.32, 9.11.32-S1, 9.16.16, 9.16.16-S1, 9.17.13)Ondřej SurýOndřej Surýhttps://gitlab.isc.org/isc-projects/bind9/-/issues/2629man pages aren't installed when building 9.17.x2021-05-25T09:34:13ZChuck Stearnsman pages aren't installed when building 9.17.xThis has been reported by a customer, and I've been able to duplicate the behavior on my system (MacBook Pro M1). There have been reported ways to get the man pages to build (using sphinx-build, or running make doc), but I was unable to ...This has been reported by a customer, and I've been able to duplicate the behavior on my system (MacBook Pro M1). There have been reported ways to get the man pages to build (using sphinx-build, or running make doc), but I was unable to get either of these to work. I was finally able to build and install manpages by descending into doc/man at the source root and running `make` and `make install` there.June 2021 (9.11.33, 9.11.33-S1, 9.16.17/9.16.18, 9.16.17-S1/9.16.18-S1, 9.17.14/9.17.15)Michal NowakMichal Nowakhttps://gitlab.isc.org/isc-projects/bind9/-/issues/2628Key generation should check for key id conflicts with newly created keys too2021-04-26T13:50:18ZMatthijs Mekkingmatthijs@isc.orgKey generation should check for key id conflicts with newly created keys tooJob [#1632735](https://gitlab.isc.org/isc-private/bind9/-/jobs/1632735) failed for 0ebacc6327dc87b9ee65a911444b256782fee26c:
```
I:kasp:check number of keys for zone ecdsa256.kasp in dir ns3 (203)
I:kasp:error: bad number of key files (2...Job [#1632735](https://gitlab.isc.org/isc-private/bind9/-/jobs/1632735) failed for 0ebacc6327dc87b9ee65a911444b256782fee26c:
```
I:kasp:check number of keys for zone ecdsa256.kasp in dir ns3 (203)
I:kasp:error: bad number of key files (2) for zone ecdsa256.kasp (expected 3)
I:kasp:check key id 26891
I:kasp:check key id 22631
I:kasp:KEY1 ID 22631
I:kasp:KEY2 ID no
I:kasp:error: No KEY2 found for zone ecdsa256.kasp
I:kasp:KEY3 ID 26891
I:kasp:failed
```
This test creates two new keys with the same key ID. The keymgr checks for conflicts, but only with already existing keys.May 2021 (9.11.32, 9.11.32-S1, 9.16.16, 9.16.16-S1, 9.17.13)Matthijs Mekkingmatthijs@isc.orgMatthijs Mekkingmatthijs@isc.orghttps://gitlab.isc.org/isc-projects/bind9/-/issues/2627tlsstream.c: warning: comparison of integer expressions of different signedness2021-05-11T07:08:12ZMichal Nowaktlsstream.c: warning: comparison of integer expressions of different signednessCompiling `main` (b64af491bf7eb363cf335c688a1f77170b0fcd94) on OpenIndiana with GCC 7.5 produces the following warning:
```
netmgr/tlsstream.c: In function 'tls_send_outgoing':
netmgr/tlsstream.c:237:14: warning: comparison of integer ex...Compiling `main` (b64af491bf7eb363cf335c688a1f77170b0fcd94) on OpenIndiana with GCC 7.5 produces the following warning:
```
netmgr/tlsstream.c: In function 'tls_send_outgoing':
netmgr/tlsstream.c:237:14: warning: comparison of integer expressions of different signedness: 'int' and 'unsigned int' [-Wsign-compare]
237 | if (pending > TLS_BUF_SIZE) {
| ^
```May 2021 (9.11.32, 9.11.32-S1, 9.16.16, 9.16.16-S1, 9.17.13)Diego dos Santos FronzaDiego dos Santos Fronzahttps://gitlab.isc.org/isc-projects/bind9/-/issues/2626Deadlock with concurrent `rndc addzone`/`rndc delzone` commands2021-07-16T05:19:12ZBenjamin GentilDeadlock with concurrent `rndc addzone`/`rndc delzone` commands### Summary
A deadlock can happens between concurrent `rndc delzone` and `rndc addzone` commands (on different zones) making the named process and every following `rndc` commands stuck.
### BIND version used
bind9 debian buster-backpo...### Summary
A deadlock can happens between concurrent `rndc delzone` and `rndc addzone` commands (on different zones) making the named process and every following `rndc` commands stuck.
### BIND version used
bind9 debian buster-backports package 1:9.16.13-1~bpo10+1
```
BIND 9.16.13-Debian (Stable Release) <id:072e758>
running on Linux x86_64 5.11.8-200.fc33.x86_64 #1 SMP Mon Mar 22 01:35:01 UTC 2021
built by make with '--build=x86_64-linux-gnu' '--prefix=/usr' '--includedir=/usr/include' '--mandir=/usr/share/man' '--infodir=/usr/share/info' '--sysconfdir=/etc' '--localstatedir=/var' '--disable-silent-rules' '--libdir=/usr/lib/x86_64-linux-gnu' '--runstatedir=/run' '--disable-maintainer-mode' '--disable-dependency-tracking' '--libdir=/usr/lib/x86_64-linux-gnu' '--sysconfdir=/etc/bind' '--with-python=python3' '--localstatedir=/' '--enable-threads' '--enable-largefile' '--with-libtool' '--enable-shared' '--enable-static' '--with-gost=no' '--with-openssl=/usr' '--with-gssapi=/usr' '--with-libidn2' '--with-json-c' '--with-lmdb=/usr' '--with-gnu-ld' '--with-maxminddb' '--with-atf=no' '--enable-ipv6' '--enable-rrl' '--enable-filter-aaaa' '--disable-native-pkcs11' '--enable-dnstap' 'build_alias=x86_64-linux-gnu' 'CFLAGS=-g -O2 -fdebug-prefix-map=/build/bind9-xJGMKz/bind9-9.16.13=. -fstack-protector-strong -Wformat -Werror=format-security -fno-strict-aliasing -fno-delete-null-pointer-checks -DNO_VERSION_DATE -DDIG_SIGCHASE' 'LDFLAGS=-Wl,-z,relro -Wl,-z,now' 'CPPFLAGS=-Wdate-time -D_FORTIFY_SOURCE=2'
compiled by GCC 8.3.0
compiled with OpenSSL version: OpenSSL 1.1.1d 10 Sep 2019
linked to OpenSSL version: OpenSSL 1.1.1d 10 Sep 2019
compiled with libuv version: 1.24.1
linked to libuv version: 1.24.1
compiled with libxml2 version: 2.9.4
linked to libxml2 version: 20904
compiled with json-c version: 0.12.1
linked to json-c version: 0.12.1
compiled with zlib version: 1.2.11
linked to zlib version: 1.2.11
linked to maxminddb version: 1.3.2
compiled with protobuf-c version: 1.3.1
linked to protobuf-c version: 1.3.1
threads support is enabled
default paths:
named configuration: /etc/bind/named.conf
rndc configuration: /etc/bind/rndc.conf
DNSSEC root key: /etc/bind/bind.keys
nsupdate session key: //run/named/session.key
named PID file: //run/named/named.pid
named lock file: //run/named/named.lock
geoip-directory: /usr/share/GeoIP
```
Has been also reproduced on a 9.11.25 build, but not on the debian buster version (1:9.11.5.P4+dfsg-5.1+deb10u3)
### Steps to reproduce
The issue can be triggered by running many `rndc addzone` & `rndc delzone` in parallel.
A repository with a POC is available here: https://github.com/bengentil/bind-deadlock
### What is the current *bug* behavior?
When the bug happens the named process is deadlocked and all `rndc` commands are stuck.
### What is the expected *correct* behavior?
The expected behavior is to have all `rndc` commands to be executed to completion without any deadlock.
### Relevant configuration files
I don't have any specific configuration in place to reproduce this issue, as far as I know this issue is not avoidable by configuration.
### Relevant logs and/or screenshots
An extract of a gdb backtrace of the deadlocked process (only the 2 relevant threads):
```
Thread 16 (Thread 0x7f549b6bf700 (LWP 58)):
#0 0x00007f54a5a9e00c in pthread_cond_wait@@GLIBC_2.3.2 () from /lib/x86_64-linux-gnu/libpthread.so.0
No symbol table info available.
#1 0x00007f54a5f560a9 in isc_task_beginexclusive (task0=<optimized out>) at task.c:1662
task = <optimized out>
manager = 0x7f54a02ba010
#2 0x000055a0f169bf99 in do_addzone (zoneconf=<optimized out>, text=0x7f549b6bebc8, redirect=false, zoneobj=0x7f5495d48a38, name=0x7f549b6be830, view=0x7f5490bc1ea0, cfg=0x7f5495d4e048, server=0x7f54a02c0010) at ./server.c:13398
tresult = <optimized out>
zone = 0x0
dbi = 2428247712
result = 0
txn = 0x0
result = <optimized out>
tresult = <optimized out>
zone = <optimized out>
txn = <optimized out>
dbi = <optimized out>
dbp = <optimized out>
#3 named_server_changezone (server=0x7f54a02c0010, command=<optimized out>, text=text@entry=0x7f549b6bebc8) at ./server.c:13800
result = <optimized out>
addzone = true
redirect = false
cfg = 0x7f5495d4e048
zoneconf = 0x7f5495d48b00
zoneobj = 0x7f5495d48a38
zonename = 0x7f5458008430 "test1.local"
view = 0x7f5490bc1ea0
buf = {magic = 1114990113, base = 0x7f5458008430, length = 11, used = 11, current = 11, active = 0, link = {prev = 0xffffffffffffffff, next = 0xffffffffffffffff}, mctx = 0x0, autore = false}
fname = {name = {magic = 1145983854, ndata = 0x7f549b6be940 "\005test1\005local", length = 13, labels = 3, attributes = 1, offsets = 0x7f549b6be880 "", buffer = 0x7f549b6be900, link = {prev = 0xffffffffffffffff, next = 0xffffffffffffffff}, list = {head = 0x0, tail = 0x0}}, offsets = "\000\006\f\000\000\000\000\000\240\307Z\245T\177\000\000\000\200\255\373\320\224\004\255\200\314\005XT\177\000\000\200\314\005XT\177\000\000\200\314\005XT\177\000\000\200\314\005XT\177\000\000\000E\027^\345\027Y\223\310\353k\233T\177\000\000\350\203,\240T\177\000\000\000\352k\233T\177\000\000\320\351k\233T\177\000\000@\366+\240T\177\000\000\277\306X\245T\177\000\000 \000\000\000\060\000\000\000\320\351k\233T\177\000", buffer = {magic = 1114990113, base = 0x7f549b6be940, length = 255, used = 13, current = 0, active = 0, link = {prev = 0xffffffffffffffff, next = 0xffffffffffffffff}, mctx = 0x0, autore = false}, data = "\005test1\005local\000\177\000\000\000\020\000\000\000\000\000\000\000E\027^\345\027Y\223\a\000\000\000\000\000\000\000\310\353k\233T\177\000\000\000\000\000\000\000\000\000\000\270\352k\233T\177\000\000p_\316\225T\177\000\000\300!\371\245T\177\000\000\000\000\000\000\000\000\000\000\242\347\362\245T\177\000\000\260\351k\233T\177\000\000\260\216\025\243T\177\000\000\060\000\000\000\060\000\000\000\220\352k\233T\177\000\000\320\351k\233T\177\000\000\000E\027^\345\027Y\223buffer-0x7f549\000\000\223\000\000\000\000\000\000\000\002\000\000\000\000\000\000\000w_\316\225T\177\000\000\260E\005XT\177\000\000\002\000\000\000\000\000\000\000"...}
dnsname = 0x7f549b6be830
#4 0x000055a0f167d7d7 in named_control_docommand (message=<optimized out>, readonly=<optimized out>, text=text@entry=0x7f549b6bebc8) at control.c:209
data = <optimized out>
cmdline = 0x7f54580545b0 "addzone test1.local {type master; file \"/var/cache/bind/test1.local.db\"; auto-dnssec maintain; inline-signing yes; key-directory \"/var/cache/bind/keys\";};"
command = 0x7f5495ce5f70 "addzone"
result = 0
log_level = <optimized out>
src = {magic = 1114990113, base = 0x7f54580545b0, length = 154, used = 154, current = 8, active = 0, link = {prev = 0xffffffffffffffff, next = 0xffffffffffffffff}, mctx = 0x0, autore = false}
lex = 0x7f54a02c83e8
#5 0x000055a0f16809f3 in control_recvmessage (task=0x7f5495d25010, event=<optimized out>) at controlconf.c:476
conn = 0x7f5495d43e50
listener = 0x7f5495d4d120
key = 0x7f54a02bf640
request = 0x7f5458005240
response = 0x0
algorithm = 163
secret = {rstart = 0x7f54a315bab0 "\342\061\016`\001\201\065\067\242U\313\033|\321\334\350\303\335\213OX\252u\f\210\033v\271K\221x\342\020\273\025\243T\177", rend = 0x7f54a315bad0 "\020\273\025\243T\177"}
now = 1617996781
b = <optimized out>
r = {base = 0x7f54a1ec4f0d ";", length = 2716618509}
text = 0x7f544c046db0
result = <optimized out>
eresult = <optimized out>
_ctrl = 0x7f54580540e0
sent = 1617996781
exp = 1617996841
nonce = 459112386
data = 0x0
#6 0x00007f54a5f53e4b in dispatch (threadid=<optimized out>, manager=0x7f54a02ba010) at task.c:1153
dispatch_count = 24
done = false
finished = false
requeue = false
event = 0x7f5495d43ed0
task = 0x7f5495d25010
task = <optimized out>
__atomic_load_ptr = <optimized out>
__atomic_load_tmp = <optimized out>
__atomic_load_ptr = <optimized out>
__atomic_load_tmp = <optimized out>
__atomic_load_ptr = <optimized out>
__atomic_load_tmp = <optimized out>
__atomic_load_ptr = <optimized out>
__atomic_load_tmp = <optimized out>
__atomic_load_ptr = <optimized out>
__atomic_load_tmp = <optimized out>
__atomic_load_ptr = <optimized out>
__atomic_load_tmp = <optimized out>
__atomic_load_ptr = <optimized out>
__atomic_load_tmp = <optimized out>
__atomic_load_ptr = <optimized out>
__atomic_load_tmp = <optimized out>
dispatch_count = <optimized out>
done = <optimized out>
requeue = <optimized out>
finished = <optimized out>
event = <optimized out>
__atomic_load_ptr = <optimized out>
__atomic_load_tmp = <optimized out>
__atomic_load_ptr = <optimized out>
__atomic_load_tmp = <optimized out>
was_idle = <optimized out>
__atomic_load_ptr = <optimized out>
__atomic_load_tmp = <optimized out>
__atomic_load_ptr = <optimized out>
__atomic_load_tmp = <optimized out>
__atomic_load_ptr = <optimized out>
__atomic_load_tmp = <optimized out>
__atomic_load_ptr = <optimized out>
__atomic_load_tmp = <optimized out>
__atomic_load_ptr = <optimized out>
__atomic_load_tmp = <optimized out>
__atomic_load_ptr = <optimized out>
__atomic_load_tmp = <optimized out>
empty = <optimized out>
i = <optimized out>
__atomic_store_ptr = <optimized out>
__atomic_store_tmp = <optimized out>
__atomic_load_ptr = <optimized out>
__atomic_load_tmp = <optimized out>
__atomic_load_ptr = <optimized out>
__atomic_load_tmp = <optimized out>
#7 run (queuep=<optimized out>) at task.c:1345
tq = <optimized out>
manager = 0x7f54a02ba010
threadid = <optimized out>
#8 0x00007f54a5f5a282 in isc__trampoline_run (arg=0x55a0f2d9d970) at trampoline.c:191
trampoline = 0x55a0f2d9d970
result = <optimized out>
#9 0x00007f54a5a97fa3 in start_thread () from /lib/x86_64-linux-gnu/libpthread.so.0
No symbol table info available.
#10 0x00007f54a562d4cf in clone () from /lib/x86_64-linux-gnu/libc.so.6
No symbol table info available.
Thread 15 (Thread 0x7f549bec0700 (LWP 57)):
#0 0x00007f54a5aa129c in __lll_lock_wait () from /lib/x86_64-linux-gnu/libpthread.so.0
No symbol table info available.
#1 0x00007f54a5a9a87a in pthread_mutex_lock () from /lib/x86_64-linux-gnu/libpthread.so.0
No symbol table info available.
#2 0x000055a0f168caef in rmzone (task=<optimized out>, event=<optimized out>) at ./server.c:13890
dz = 0x7f5495d34ff0
zone = 0x7f5464008d10
raw = 0x0
mayberaw = <optimized out>
zonename = "test2.local", '\000' <repeats 17 times>, "T\177", '\000' <repeats 26 times>, "\377\377\377\377\377\377\377\377RSND\377\377\377\377\000\000\000\000\000\000\000\000", '\377' <repeats 16 times>, '\000' <repeats 20 times>, "\377\377\377\377", '\000' <repeats 72 times>, "X\002\000\000\000\000\000\000"...
view = 0x7f5490bc1ea0
cfg = <optimized out>
dbp = 0x0
added = true
result = <optimized out>
txn = 0x0
dbi = 4294967295
#3 0x00007f54a5f53e4b in dispatch (threadid=<optimized out>, manager=0x7f54a02ba010) at task.c:1153
dispatch_count = 0
done = false
finished = false
requeue = false
event = 0x7f549559be48
task = 0x7f5495d25be0
task = <optimized out>
__atomic_load_ptr = <optimized out>
__atomic_load_tmp = <optimized out>
__atomic_load_ptr = <optimized out>
__atomic_load_tmp = <optimized out>
__atomic_load_ptr = <optimized out>
__atomic_load_tmp = <optimized out>
__atomic_load_ptr = <optimized out>
__atomic_load_tmp = <optimized out>
__atomic_load_ptr = <optimized out>
__atomic_load_tmp = <optimized out>
__atomic_load_ptr = <optimized out>
__atomic_load_tmp = <optimized out>
__atomic_load_ptr = <optimized out>
__atomic_load_tmp = <optimized out>
__atomic_load_ptr = <optimized out>
__atomic_load_tmp = <optimized out>
dispatch_count = <optimized out>
done = <optimized out>
requeue = <optimized out>
finished = <optimized out>
event = <optimized out>
__atomic_load_ptr = <optimized out>
__atomic_load_tmp = <optimized out>
__atomic_load_ptr = <optimized out>
__atomic_load_tmp = <optimized out>
was_idle = <optimized out>
__atomic_load_ptr = <optimized out>
__atomic_load_tmp = <optimized out>
__atomic_load_ptr = <optimized out>
__atomic_load_tmp = <optimized out>
__atomic_load_ptr = <optimized out>
__atomic_load_tmp = <optimized out>
__atomic_load_ptr = <optimized out>
__atomic_load_tmp = <optimized out>
__atomic_load_ptr = <optimized out>
__atomic_load_tmp = <optimized out>
__atomic_load_ptr = <optimized out>
__atomic_load_tmp = <optimized out>
empty = <optimized out>
i = <optimized out>
__atomic_store_ptr = <optimized out>
__atomic_store_tmp = <optimized out>
__atomic_load_ptr = <optimized out>
__atomic_load_tmp = <optimized out>
__atomic_load_ptr = <optimized out>
__atomic_load_tmp = <optimized out>
#4 run (queuep=<optimized out>) at task.c:1345
tq = <optimized out>
manager = 0x7f54a02ba010
threadid = <optimized out>
#5 0x00007f54a5f5a282 in isc__trampoline_run (arg=0x55a0f2d9d7e0) at trampoline.c:191
trampoline = 0x55a0f2d9d7e0
result = <optimized out>
#6 0x00007f54a5a97fa3 in start_thread () from /lib/x86_64-linux-gnu/libpthread.so.0
No symbol table info available.
#7 0x00007f54a562d4cf in clone () from /lib/x86_64-linux-gnu/libc.so.6
No symbol table info available.
```
The corresponding relevant logs:
```
Apr 9 19:33:01 f402d8b027a0 named[42]: received control channel command 'delzone test2.local'
Apr 9 19:33:01 f402d8b027a0 named[42]: zone test2.local scheduled for removal via delzone
Apr 9 19:33:01 f402d8b027a0 named[42]: received control channel command 'addzone test1.local {type master; file "/var/cache/bind/test1.local.db"; auto-dnssec maintain; inline-signing yes; key-directory "/var/cache/bind/keys";};'
Apr 9 19:33:01 f402d8b027a0 named[42]: deleting zone test2.local in view _default via delzone
```
We can see that `rndc addzone test1.local [...]` has been executed during an already running `rndc delzone test2.local` and both threads are now waiting.
The thread 15/LWP 57 (delzone) is waiting for a lock owned by thread 16/LWP 58 (addzone)
```
(gdb) thread 15
[Switching to thread 15 (Thread 0x7f549bec0700 (LWP 57))]
#0 0x00007f54a5aa129c in __lll_lock_wait () from /lib/x86_64-linux-gnu/libpthread.so.0
(gdb) frame 2
#2 0x000055a0f168caef in rmzone (task=<optimized out>, event=<optimized out>) at ./server.c:13890
13890 in ./server.c
(gdb) p *(&view->new_zone_lock->__data->__owner)
$9 = 58
```
isc_task_beginexclusive waits while this is true: `manager->halted + 1 < manager->workers`
```
(gdb) thread 16
[Switching to thread 16 (Thread 0x7f549b6bf700 (LWP 58))]
#0 0x00007f54a5a9e00c in pthread_cond_wait@@GLIBC_2.3.2 () from /lib/x86_64-linux-gnu/libpthread.so.0
(gdb) frame 1
#1 0x00007f54a5f560a9 in isc_task_beginexclusive (task0=<optimized out>) at task.c:1662
1662 task.c: No such file or directory.
(gdb) p manager->halted
$10 = 6
(gdb) p manager->workers
$11 = 8
```
### Observations
The rmzone relevant code is:
* [server.c:13890](https://gitlab.isc.org/isc-projects/bind9/-/blob/v9_16_13/bin/named/server.c#L13874)
```
13855 rmzone(isc_task_t *task, isc_event_t *event) {
[...]
13888 #ifdef HAVE_LMDB
13889 /* Make sure we can open the NZD database */
->13890 LOCK(&view->new_zone_lock);
```
The addzone relevant code is:
* [server.c:13350](https://gitlab.isc.org/isc-projects/bind9/-/blob/v9_16_13/bin/named/server.c#L13382)
```
13337 do_addzone(named_server_t *server, ns_cfgctx_t *cfg, dns_view_t *view,
13338 dns_name_t *name, cfg_obj_t *zoneconf, const cfg_obj_t *zoneobj,
13339 bool redirect, isc_buffer_t **text) {
[...]
13350 LOCK(&view->new_zone_lock);
[...]
13387 /* Make sure we can open the NZD database */
13388 result = nzd_writable(view);
13389 if (result != ISC_R_SUCCESS) {
13390 TCHECK(putstr(text, "unable to open NZD database for '"));
13391 TCHECK(putstr(text, view->new_zone_db));
13392 TCHECK(putstr(text, "'"));
13393 result = ISC_R_FAILURE;
13394 goto cleanup;
13395 }
13396 #endif /* HAVE_LMDB */
13397
->13398 result = isc_task_beginexclusive(server->task);
```
* [task.c:1662](https://gitlab.isc.org/isc-projects/bind9/-/blob/v9_16_13/lib/isc/task.c#L1662)
```
1634 isc_task_beginexclusive(isc_task_t *task0) {
[...]
1660 while (manager->halted + 1 < manager->workers) {
1661 wake_all_queues(manager);
->1662 WAIT(&manager->halt_cond, &manager->halt_lock);
1663 }
```
My understanding is that the `rmzone` is executed between the `LOCK(&view->new_zone_lock)` and the `isc_task_beginexclusive` in `do_addzone` resulting in:
* `do_addzone` waits for other workers to stop (ie. waits for `rmzone` to stop)
* `rmzone` waits for the `view->new_zone_lock` locked by `do_addzone`
* `do_addzone` sees always 2 workers and the `view->new_zone_lock` is never unlockedMay 2021 (9.11.32, 9.11.32-S1, 9.16.16, 9.16.16-S1, 9.17.13)Diego dos Santos FronzaDiego dos Santos Fronzahttps://gitlab.isc.org/isc-projects/bind9/-/issues/2625The shutdown system test is not capturing enough2021-04-23T05:16:04ZMark AndrewsThe shutdown system test is not capturing enoughJob [#1631511](https://gitlab.isc.org/isc-projects/bind9/-/jobs/1631511) failed for 0a08de65d7e1fbf2d6813327aa73b1c587dec053:
The shutdown system test in rndc mode is just asserting without leaving enough forensic evidence to continue. ...Job [#1631511](https://gitlab.isc.org/isc-projects/bind9/-/jobs/1631511) failed for 0a08de65d7e1fbf2d6813327aa73b1c587dec053:
The shutdown system test in rndc mode is just asserting without leaving enough forensic evidence to continue. named.run ends with the following which could indicate that named is deadlocked but without a core we can't know.
```
12-Apr-2021 02:03:53.895 fctx 0x7b6800240000(uoilpwjnw.test/A): doshutdown
12-Apr-2021 02:03:53.895 fctx 0x7b6800240000(uoilpwjnw.test/A): stopqueries
12-Apr-2021 02:03:53.895 fctx 0x7b6800240000(uoilpwjnw.test/A): cancelqueries
12-Apr-2021 02:03:53.895 dns_adb_destroyfind on find 0x7b4000058c00
12-Apr-2021 02:03:53.895 fctx 0x7b6800240000(uoilpwjnw.test/A): unlink
12-Apr-2021 02:03:53.895 fctx 0x7b6800240000(uoilpwjnw.test/A): destroy
12-Apr-2021 02:03:53.907 allocate new control connection
12-Apr-2021 02:03:53.907 allocate new control connection
12-Apr-2021 02:03:53.907 received control channel command 'status'
12-Apr-2021 02:03:53.907 received control channel command 'status'
12-Apr-2021 02:03:53.907 freeing control connection
12-Apr-2021 02:03:53.907 freeing control connection
12-Apr-2021 02:03:53.911 allocate new control connection
12-Apr-2021 02:03:53.911 received control channel command 'status'
12-Apr-2021 02:03:53.911 freeing control connection
```May 2021 (9.11.32, 9.11.32-S1, 9.16.16, 9.16.16-S1, 9.17.13)