Restore default rrset-order to random.

This commit is contained in:
Mark Andrews
2018-06-15 13:34:27 +10:00
parent e495999c62
commit e8154b50d4
6 changed files with 64 additions and 5 deletions

View File

@@ -136,7 +136,7 @@ do
eval "match=\`expr \$match + \$match$i\`"
done
echo_i "Random selection return $match of 24 possible orders in 36 samples"
if [ $match -lt 8 ]; then echo ret=1; fi
if [ $match -lt 8 ]; then ret=1; fi
if [ $ret != 0 ]; then echo_i "failed"; fi
status=`expr $status + $ret`
@@ -230,7 +230,7 @@ do
eval "match=\`expr \$match + \$match$i\`"
done
echo_i "Random selection return $match of 24 possible orders in 36 samples"
if [ $match -lt 8 ]; then echo ret=1; fi
if [ $match -lt 8 ]; then ret=1; fi
if [ $ret != 0 ]; then echo_i "failed"; fi
status=`expr $status + $ret`
@@ -340,7 +340,7 @@ do
eval "match=\`expr \$match + \$match$i\`"
done
echo_i "Random selection return $match of 24 possible orders in 36 samples"
if [ $match -lt 8 ]; then echo ret=1; fi
if [ $match -lt 8 ]; then ret=1; fi
if [ $ret != 0 ]; then echo_i "failed"; fi
status=`expr $status + $ret`
@@ -438,7 +438,33 @@ do
eval "match=\`expr \$match + \$match$i\`"
done
echo_i "Random selection return $match of 24 possible orders in 36 samples"
if [ $match -lt 8 ]; then echo ret=1; fi
if [ $match -lt 8 ]; then ret=1; fi
if [ $ret != 0 ]; then echo_i "failed"; fi
echo_i "Checking default order (cache)"
ret=0
for i in 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24
do
eval match$i=0
done
for i in a b c d e f g h i j k l m n o p q r s t u v w x y z 0 1 2 3 4 5 6 7 9
do
$DIGCMD @10.53.0.5 random.example > dig.out.random || ret=1
match=0
for j in 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24
do
eval "$DIFF dig.out.random dig.out.random.good$j >/dev/null && match$j=1 match=1"
if [ $match -eq 1 ]; then break; fi
done
if [ $match -eq 0 ]; then ret=1; fi
done
match=0
for i in 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24
do
eval "match=\`expr \$match + \$match$i\`"
done
echo_i "Default selection return $match of 24 possible orders in 36 samples"
if [ $match -lt 8 ]; then ret=1; fi
if [ $ret != 0 ]; then echo_i "failed"; fi
echo_i "Checking default order no match in rrset-order (no shuffling)"
@@ -464,7 +490,7 @@ do
eval "match=\`expr \$match + \$match$i\`"
done
echo_i "Consistent selection return $match of 24 possible orders in 36 samples"
if [ $match -ne 1 ]; then echo ret=1; fi
if [ $match -ne 1 ]; then ret=1; fi
if [ $ret != 0 ]; then echo_i "failed"; fi
status=`expr $status + $ret`