This case scenario is for a router with embedded linux, but I think the answer could be the same for any Linux system.
This is my DNS check:
~ $ cat /etc/resolv.conf
nameserver 80.58.61.250
nameserver 80.58.61.254
~ $ ping 80.58.61.250
PING 80.58.61.250 (80.58.61.250): 56 data bytes
64 bytes from 80.58.61.250: seq=0 ttl=250 time=50.0 ms
64 bytes from 80.58.61.250: seq=1 ttl=250 time=40.0 ms
^C
--- 80.58.61.250 ping statistics ---
2 packets transmitted, 2 packets received, 0% packet loss
round-trip min/avg/max = 40.0/45.0/50.0 ms
~ $ ping www.google.es
PING www.google.es (2a00:1450:4007:808::101f): 56 data bytes
ping: sendto: Network is unreachable
~ $ ping 8.8.8.8
PING 8.8.8.8 (8.8.8.8): 56 data bytes
64 bytes from 8.8.8.8: seq=0 ttl=57 time=50.0 ms
64 bytes from 8.8.8.8: seq=1 ttl=57 time=40.0 ms
64 bytes from 8.8.8.8: seq=2 ttl=57 time=40.0 ms
^C
--- 8.8.8.8 ping statistics ---
3 packets transmitted, 3 packets received, 0% packet loss
round-trip min/avg/max = 40.0/43.3/50.0 ms
As can be seen, there is a response from internet (8.8.8.8
) but not from domain names (www.google.es
, same for www.google.com
).
The DNS server (80.58.61.250
) answers to pings.
So I was wondering if the problem could be in that DNS server.
Is there some way, like telneting or similar, to check if a given DNS IP works as it must (this is: answering with a IP address when requested for a domain name)?
For example, when testing a SSH server, a possible trick is:
C:\Users\Luis>telnet Midnighter- 22
SSH-2.0-OpenSSH_6.7p1 Debian-5
Third party tools accepted. Command line and Open source preferred.
ping
would have saidping: unknown host www.google.es
. – Mark Plotnick Oct 02 '15 at 16:18nslookup www.google.es
ornslookup www.google.es 80.58.61.250
to check the DNS server. – Mark Plotnick Oct 02 '15 at 16:20ping www.google.es
translated the name into an IP(v6) for you, in the parenthesis: "(2a00:1450:4007:808::101f)". Also:nslookup www.google.es
orhost www.google.es
. as per thrig's answer. – Jeff Schaller Oct 02 '15 at 17:01