2
0
mirror of https://gitlab.isc.org/isc-projects/bind9 synced 2025-09-04 00:25:29 +00:00

Adjust the resolver-query-timeout test

Since the read timeout now works, the resolver time outs from the
dispatch level instead of from the "hung fetch" timer, and so the
EDE value in 'fctx_expired()' is not being set. Remove the expected
EDE value from the test.
This commit is contained in:
Aram Sargsyan
2024-12-20 10:39:26 +00:00
committed by Arаm Sаrgsyаn
parent 87c453850c
commit 5367ccb561

View File

@@ -53,16 +53,14 @@ grep -F "no servers could be reached" dig.out.ns1.test${n} >/dev/null || ret=1
if [ $ret != 0 ]; then echo_i "failed"; fi if [ $ret != 0 ]; then echo_i "failed"; fi
status=$((status + ret)) status=$((status + ret))
# 'resolver-query-timeout' is set to 5 seconds in ns1, which is lower than the # 'resolver-query-timeout' is set to 5 seconds in ns1, so named should
# current single query timeout value MAX_SINGLE_QUERY_TIMEOUT of 9 seconds, so # interrupt the non-responsive query and send a SERVFAIL answer before dig's
# the "hung fetch" timer should kick in, interrupt the non-responsive query and # own timeout fires, which is set to 7 seconds.
# send a SERVFAIL answer.
n=$((n + 1)) n=$((n + 1))
echo_i "checking no response handling with a longer than resolver-query-timeout timeout ($n)" echo_i "checking no response handling with a longer than resolver-query-timeout timeout ($n)"
ret=0 ret=0
dig_with_opts +tcp +tries=1 +timeout=7 noresponse.example.net @10.53.0.1 a >dig.out.ns1.test${n} || ret=1 dig_with_opts +tcp +tries=1 +timeout=7 noresponse.example.net @10.53.0.1 a >dig.out.ns1.test${n} || ret=1
grep -F "status: SERVFAIL" dig.out.ns1.test${n} >/dev/null || ret=1 grep -F "status: SERVFAIL" dig.out.ns1.test${n} >/dev/null || ret=1
grep -F "EDE: 22 (No Reachable Authority)" dig.out.ns1.test${n} >/dev/null || ret=1
if [ $ret != 0 ]; then echo_i "failed"; fi if [ $ret != 0 ]; then echo_i "failed"; fi
status=$((status + ret)) status=$((status + ret))