Subject: Re: name service (does anyone else see this?)
To: John Hawkinson <>
From: Greg A. Woods <>
List: current-users
Date: 08/06/1995 12:55:56
[ On Sat, August  5, 1995 at 22:10:54 (-0400), John Hawkinson wrote: ]
> Subject: Re: name service (does anyone else see this?)
> You should certainly use the loopback address in preference to
>, which is entirely bogus. If any implementation accepts it,
> it's confused itself.

Since most TCP/IP implementations do accept as the local host,
and this is a very well known feature, there's no problem with using it
where it works.

It certainly works on NetBSD-current:

	ttyp1:<woods@tar> $ telnet 0
	Connected to 0.
	Escape character is '^]'.
	NetBSD/sparc (tar) (ttyp0)
	login: Connection closed by foreign host.
> It's an open question as to whether you should use the ip address of
> an interface, or use the loopback. It generally doesn't matter, but
> using the loopback address is more likely to do the right thing if
> you copy the resolv.conf file to another machine (depending on what
> you mean by "right").
> Of course, you should always have more than one nameserver in
> resolv.conf, particularly if the first one is yourself, since some thnigs
> try to resolve names at boot time prior to named starting, like,
> say, syslogd.

>From the BIND-4.9.3-BETA24 "Name Server Operations Guide":

	Note that if multiple \fInameserver\fP entries are desired in
	\fB/etc/resolv.conf\fP (assuming the first entry is intended for the
	local host's instance of \fBnamed\fP), the first entry should specify
	the IP number of the local host, and not  If your host's IP
	implementation does not create a short-circuit route between the default
	interface and the loopback interface, then you might also want to add a
	static route (eg. in \fB/etc/rc.local\fP) to do so:
	.(b l
	\fIroute add localhost 1\fP

I.e. you should use if your host(s) supports it, esp. if you've
got multiple hosts with which you would like to share a single copy of
/etc/resolv.conf.  Otherwise you should use the IP number of the main
interface on your host, and if necessary you might want to add a
short-circuit route between this interface and the loopback interface.

Many TCP/IP implementations will cause even the most modern DNS resolver
implementations to hang in a query to if the local named isn't
running for some reason, regardless of the presence of additional
"nameserver" entries in the /etc/resolv.conf file.

							Greg A. Woods

+1 416 443-1734			VE3TCP			robohack!woods
Planix, Inc. <>; Secrets Of The Weird <>