Network Working Group A. Romao
Request for Comments: 1713 FCCN
FYI: 27 November 1994
Category: Informational
Tools for DNS debugging
1. Introduction
Today more than 3,800,000 computers are inter-connected in a global Internet [1], comprising several millions of end-users, able to reach any of those machines just by naming it. This facility is possible thanks to the world widest distributed database, the Domain Name System, used to provide distributed applications various services, the most notable one being translating names into IP addresses and vice-versa. This happens when you do an FTP or Telnet, when your gopher client follows a link to some remote server, when you click on a hypertext item and have to reach a server as defined by the URL, when you talk to someuser@some.host, when your mail has to be routed through a set to gateways before it reaches the final recipient, when you post an article to Usenet and want it propagated all over the world. While these may be the most visible uses of DNS, a lot more applications rely on this system to operate, e.g., network security, monitoring and accounting tools, just to mention a few.
Romao [Page 1]
RFC 1713 Tools for DNS debugging November 1994
All these anomalies make DNS less efficient than it could be, causing trouble to network operations, thus affecting the overall Internet. This document tries to show how important it is to have DNS properly managed, including what is already in place to help administrators taking better care of their domains.
2. DNS debugging
To help finding problems in DNS configurations and/or implementations there is a set of tools developed specifically for this purpose. There is probably a lot of people in charge of domain administration having no idea of these tools (and, worse, not aware of the anomalies that may exist in their configurations). What follows is a description of some of these programs, their scope, motivations and availability, and is hoped to serve as an introduction to the subject of DNS debugging, as well as a guide to those who are looking for something to help them finding out how healthy their domains and servers are.
2.1. Host
Host is a program used to retrieve DNS information from name servers. This information may be used simply to get simple things like address-to-name mapping, or some more advanced purposes, e.g., performing sanity checks on the data. It was created at Rutgers University, but then Eric Wassenaar from Nikhef did a major rewrite and still seems to be actively working on improving it. The program is available from ftp://ftp.nikhef.nl/pub/network/host_YYMMDD.tar.Z (YYMMDD is the date of the latest release).
Romao [Page 2]
RFC 1713 Tools for DNS debugging November 1994
As a debugger, host analyzes some set of the DNS space (e.g., an entire zone) and produces reports with the results of its operation. To do this, host first performs a zone transfer, which may be recursive, getting information from a zone and all its sub-zones. This data is then analyzed as requested by the arguments given on the command line. Note that zone transfers are done by contacting authoritative name servers for that zone, so it must be possible to make this kind of request from such servers: some of them refuse zone transfers (except from secondaries) to avoid congestion.
Romao [Page 3]
RFC 1713 Tools for DNS debugging November 1994 2.2. DnswalkDnswalk is a DNS debugger written in Perl by David Barr, from Pennsylvania State University. You'll find the latest version at ftp://ftp.pop.psu.edu/pub/src/dnswalk. With the software comes a small document where the author points some useful advice so it may be worth reading it.
Romao [Page 4]
RFC 1713 Tools for DNS debugging November 1994 2.3. LamersA lame delegation is a serious error in DNS configurations, yet a (too) common one. It happens when a name server is listed in the NS records for some domain and in fact it is not a server for that domain. Queries are thus sent to the wrong servers, who don't know nothing (at least not as expected) about the queried domain. Furthermore, sometimes these hosts (if they exist!) don't even run name servers. As a result, queries are timed out and resent, only to fail, thus creating (more) unnecessary traffic.
Romao [Page 5]
RFC 1713 Tools for DNS debugging November 1994
You can get lamers from ftp://terminator.cc.umich.edu/dns/lame- delegations.
2.4. DOC
Authority information is one of the most significant parts of the DNS data, as the whole mechanism depends on it to correctly traverse the domain tree. Incorrect authority information leads to problems such as lame delegations or even, in extreme cases, the inaccessibility of a domain. Take the case where the information given about all its name servers is incorrect: being unable to contact the real servers you may end up being unable to reach anything inside that domain. This may be exaggerated, but if you're on the DNS business long enough you've probably have seen some enlightened examples of this scenario.
Romao [Page 6]
RFC 1713 Tools for DNS debugging November 1994 2.5. DDTDDT (Domain Debug Tools) is a package of programs to scan DNS information for error detection, developed originally by Jorge Frazao from PUUG - Portuguese UNIX Users Group and later rewritten by the author, at the time at the Faculty of Sciences of University of Lisbon. Each program is specialized in a given set of anomalies: you have a checker for authority information, another for glue data, mail exchangers, reverse-mappings and miscellaneous errors found in all kinds of resource records. As a whole, they do a rather extensive checking on DNS configurations.
Romao [Page 7]
RFC 1713 Tools for DNS debugging November 1994
Except for ddt-xfer, all the programs are written in Perl. A new release may come into existence in a near future, after a thorough review of the methods used, the set of errors checked for and some bug fixing (in particular, a Perl version of ddt-xfer is expected). In the mean time, the latest version is available from ftp://ns.dns.pt/pub/dns/ddt-2.0.1.tar.gz.
2.6. The Checker Project
The problem of the huge amount of DNS traffic over the Internet is getting researchers close attention for quite some time, mainly because most of it is unnecessary. Observations have shown that DNS consumes something like twenty times more bandwidth than it should [4]. Some causes for this undoubtedly catastrophic scenario lie on deficient resolver and name server implementations spread all over the world, from personal to super-computers, running all sorts of operating systems.
Romao [Page 8]
RFC 1713 Tools for DNS debugging November 1994
Presently Checker has been running on a secondary for the US domain for more than a year with little trouble. Authors feel confident it should run on any BSD platform (at least SunOS) without problems, and is planned to be included as part of the BIND name server.
2.7. Others
All the tools described above are the result of systematic work on the issue of DNS debugging, some of them included in research projects. For the sake of completeness several other programs are mentioned here. These, though just as serious, seem to have been developed in a somewhat ad-hoc fashion, without an implicit intention of being used outside the environments where they were born. This impression is, of course, arguable, nevertheless there was no necessity of dedicating an entire section to any of them. This doesn't mean they are not valuable contributions, in some cases they may be just what you are looking for, without having to install a complete package to do some testings on your domain.
Romao [Page 9]
RFC 1713 Tools for DNS debugging November 1994
You may also want to consider using a version control system like SCCS or RCS to maintain your configuration files consistent through updates, or use tools like M4 macros to generate those files. As stated above, it's important to avoid human-generated errors, creating problems that are difficult to track down, since they're often hidden behind some mistyped name. Errors like this may end up in many queries for a non-existing name, just to mention the less serious kind. See [9] for a description of the most common errors made while configuring domains.
3. Why look after DNS?
Several pieces of software were presented to help people administer and debug their name services. They exhibit many differences in their way of doing things, scope and requirements and it may be difficult just to choose one of them to work with. For one thing, people's expectations from these tools vary according to their kind of involvement with DNS. If you are responsible for a big domain, e.g., a top-level one or a big institution with many hosts and sub- domains, you probably want to see how well is the tree below your node organized, since the consequences of errors tend to propagate upwards, thus affecting your own domain and servers. For that you need some program that recursively descends the domain tree and analyzes each domain per se and the interdependencies between them all. You will have to consider how deep you want your analysis to be, the effects it will have on the network infrastructure, i.e., will it generate traffic only inside a campus network, no matter how big it is, or will it be spread over, say, a whole country (of course, your kind of connectivity plays an important role here).
Romao [Page 10]
RFC 1713 Tools for DNS debugging November 1994
The ubiquitous DNS thus deserves a great deal of attention, perhaps much more than it generally has. One may say that it is a victim of its own success: if a user triggers an excessive amount of queries only to have one request satisfied, he won't worry about it (in fact, he won't notice it), won't complain to his system administrator, and things will just go on like this. Of course, DNS was designed to resist and provide its services despite all these anomalies. But by doing so it is frequently forgotten, as long as people can Telnet or ftp. As DNS will be given new responsibilities, as pointed in the above paragraph, the problems described in this text will grow more serious and new ones may appear (notably security ones [16], with a lot of work being presently in progress addressing security in DNS), if nothing is done to purge them.
Romao [Page 11]
RFC 1713 Tools for DNS debugging November 1994
[8] Albitz, P. and C. Liu, "DNS and BIND", O'Reilly and Associates
Romao [Page 12]
RFC 1713 Tools for DNS debugging November 1994
Security Considerations