LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 12-24-2015, 03:01 PM   #1
pi3.14
LQ Newbie
 
Registered: Dec 2015
Distribution: Debian
Posts: 29

Rep: Reputation: Disabled
Strange Networking Behavior On Debian WiFi


Hi. I work at a Windows shop, but I setup my laptop to dual boot into Debian 8, with Gnome 3. I had to install the iwlwifi package to get Gnome to see the WiFi networks. I also had to adjust the netmanager config slight to get the ethernet managed. Other than that, I think it is a default system.

The networking seems to be fine on ethernet, but when on WiFi, connected to any of our routers, I see some weird behavior that prevents practical use. Here is a summary:

1. I can see all wireless networks, both with gnome and with iwlist. And I can connect successfully to any of them.
2. I can ping both localhost wlan0 ip address, as well as the gateway router. I can make dns requests to the gateway router.
3. I cannot ping anything past the gateway router, such as the next hop past the gateway router, or ip addresses on the Internet.
4. When booted into Windows, I have full connectivity using the same WiFi routers. I checked, and I have the same MAC address under both windows and Linux.

I can't understood how the WiFi routers would be discriminating against me based on my OS (that should be transparent). Maybe some issue with the routing configuration on my system...?

Code:
me@echo:~$ ip addr
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default 
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host 
       valid_lft forever preferred_lft forever
2: eth0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc pfifo_fast state DOWN group default qlen 1000
    link/ether <snip> brd ff:ff:ff:ff:ff:ff
    inet 169.254.5.110/16 brd 169.254.255.255 scope link eth0:avahi
       valid_lft forever preferred_lft forever
3: wlan0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 1000
    link/ether <snip> brd ff:ff:ff:ff:ff:ff
    inet 192.168.1.57/24 brd 192.168.1.255 scope global dynamic wlan0
       valid_lft 28240sec preferred_lft 28240sec
    inet6 fe80::6e88:14ff:fe3e:bae8/64 scope link 
       valid_lft forever preferred_lft forever

me@echo:~$ cat /etc/resolv.conf 
# Generated by NetworkManager
search <snip>
nameserver 192.168.1.2

me@echo:~$ ping -c 4 192.168.1.1 # 1st hop gateway router
PING 192.168.1.1 (192.168.1.1) 56(84) bytes of data.
64 bytes from 192.168.1.1: icmp_seq=1 ttl=64 time=2.03 ms
64 bytes from 192.168.1.1: icmp_seq=2 ttl=64 time=5.20 ms
64 bytes from 192.168.1.1: icmp_seq=3 ttl=64 time=1.88 ms
64 bytes from 192.168.1.1: icmp_seq=4 ttl=64 time=10.6 ms

me@echo:~$ ping -c 4 192.168.0.1 # next hop gateway router
PING 192.168.0.1 (192.168.0.1) 56(84) bytes of data.
From 169.254.5.110 icmp_seq=1 Destination Host Unreachable
From 169.254.5.110 icmp_seq=2 Destination Host Unreachable
From 169.254.5.110 icmp_seq=3 Destination Host Unreachable
From 169.254.5.110 icmp_seq=4 Destination Host Unreachable

me@echo:~$ ping -c 4 8.8.8.8 # Google DNS
PING 8.8.8.8 (8.8.8.8) 56(84) bytes of data.
From 169.254.5.110 icmp_seq=1 Destination Host Unreachable
From 169.254.5.110 icmp_seq=2 Destination Host Unreachable
From 169.254.5.110 icmp_seq=3 Destination Host Unreachable
From 169.254.5.110 icmp_seq=4 Destination Host Unreachable

me@echo:~$ nslookup google.com
Server:		192.168.1.2
Address:	192.168.1.2#53

Non-authoritative answer:
Name:	google.com
Address: 66.58.255.49
Name:	google.com
Address: 66.58.255.15
Name:	google.com

me@echo:~$ ping -c 4 google.com
PING google.com (66.58.255.44) 56(84) bytes of data.
From echo (169.254.5.110) icmp_seq=1 Destination Host Unreachable
From echo (169.254.5.110) icmp_seq=2 Destination Host Unreachable
From echo (169.254.5.110) icmp_seq=3 Destination Host Unreachable
From echo (169.254.5.110) icmp_seq=4 Destination Host Unreachable

