README revision f159b7b5c761d9107808fef524a8491f41b4cd4f
9bff67898d55cddfcec9ce30cc2b1bb6211ec691David LawrenceCopyright (C) 2004, 2010, 2011, 2013, 2015 Internet Systems Consortium, Inc. ("ISC")
816e576f77e2c46df3e3d97d65822aa8aded7c4bDavid LawrenceCopyright (C) 2000, 2001 Internet Software Consortium.
2d54cf04fc02db7c369592b6f91bbd1330df3387Andreas GustafssonSee COPYRIGHT in the source root or http://isc.org/copyright.html for terms.
36bc6a0a8312de762caf1e984efe15c8e7170d9dAndreas Gustafsson
9c3531d72aeaad6c5f01efe6a1c82023e1379e4dDavid LawrenceThis is a simple test environment for running bind9 system tests
2d54cf04fc02db7c369592b6f91bbd1330df3387Andreas Gustafssoninvolving multiple name servers.
2d54cf04fc02db7c369592b6f91bbd1330df3387Andreas Gustafsson
2d54cf04fc02db7c369592b6f91bbd1330df3387Andreas GustafssonThere are multiple test suites, each in a separate subdirectory and
2d54cf04fc02db7c369592b6f91bbd1330df3387Andreas Gustafssoninvolving a different DNS setup. They are:
2d54cf04fc02db7c369592b6f91bbd1330df3387Andreas Gustafsson
2d54cf04fc02db7c369592b6f91bbd1330df3387Andreas Gustafsson dnssec/ DNSSEC tests
2d54cf04fc02db7c369592b6f91bbd1330df3387Andreas Gustafsson forward/ Forwarding tests
36bc6a0a8312de762caf1e984efe15c8e7170d9dAndreas Gustafsson glue/ Glue handling tests
36bc6a0a8312de762caf1e984efe15c8e7170d9dAndreas Gustafsson limits/ Tests of handling of large data (close to server limits)
36bc6a0a8312de762caf1e984efe15c8e7170d9dAndreas Gustafsson lwresd/ Tests of the lightweight resolver library and daemon
76458ec215a57c6806afdd831b9c9a30b93344b0Andreas Gustafsson notify/ More NOTIFY tests
76458ec215a57c6806afdd831b9c9a30b93344b0Andreas Gustafsson nsupdate/ Dynamic update and IXFR tests
2d54cf04fc02db7c369592b6f91bbd1330df3387Andreas Gustafsson resolver/ Regression tests for resolver bugs that have been fixed
2d54cf04fc02db7c369592b6f91bbd1330df3387Andreas Gustafsson (not a complete resolver test suite)
2d54cf04fc02db7c369592b6f91bbd1330df3387Andreas Gustafsson rrl/ query rate limiting
76458ec215a57c6806afdd831b9c9a30b93344b0Andreas Gustafsson rpz/ Tests of response policy zone (RPZ) rewriting
76458ec215a57c6806afdd831b9c9a30b93344b0Andreas Gustafsson stub/ Tests of stub zone functionality
76458ec215a57c6806afdd831b9c9a30b93344b0Andreas Gustafsson unknown/ Unknown type and class tests
76458ec215a57c6806afdd831b9c9a30b93344b0Andreas Gustafsson upforwd/ Update forwarding tests
40f53fa8d9c6a4fc38c0014495e7a42b08f52481David Lawrence views/ Tests of the "views" statement
76458ec215a57c6806afdd831b9c9a30b93344b0Andreas Gustafsson xfer/ Zone transfer tests
76458ec215a57c6806afdd831b9c9a30b93344b0Andreas Gustafsson xferquota/ Zone transfer quota tests
76458ec215a57c6806afdd831b9c9a30b93344b0Andreas Gustafsson
76458ec215a57c6806afdd831b9c9a30b93344b0Andreas GustafssonTypically each test suite sets up 2-5 name servers and then performs
b976f9c60a09f4a098852d0653ad5df6842557a7Andreas Gustafssonone or more tests against them. Within the test suite subdirectory,
b976f9c60a09f4a098852d0653ad5df6842557a7Andreas Gustafssoneach name server has a separate subdirectory containing its
3d4a70fe38769e42b943717256208b63fec05f32Andreas Gustafssonconfiguration data. By convention, these subdirectories are named
3d4a70fe38769e42b943717256208b63fec05f32Andreas Gustafsson"ns1", "ns2", etc.
b976f9c60a09f4a098852d0653ad5df6842557a7Andreas Gustafsson
36bc6a0a8312de762caf1e984efe15c8e7170d9dAndreas GustafssonThe tests are completely self-contained and do not require access to
36bc6a0a8312de762caf1e984efe15c8e7170d9dAndreas Gustafssonthe real DNS. Generally, one of the test servers (ns1) is set up as a
63404af69b0b99b8fa551e92702921f01c3bbfd7Andreas Gustafssonroot name server and is listed in the hints file of the others.
63404af69b0b99b8fa551e92702921f01c3bbfd7Andreas Gustafsson
63404af69b0b99b8fa551e92702921f01c3bbfd7Andreas GustafssonTo enable all servers to run on the same machine, they bind to
63404af69b0b99b8fa551e92702921f01c3bbfd7Andreas Gustafssonseparate virtual IP address on the loopback interface. ns1 runs on
63404af69b0b99b8fa551e92702921f01c3bbfd7Andreas Gustafsson10.53.0.1, ns2 on 10.53.0.2, etc. Before running any tests, you must
63404af69b0b99b8fa551e92702921f01c3bbfd7Andreas Gustafssonset up these addresses by running "ifconfig.sh up" as root.
63404af69b0b99b8fa551e92702921f01c3bbfd7Andreas Gustafsson
f7aa8ce0b3cf7f5df618a42beecf8d5517c000acAndreas GustafssonMac OS X:
f7aa8ce0b3cf7f5df618a42beecf8d5517c000acAndreas GustafssonIf you wish to make the interfaces survive across reboots
63404af69b0b99b8fa551e92702921f01c3bbfd7Andreas Gustafssoncopy org.isc.bind.system and org.isc.bind.system to
63404af69b0b99b8fa551e92702921f01c3bbfd7Andreas Gustafsson/Library/LaunchDaemons then run
63404af69b0b99b8fa551e92702921f01c3bbfd7Andreas Gustafsson"launchctl load /Library/LaunchDaemons/org.isc.bind.system.plist" as
63404af69b0b99b8fa551e92702921f01c3bbfd7Andreas Gustafssonroot.
63404af69b0b99b8fa551e92702921f01c3bbfd7Andreas Gustafsson
f7aa8ce0b3cf7f5df618a42beecf8d5517c000acAndreas GustafssonThe servers use port 5300 instead of the usual port 53, so they can be
63404af69b0b99b8fa551e92702921f01c3bbfd7Andreas Gustafssonrun without root privileges once the interfaces have been set up.
63404af69b0b99b8fa551e92702921f01c3bbfd7Andreas Gustafsson
63404af69b0b99b8fa551e92702921f01c3bbfd7Andreas GustafssonThe tests can be run individually like this:
63404af69b0b99b8fa551e92702921f01c3bbfd7Andreas Gustafsson
63404af69b0b99b8fa551e92702921f01c3bbfd7Andreas Gustafsson sh run.sh xfer
36bc6a0a8312de762caf1e984efe15c8e7170d9dAndreas Gustafsson sh run.sh notify
2d54cf04fc02db7c369592b6f91bbd1330df3387Andreas Gustafsson etc.
3d4a70fe38769e42b943717256208b63fec05f32Andreas Gustafsson
3d4a70fe38769e42b943717256208b63fec05f32Andreas GustafssonTo run all the tests, just type "make test".
36bc6a0a8312de762caf1e984efe15c8e7170d9dAndreas Gustafsson
36bc6a0a8312de762caf1e984efe15c8e7170d9dAndreas GustafssonWhen running system tests, named and lwresd can be run under
3d4a70fe38769e42b943717256208b63fec05f32Andreas GustafssonValgrind. The output from Valgrind are sent to per-process files that
3d4a70fe38769e42b943717256208b63fec05f32Andreas Gustafssoncan be reviewed after the test has completed. To enable this, set the
3d4a70fe38769e42b943717256208b63fec05f32Andreas GustafssonUSE_VALGRIND environment variable.
3d4a70fe38769e42b943717256208b63fec05f32Andreas Gustafsson