I have a strange configuration problem with Wifi. When I connect a ethernet cable to my router, network eth0 is configured and I can access all internet resources.
However when I use a Wifi dongle, I can ssh into the Pi, but connection to the internet does not work, not even the router is reachable via ping. I have tried various combinations of settings in /etc/network/interfaces, but nothing makes it work nicely.
How can it work via eth0 and not over wlan0? Is there any option I can change to make this work better? Anything that could be misconfigured on the router? I have multiple other devices using Wifi on it without any problem...
This is the content of the config-files and output of some apps, any others that could shed some light on my problem?
$ ifconfig
eth0 Link encap:Ethernet Hardware Adresse b8:27:eb:42:36:d2
UP BROADCAST MULTICAST MTU:1500 Metrik:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
Kollisionen:0 Sendewarteschlangenlänge:1000
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
lo Link encap:Lokale Schleife
inet Adresse:127.0.0.1 Maske:255.0.0.0
UP LOOPBACK RUNNING MTU:16436 Metrik:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
Kollisionen:0 Sendewarteschlangenlänge:0
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
wlan0 Link encap:Ethernet Hardware Adresse 64:70:02:29:47:55
inet Adresse:192.168.1.102 Bcast:192.168.1.255 Maske:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metrik:1
RX packets:120 errors:0 dropped:125 overruns:0 frame:0
TX packets:69 errors:0 dropped:0 overruns:0 carrier:0
Kollisionen:0 Sendewarteschlangenlänge:1000
RX bytes:31342 (30.6 KiB) TX bytes:11574 (11.3 KiB)
$ iwconfig
wlan0 IEEE 802.11bgn ESSID:"dodoli" Nickname:""
Mode:Managed Frequency:2.427 GHz Access Point: F4:EC:38:B5:BF:BE
Bit Rate:150 Mb/s Sensitivity:0/0
Retry:off RTS thr:off Fragment thr:off
Power Management:off
Link Quality=100/100 Signal level=100/100 Noise level=0/100
Rx invalid nwid:0 Rx invalid crypt:0 Rx invalid frag:0
Tx excessive retries:0 Invalid misc:0 Missed beacon:0
lo no wireless extensions.
eth0 no wireless extensions.
$ cat /etc/network/interfaces auto lo iface lo inet loopback iface eth0 inet dhcp allow-hotplug wlan0 iface wlan0 inet dhcp wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf iface default inet dhcp
$ cat /etc/resolv.conf nameserver 192.168.1.1
$ route -n Kernel-IP-Routentabelle Ziel Router Genmask Flags Metric Ref Use Iface 0.0.0.0 192.168.1.1 0.0.0.0 UG 0 0 0 wlan0 192.168.1.0 0.0.0.0 255.255.255.0 U 0 0 0 wlan0
$ sudo cat /etc/wpa_supplicant/wpa_supplicant.conf
ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
update_config=1
network={
ssid="XXXXX"
scan_ssid=1
key_mgmt=WPA-PSK
psk="XXXXXXXXXXXXXXXXXXXXXXXX
}
ping to 192.168.1.1 (i.e. the route) times out, however ping to my desktop machine from where I ssh into it works, but the connection is done across the router!
/etc/wpa_supplicant/wpa_supplicant.conf– PiBorg Aug 19 '13 at 18:37