root@echo:~# iptables -L
Chain INPUT (policy ACCEPT)
target     prot opt source               destination         

Chain FORWARD (policy ACCEPT)
target     prot opt source               destination         

Chain OUTPUT (policy ACCEPT)
target     prot opt source               destination         

root@echo:/etc# cat NetworkManager/NetworkManager.conf
[main]
plugins=ifupdown,keyfile

[ifupdown]
managed=true
 
Old 12-24-2015, 04:28 PM   #2
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,499

Rep: Reputation: 5841Reputation: 5841Reputation: 5841Reputation: 5841Reputation: 5841Reputation: 5841Reputation: 5841Reputation: 5841Reputation: 5841Reputation: 5841Reputation: 5841
Welcome to LinuxQuestions.

Yes, it looks like a routing problem. If you look at the output of the ping command you will see it is using eth0 versus wlan0 when trying to communicate outside the LAN.
Quote:
From 169.254.5.110 icmp_seq=1 Destination Host Unreachable
A 169.254.xxx.xxx address is assigned when the DHCP client can not communicate with the server. What did you adjust to get eth0 managed?

Post the output of the command:
ip route

https://en.wikipedia.org/wiki/Link-local_address
 
Old 12-24-2015, 05:01 PM   #3
pi3.14
LQ Newbie
 
Registered: Dec 2015
Distribution: Debian
Posts: 29

Original Poster
Rep: Reputation: Disabled
Code:
me@echo:~$ ip route
default dev eth0  scope link  metric 1002 
default via 192.168.1.1 dev wlan0  proto static  metric 1024 
169.254.0.0/16 dev eth0  proto kernel  scope link  src 169.254.5.110 
169.254.0.0/16 dev wlan0  scope link  metric 1000 
192.168.1.0/24 dev wlan0  proto kernel  scope link  src 192.168.1.57
Relevant notes: I noticed that, after rebooting the system, the networking works correctly for about 1 or 2 minutes. If I check the ip route command before that time is up, the default eht0 route is missing. And then after the networking stops working correctly, that eth0 default route shows up. So clearly something wrong in my configuration.

The part that I adjusted was in the /etc/NetworkManager/NetworkManager.conf file, pasted into my first post. I adjust the "managed" line from "false" to "true". I changed it earlier because when i first started Gnome, it said that the ethernet connection was unmanaged, so I gave that a try, blindly following some Web page article I found.
 
Old 12-28-2015, 03:15 PM   #4
pi3.14
LQ Newbie
 
Registered: Dec 2015
Distribution: Debian
Posts: 29

Original Poster
Rep: Reputation: Disabled
I tried deleting the NetworkManager.conf, and reinstalling network-manager and gnome-network-manager from Debian wheezy. But the eth0 default route still gets added after about 1 or 2 minutes, even if ethernet is never plugged in. I'm not sure how to proceed, so I'm just using the workaround command

Code:
ip route del default dev eth0
 
Old 12-28-2015, 03:38 PM   #5
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,499

Rep: Reputation: 5841Reputation: 5841Reputation: 5841Reputation: 5841Reputation: 5841Reputation: 5841Reputation: 5841Reputation: 5841Reputation: 5841Reputation: 5841Reputation: 5841
I'm not sure what is happening either. I only suspect that the dhcp client is trying to get an address on eth0 and times out to a link-local address.
 
Old 02-29-2016, 07:07 PM   #6
pi3.14
LQ Newbie
 
Registered: Dec 2015
Distribution: Debian
Posts: 29

Original Poster
Rep: Reputation: Disabled
For posterity, I think it was this line in /etc/network/interfaces causing the "problem":

Code:
# The primary network interface
allow-hotplug eth0
iface eth0 inet dhcp
If I comment that out, then I don't see the default eth0 route appear on startup, unless Network Manager adds it.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Debian Networking Doesn't Work with Home Wifi 52358 Linux - Networking 4 03-13-2017 09:11 AM
[SOLVED] Strange behavior battles Linux - Newbie 5 07-10-2014 09:59 AM
RXVT-unicode, strange behavior in Debian SID Vizaa Linux - Software 1 10-24-2012 10:48 AM
Wifi and networking - wierd behavior on Fedora 8 algogeek Linux - Hardware 1 05-09-2008 07:26 AM
Debian strange behavior about network config Half_Elf Debian 3 04-01-2004 01:07 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 10:40 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration