+3617. [bug] Named was failing to answer queries during
+ "rndc reload" [RT #34098]
+
3616. [bug] Change #3613 was incomplete. [RT #34177]
3615. [cleanup] "configure" now finishes by printing a summary
}
static isc_result_t
-load_zones(ns_server_t *server) {
+load_zones(ns_server_t *server, isc_boolean_t init) {
isc_result_t result;
dns_view_t *view;
ns_zoneload_t *zl;
if (refs == 0) {
isc_refcount_destroy(&zl->refs);
isc_mem_put(server->mctx, zl, sizeof (*zl));
- } else {
+ } else if (init) {
/*
* Place the task manager into privileged mode. This
* ensures that after we leave task-exclusive mode, no
* other tasks will be able to run except for the ones
- * that are loading zones.
+ * that are loading zones. (This should only be done during
+ * the initial server setup; it isn't necessary during
+ * a reload.)
*/
isc_taskmgr_setmode(ns_g_taskmgr, isc_taskmgrmode_privileged);
}
isc_hash_init();
- CHECKFATAL(load_zones(server), "loading zones");
+ CHECKFATAL(load_zones(server, ISC_TRUE), "loading zones");
}
void
isc_result_t result;
CHECK(loadconfig(server));
- result = load_zones(server);
+ result = load_zones(server, ISC_FALSE);
if (result == ISC_R_SUCCESS)
isc_log_write(ns_g_lctx, NS_LOGCATEGORY_GENERAL,
NS_LOGMODULE_SERVER, ISC_LOG_INFO,
sed -e 's/0 0 0 0 0/1 0 0 0 0/' -e 's/\.1$/.2/' < ns2/redirect.db.in > ns2/redirect.db
$RNDC -c ../common/rndc.conf -s 10.53.0.2 -p 9953 reload > rndc.out || ret=1
sed 's/^/I:ns2 /' rndc.out
-$DIG $DIGOPTS +short @10.53.0.2 soa example.nil > dig.out.ns1.test$n || ret=1
-set -- `cat dig.out.ns1.test$n`
-[ $3 = 1 ] || ret=1
-$DIG $DIGOPTS nonexist. @10.53.0.2 -b 10.53.0.2 a > dig.out.ns2.test$n || ret=1
-grep "status: NOERROR" dig.out.ns2.test$n > /dev/null || ret=1
-grep "100.100.100.2" dig.out.ns2.test$n > /dev/null || ret=1
+for i in 1 2 3 4 5 6 7 8 9; do
+ tmp=0
+ $DIG $DIGOPTS +short @10.53.0.2 soa example.nil > dig.out.ns1.test$n || tmp=1
+ set -- `cat dig.out.ns1.test$n`
+ [ $3 = 1 ] || tmp=1
+ $DIG $DIGOPTS nonexist. @10.53.0.2 -b 10.53.0.2 a > dig.out.ns2.test$n || tmp=1
+ grep "status: NOERROR" dig.out.ns2.test$n > /dev/null || tmp=1
+ grep "100.100.100.2" dig.out.ns2.test$n > /dev/null || tmp=1
+ [ $tmp -eq 0 ] && break
+ sleep 1
+done
+[ $tmp -eq 1 ] && ret=1
n=`expr $n + 1`
if [ $ret != 0 ]; then echo "I:failed"; fi
status=`expr $status + $ret`