0

I'm getting nowhere with the following problem: When using my local ISPs DNS server at 192.168.0.1 (for example putting it into /etc/resolv.conf or using it directly with dig google.com @192.168.0.1) everything works fine, all names are resolved. But as soon as I use any other DNS server (8.8.8.8, 9.9.9.9 or 1.1.1.1 - e.g. dig google.com @8.8.8.8) nothing works, I get the following error message from dig

$ dig google.com @8.8.8.8
; <<>> DiG 9.10.3-P4-Debian <<>> google.com @1.1.1.1
;; global options: +cmd
;; connection timed out; no servers could be reached

What I did so far:

  • Used ping 8.8.8.8 to check if I have net access - everything works.
  • Checked if the firewall port 53 is open - yes, it is.
  • Checked tcpdump -i eth0 -n -S port 53 - dig sends out the requests, I get no responses.

The strange thing is that when I use 192.168.0.1 as the DNS server it works, but as soon as I use any other DNS server I get no response. Can anyone help?

  • @shiftas 1h ago it worked properly and suddenly it stopped working. I can not explain why, I did nothing unusual. I'll try what you suggested. – chevallier Aug 8 at 8:43
  • For port 53, is TCP and UDP open? – Rui F Ribeiro Aug 8 at 9:01
  • @RuiFRibeiro yes, exactly, both TCP and UDP. – chevallier Aug 8 at 9:17
  • 2
    @RuiFRibeiro - Imagine, after calling my ISP (of course, they denied that they made any changes to their system during the phone call) it suddenly began to work. Thanks for your efforts! – chevallier Aug 8 at 10:04
  • 1
    "no servers could be reached" is a transport issue. Flags that can help: +tcp to force TCP or +notcp to force UDP (DNS is a poor child being mistreated regarding UDP vs TCP it often happens some rules are on one transport and not the other), and then working on EDNS UDP buffer size (+bufsize). BTW ping is almost never a good tool for troubleshooting. You could instead use tcptraceroute 8.8.8.8 53 to check TCP connectivity to host or traceroute --udp which uses port 53 then by default. – Patrick Mevzek Aug 8 at 20:31

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.