3

On my raspberry Pi 3B, attempting to access the internet for downloads fails. Anything that uses it (chromium, apt-get, etc) does not work, giving errors such as DNS server not found, or just hanging. However, ping google.com or ping 10.0.0.1 works just fine (connecting to my Router's setup page via 10.0.0.1 in chromium seems to work also)

This issue occurs on both LAN and WiFi.

I have looked at other forums which have similar issues, but their solutions do not seem to apply - the LAN lights are active on the Ethernet port, the MTU value of all interfaces is set to 1400, and my Router has DHCP enabled (the PI is detected)

  • OS: Raspbian 4.9.80 v7
  • Manufacturer: element14
9
  • Might not be relevant, but I should mention this issue just started today, and this is the first time this has ever happened on this board (it worked fine yesterday!)
    – Fuzzyzilla
    Commented Apr 4, 2018 at 4:45
  • It would help if you can be more specific about the errors – if you can, cut and paste the error message. It would also help to know the OS version you're using and how you are connected to the Internet. If you have other machines on the network, how is their connectivity?
    – dlu
    Commented Apr 4, 2018 at 5:01
  • Fuzzyzilla, you should add your comment to your question.
    – NomadMaker
    Commented Apr 4, 2018 at 5:03
  • @dlu My OS is Raspbian 4.9.80 v7 (fresh install today). In the case of errors, well, there just aren't any - chromium simply gives a generic DNS not found, and apt-get downloads trees, then hangs on 0%.
    – Fuzzyzilla
    Commented Apr 4, 2018 at 5:04
  • Is the DNS server not found or is the address you are asking for unresolved?
    – dlu
    Commented Apr 4, 2018 at 5:06

1 Answer 1

0

In cases like this it helps to break the problem down – which in turn means knowing something about the pieces that need to line up for a network connection to succeed. Much of this information isn't specific to the Pi or it's OS, but it will be helpful to know the tools and foibles of the particular hardware and OS that you are using.

This question and its answers may help: How do I set up networking/WiFi/static IP address?.

Testing with other devices on the same network may also help pinpoint where the problem lies. Rebooting often works wonders.

In general you want to start close and expand as you test, so you might:

  1. Check that your network is up and basically working by trying to ping a machine on your local net by IP address (ping 10.0.0.42).
  2. Check that you can talk to your router by attempting to ping the internal interface of your router by IP address (ping 10.0.0.1).
  3. Check that your router is routing by doing a ping to the external interface of your router by IP address (ping 1.2.4.192).
  4. Now try to reach your router's router by attempting to ping your router's default route by IP address (ping 1.2.4.8). Success means that you can reach a remote machine – specifically the machine that your router will be forwarding all of your Internet traffic to
  5. Now verify that it is all working with a to ping something far away by IP address (ping 8.8.8.8).

If those all work then you have a network connection that is working at the IP level. If any of them fail, then that is the spot to start investigating further.

Next test that DNS works. You could:

  1. Use dig to check it DNS requests are getting resolved. Use a well known server by IP address (e.g., 8.8.8.8 or 1.1.1.1) – dig google.com @1.1.1.1
  2. Then try the same thing using the DNS server that you have configured.
  3. Then try pinging a "new" host (one that you're confident isn't in your local resolver cache.

If you don't have dig or nslookup or a similar tool you can use ping instead.

14
  • Thank you for this answer! On my pi. steps 1-5 work, though I don't really know what 4 or 5 mean (forgive me!). As for the DNS testing, I get a dig: command not found spit back at me. I might need to install dig, but that's not really an option now! I should also point out that connecting to 10.0.0.1 via chromium does bring up my router's config page, so I don't think it's chromium's fault.
    – Fuzzyzilla
    Commented Apr 4, 2018 at 5:33
  • Added some more... Yes, chromium sounds like it is behaving (although there may still be a DNS problem).
    – dlu
    Commented Apr 4, 2018 at 5:45
  • ping google.com functions correctly. I've also tried for a lot of other sites, and they all ping as expected. EDIT: found a site that doesn't work - the one that apt-get is trying to access! ping mirrordirector.raspian.org drops all packets.
    – Fuzzyzilla
    Commented Apr 4, 2018 at 5:49
  • You can use ping instead of dig.
    – dlu
    Commented Apr 4, 2018 at 5:49
  • Firewall? Try curl (curl google.com) if you have it installed? Since you can get to 10.0.0.1 the problem is probably at your router or beyond.
    – dlu
    Commented Apr 4, 2018 at 5:51

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.