On Thu, 16 Nov 2000, David Wolfskill wrote:

>I'm pretty sure that all (UNIX) versions of nslookup uses gethostbyname();
>I'm less confident about their use of gethostbyaddr().  (I'm pretty sure
>that there have been some versions of nslookup that would try to do a
>gethostbyname() using an IP address as an argument, if you gave it an IP
>address.  But the machine I have where that was likely the case stopped
>working a few months ago, and I don't have the time to get a Sun 3/60 running
>again... and I'm digressing.  For those versions of nslookup, it was
>generally necessary to feed it something of the form
>ddd.ccc.bbb.aaa.in-addr.arpa (assuming an IP address "aaa.bbb.ccc.ddd").)

I'm not sure of this at all.  On our internal machines, various breeds
of linux and solaris, nslookup doesn't return an answer if there is no
DNS entry for the name in question, EVEN IF that host is named in the
/etc/hosts file.

gethostbyname() follows the rules specifed in /etc/nsswitch.conf, which
is where gethostbyname() finds out in what order to search, files, dns,
nis, etc.

Some versions of nslookup will accept an IP address, ie the Linux flavor
will, but default Solaris flavors won't.

I've found that simply adding entries to /etc/hosts files was sufficient 
to get amanda running.  As long as each machine can 'ping othermachine'
and there isn't a conflict with DNS entries, it's fine.
-- 
Joi Ellis
[EMAIL PROTECTED], http://www.visi.com/~gyles19/

Reply via email to