LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Networking (https://www.linuxquestions.org/questions/linux-networking-3/)
-   -   host vs dig (https://www.linuxquestions.org/questions/linux-networking-3/host-vs-dig-79274/)

jpbarto 08-05-2003 02:42 PM

host vs dig
 
got a little network of 5 machines set up here at home (not connected to the internet).

if sitting on a machine I can ping and 'dig' any machine name I like (so long as I append house.net for the dig command).

However if lets say 'dig +short acomp.house.net' returns 192.168.1.12

and I then execute 'host 192.168.1.12' why does host come back with "timed out; no servers could be reached".

what's the deal here why can't I do reverse lookups?

bentz 08-05-2003 03:03 PM

'Timed out; no servers could be reached' is a message from your system regarding connecting to your DNS server. 'host' is trying to connect to your DNS server (specified in /etc/resolv.conf) and look for a DNS zone containing a '12' PTR record in 1.168.192.in-addr.arpa which it's not finding because DNS is apparently broken on your system. You cannot perform reverse lookups with 'host' against /etc/hosts, because 'host' is meant to be a DNS tool.

I imagine that forward lookups are working fine via /etc/hosts (which is controlled via /etc/nsswitch.conf; 'hosts: files dns').

jpbarto 08-06-2003 10:17 AM

thank you for the clarification and thoughts. I'll look into it and let you know what I find out.

jpbarto


All times are GMT -5. The time now is 04:43 PM.