My Raspi is connected to our WLAN using the following /etc/network/interfaces settings

auto wlan0
allow-hotplug wlan0
iface wlan0 inet static
    wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf

And the following settings in /etc/wpa_supplicant/wpc_supplicant.conf

ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev


With this config, no hostnames are resolved - I suspect because the Pi can't find my local DNS servers ( and If I change these in the network interfaces file to and then external hostnames are resolved so I can successfully ping google.com (whereas previously only specifying the IP address -- e.g ping -- would work).

If I attempt to ping any local IP addresses, it tells me that the destination host is unreachable; internet works but not local network.

I am also unable to reach the Pi from other machines on my local network. My initial thought was an incorrect subnet mask, but when I run ifconfig it correctly brings through

  • Why do people pick these random settings and where do they come from?
    – Milliways
    Apr 18, 2017 at 11:16
  • What random settings?
    – ryansin
    Apr 18, 2017 at 11:17
  • @Milliways well that was an unhelpful comment, not what this site is about
    – ryansin
    Apr 18, 2017 at 11:28
  • 1
    I think the point is you seem to have done something cargo cult style and are then perplexed that it doesn't work. There actually is no question here, but it's implicit what you more or less meant to ask is the duplicate.
    – goldilocks
    Apr 18, 2017 at 12:45
  • I don't know why you'd assume that - I wrote this myself and I've set up networking on several Linux distros that have all worked. I included all of this information because I wanted to be clear, not because I don't understand how it works. On the same machine, for instance, eth0 works with a static IP. I think it would be helpful if @Milliways was more clear instead of just criticizing and marking as a duplicate of a generic question that doesn't solve this issue.
    – ryansin
    Apr 18, 2017 at 12:50


Browse other questions tagged or ask your own question.