mirror of
https://gitlab.isc.org/isc-projects/bind9
synced 2025-08-31 14:35:26 +00:00
check recovery from forwarding to a non-recursive server
This commit is contained in:
@@ -51,6 +51,11 @@ zone "example5." {
|
||||
file "example.db";
|
||||
};
|
||||
|
||||
zone "sld.tld" {
|
||||
type master;
|
||||
file "sld.tld.db";
|
||||
};
|
||||
|
||||
/* A forward zone without forwarders. */
|
||||
zone "example6" {
|
||||
type forward;
|
||||
|
11
bin/tests/system/forward/ns1/sld.tld.db
Normal file
11
bin/tests/system/forward/ns1/sld.tld.db
Normal file
@@ -0,0 +1,11 @@
|
||||
$TTL 300 ; 5 minutes
|
||||
@ IN SOA ns root (
|
||||
2000082401 ; serial
|
||||
1800 ; refresh (30 minutes)
|
||||
1800 ; retry (30 minutes)
|
||||
1814400 ; expire (3 weeks)
|
||||
3600 ; minimum (1 hour)
|
||||
)
|
||||
NS ns
|
||||
ns A 10.53.0.1
|
||||
xxx TXT "foo"
|
@@ -60,3 +60,8 @@ zone "1.0.10.in-addr.arpa." {
|
||||
type master;
|
||||
file "example.db";
|
||||
};
|
||||
|
||||
zone "tld" {
|
||||
type master;
|
||||
file "tld.db";
|
||||
};
|
||||
|
12
bin/tests/system/forward/ns2/tld.db
Normal file
12
bin/tests/system/forward/ns2/tld.db
Normal file
@@ -0,0 +1,12 @@
|
||||
$TTL 300 ; 5 minutes
|
||||
@ IN SOA ns root (
|
||||
2000082401 ; serial
|
||||
1800 ; refresh (30 minutes)
|
||||
1800 ; retry (30 minutes)
|
||||
1814400 ; expire (3 weeks)
|
||||
3600 ; minimum (1 hour)
|
||||
)
|
||||
NS ns
|
||||
ns A 10.53.0.2
|
||||
sld NS ns.sld
|
||||
ns.sld A 10.53.0.1
|
28
bin/tests/system/forward/ns8/named.conf.in
Normal file
28
bin/tests/system/forward/ns8/named.conf.in
Normal file
@@ -0,0 +1,28 @@
|
||||
/*
|
||||
* Copyright (C) Internet Systems Consortium, Inc. ("ISC")
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
*/
|
||||
|
||||
options {
|
||||
query-source address 10.53.0.8;
|
||||
notify-source 10.53.0.8;
|
||||
transfer-source 10.53.0.8;
|
||||
port @PORT@;
|
||||
pid-file "named.pid";
|
||||
listen-on { 10.53.0.8; };
|
||||
listen-on-v6 { none; };
|
||||
forwarders { 10.53.0.2; }; // returns referrals
|
||||
forward first;
|
||||
dnssec-validation yes;
|
||||
};
|
||||
|
||||
zone "." {
|
||||
type hint;
|
||||
file "root.db";
|
||||
};
|
11
bin/tests/system/forward/ns8/root.db
Normal file
11
bin/tests/system/forward/ns8/root.db
Normal file
@@ -0,0 +1,11 @@
|
||||
; Copyright (C) Internet Systems Consortium, Inc. ("ISC")
|
||||
;
|
||||
; This Source Code Form is subject to the terms of the Mozilla Public
|
||||
; License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
; file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
;
|
||||
; See the COPYRIGHT file distributed with this work for additional
|
||||
; information regarding copyright ownership.
|
||||
|
||||
. NS a.root-servers.nil.
|
||||
a.root-servers.nil. A 10.53.0.1
|
@@ -19,3 +19,4 @@ copy_setports ns3/named.conf.in ns3/named.conf
|
||||
copy_setports ns4/named.conf.in ns4/named.conf
|
||||
copy_setports ns5/named.conf.in ns5/named.conf
|
||||
copy_setports ns7/named.conf.in ns7/named.conf
|
||||
copy_setports ns8/named.conf.in ns8/named.conf
|
||||
|
@@ -159,5 +159,12 @@ sent=`grep "10.53.0.7#.* (.): query '\./NS/IN' approved" ns1/named.run | wc -l`
|
||||
if [ $ret != 0 ]; then echo_i "failed"; fi
|
||||
status=`expr $status + $ret`
|
||||
|
||||
echo_i "checking recovery from forwarding to a non-recursive server"
|
||||
ret=0
|
||||
$DIG $DIGOPTS xxx.sld.tld txt @10.53.0.8 > dig.out.f8
|
||||
grep "status: NOERROR" dig.out.f8 > /dev/null || ret=1
|
||||
if [ $ret != 0 ]; then echo_i "failed"; fi
|
||||
status=`expr $status + $ret`
|
||||
|
||||
echo_i "exit status: $status"
|
||||
[ $status -eq 0 ] || exit 1
|
||||
|
Reference in New Issue
Block a user