]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
address a possible notify test failure
authorEvan Hunt <each@isc.org>
Mon, 26 Feb 2018 03:44:19 +0000 (19:44 -0800)
committerEvan Hunt <each@isc.org>
Tue, 6 Mar 2018 19:46:26 +0000 (11:46 -0800)
- wait for the transfer completion message to apear in the log instead
  of the notify message. this ensures we don't check for the presense of
  transfered records during the time between the notify and the
  transfer.

(cherry picked from commit ad32553c1d06dcc77542c52ea386ecaea0004f6b)

CHANGES
bin/tests/system/notify/clean.sh
bin/tests/system/notify/tests.sh

diff --git a/CHANGES b/CHANGES
index 46011c03b28a7fa58ceb08ace45a449947eea799..75f555bb234597b7c9813c1f19c459e24c9fc988 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -1,3 +1,6 @@
+4907.  [test]          Improved the reliabilty of the 'notify' system
+                       test. [GL #59]
+
 4905.  [bug]           irs_resconf_load() ignored resolv.conf syntax errors
                        when "domain" or "search" options were present in that
                        file. [GL #110]
index 909076b98493bc74e2e6a2e36edaaa56a609e79c..adcaa0e529f7e55ba6fb63123071309569fedb3e 100644 (file)
@@ -11,7 +11,7 @@
 #
 
 rm -f */named.memstats
-rm -f */named.run
+rm -f */named.run */named.run.prev
 rm -f */named.conf
 rm -f */named.port
 rm -f dig.out.?.ns5.test*
@@ -29,3 +29,4 @@ rm -f ns5/x21.bk-b.jnl
 rm -f ns5/x21.bk-c
 rm -f ns5/x21.bk-c.jnl
 rm -f ns5/x21.db.jnl
+rm -f tmp
index d88dc8d089f633d64063e34bc3308fde02f587d3..aaf22d02584ba773780d9d9058cc2bff5951064d 100644 (file)
@@ -59,6 +59,8 @@ awk '$1 > 5 { exit(1) }' log.out || ret=1
 [ $ret = 0 ] || echo_i "failed"
 status=`expr $ret + $status`
 
+nextpart ns3/named.run > /dev/null
+
 sleep 1 # make sure filesystem time stamp is newer for reload.
 rm -f ns2/example.db
 cp -f ns2/example2.db ns2/example.db
@@ -69,11 +71,13 @@ else
     echo_i "reloading with example2 using rndc and waiting up to 45 seconds"
     $RNDCCMD 10.53.0.2 reload 2>&1 | sed 's/^/I:ns2 /'
 fi
+
 try=0
 while test $try -lt 45
 do
+    nextpart ns3/named.run > tmp
+    grep "transfer of 'example/IN' from 10.53.0.2#.*success" tmp > /dev/null && break
     sleep 1
-    grep 'notify from 10.53.0.2#[0-9][0-9]*: serial 2$' ns3/named.run > /dev/null && break
     try=`expr $try + 1`
 done
 
@@ -118,8 +122,9 @@ $PERL $SYSTEMTESTTOP/start.pl --noclean --restart --port ${PORT} . ns2
 try=0
 while test $try -lt 45
 do
+    nextpart ns3/named.run > tmp
+    grep "transfer of 'example/IN' from 10.53.0.2#.*success" tmp > /dev/null && break
     sleep 1
-    grep 'notify from 10.53.0.2#[0-9][0-9]*: serial 4$' ns3/named.run > /dev/null && break
     try=`expr $try + 1`
 done