From 39191052ad90da2418f2d144708d09b12c173ec4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20K=C4=99pie=C5=84?= Date: Thu, 5 Nov 2020 07:53:43 +0100 Subject: [PATCH] Wait for the "fast-expire" zone to be transferred In order for a "fast-expire/IN: response-policy zone expired" message to be logged in ns3/named.run, the "fast-expire" zone must first be transferred in by that server. However, with unfavorable timing, ns3 may be stopped before it manages to fetch the "fast-expire" zone from ns5 and after the latter has been reconfigured to no longer serve that zone. In such a case, the "rpz" system test will report a false positive for the relevant check. Prevent that from happening by ensuring ns3 manages to transfer the "fast-expire" zone before getting shut down. --- bin/tests/system/rpz/tests.sh | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/bin/tests/system/rpz/tests.sh b/bin/tests/system/rpz/tests.sh index a151a3af97..c888289db4 100644 --- a/bin/tests/system/rpz/tests.sh +++ b/bin/tests/system/rpz/tests.sh @@ -781,7 +781,10 @@ EOF done fi - # reconfigure the ns5 primary server without the fast-exire zone, so + # Ensure ns3 manages to transfer the fast-expire zone before shutdown. + wait_for_log 20 "zone fast-expire/IN: transferred serial 1" ns3/named.run + + # reconfigure the ns5 primary server without the fast-expire zone, so # it can't be refreshed on ns3, and will expire in 5 seconds. cat /dev/null > ns5/expire.conf rndc_reconfig ns5 10.53.0.5