]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
Wait for slow zone transfer to complete before ending test
authorMark Andrews <marka@isc.org>
Fri, 11 Aug 2023 03:28:05 +0000 (13:28 +1000)
committerAram Sargsyan <aram@isc.org>
Fri, 22 Sep 2023 08:52:13 +0000 (08:52 +0000)
This allows the statistics channel to be viewed in a browser while
the transfer is in progress.  Also set the transfer format to
one-answer to extend the amount of time the re-transfer takes.

When running the statschannel test on its own, use
<http://10.53.0.3:5304/xml/v3/xfrins> to see the output.

Note: the port is subject to future change.

bin/tests/system/statschannel/ns1/named.conf.in
bin/tests/system/statschannel/tests.sh

index 52fd9fd855e2e69823ac195a2f07f5a480eb498d..52e8a7339f458daddf2062dee4df03a5503dd2ef 100644 (file)
@@ -37,6 +37,10 @@ controls {
        inet 10.53.0.1 port @CONTROLPORT@ allow { any; } keys { rndc_key; };
 };
 
+server 10.53.0.3 {
+       transfer-format one-answer;
+};
+
 zone "example" {
        type primary;
        file "example.db";
index c48d0ebffaeffb7b7539e5fdf941ab0cb9f4e5d3..6772ac8d1a60bff30c137e421762dc25586cc0a6 100644 (file)
@@ -721,5 +721,12 @@ if [ $ret != 0 ]; then echo_i "failed"; fi
 status=$((status + ret))
 n=$((n + 1))
 
+echo_i "Wait for slow zone transfer to complete ($n)"
+ret=0
+wait_for_log 20 "zone example/IN: zone transfer finished: success" ns3/named.run || ret=1
+if [ $ret != 0 ]; then echo_i "failed"; fi
+status=$((status + ret))
+n=$((n + 1))
+
 echo_i "exit status: $status"
 [ $status -eq 0 ] || exit 1