[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Getting hostname

Steve Greenland wrote:
> Dig only works with DNS. The host solution works with /etc/hosts and
> (probably) NIS. Depending on the application, this may be an issue.

Hmm...  I thought host and dig were two sides of the same coin.  I
just checked with an experiment and host (neither one) returns
information from /etc/hosts but only from DNS.  (Yes, nsswitch.conf is
set to 'hosts: files dns'.)  BTW in my application, not the OP's
application, I really only wanted the DNS information.


Attachment: pgphU765oXJS8.pgp
Description: PGP signature

Reply to: