3667. [func] dig: add support to keep the TCP socket open between
successive queries (+[no]keepopen). [RT #34918]
This commit is contained in:
@@ -85,11 +85,16 @@ in_cache () {
|
||||
}
|
||||
|
||||
echo "I:check correctness of routine cache cleaning"
|
||||
$DIG $DIGOPTS -f dig.batch > dig.out.ns2 || status=1
|
||||
$DIG $DIGOPTS +tcp +keepopen -b 10.53.0.7 -f dig.batch > dig.out.ns2 || status=1
|
||||
grep ";" dig.out.ns2
|
||||
|
||||
$PERL ../digcomp.pl --lc dig.out.ns2 knowngood.dig.out || status=1
|
||||
|
||||
echo "I:only one tcp socket was used"
|
||||
tcpclients=`grep "client 10.53.0.7#[0-9]*:" ns2/named.run | awk '{print $4}' | sort | uniq -c | wc -l`
|
||||
|
||||
test $tcpclients -eq 1 || { status=1; echo "I:failed"; }
|
||||
|
||||
echo "I:reset and check that records are correctly cached initially"
|
||||
ret=0
|
||||
load_cache
|
||||
|
||||
Reference in New Issue
Block a user