[TriLUG] Any help diagnosing an intermittent network issue?

Rodney Radford ncgadgetry at gmail.com
Sun Oct 26 10:42:24 EDT 2014


Wow lots of ideas, and lots of questions - let me try to address some of
the questions/suggestions given:

Here is the ifconfig eth0 output when everything is working correctly:

   eth0      Link encap:Ethernet  HWaddr 2c:27:d7:06:56:54
          inet addr:10.42.0.1  Bcast:10.42.0.255  Mask:255.255.255.0
          inet6 addr: fe80::2e27:d7ff:fe06:5654/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:8754 errors:0 dropped:0 overruns:0 frame:0
          TX packets:145646 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:8881902 (8.8 MB)  TX bytes:23985517 (23.9 MB)

And here it is when it is dead:

    eth0      Link encap:Ethernet  HWaddr 2c:27:d7:06:56:54
          inet6 addr: fe80::2e27:d7ff:fe06:5654/64 Scope:Link
          UP BROADCAST MULTICAST  MTU:1500  Metric:1
          RX packets:8752 errors:0 dropped:0 overruns:0 frame:0
          TX packets:145577 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:8881218 (8.8 MB)  TX bytes:23974762 (23.9 MB)

When I connect the network cable between the laptop and the RPi, ifconfig
starts toggling between those two outputs on a 1-2 second period. When the
connection is stable, this does not happen.

* The connection between the laptop and the RPi is a simple cable - no
switch, hob, in the middle.  No DHCP as I have statically defined the two
IP addresses on that link (laptop=10.42.0.1, RPi=10.42.0.2). No DNS
involved as I am connecting directly with IP addresses, but the issue is
evident even before connecting based on the instability shown with ifconfig.

* the wifi connection is between my laptop and my house modem. That
connection is stable and is on a different subnet (192.16.0.x) that is
completely separate from the 10.42.0.x used between the RPI and laptop.
For this reason (and the previous item), I don't see this as being a
DHCP/DNS issue, nor an issue with other systems on the wifi link.

* power to the RPi should be good. It is actually a dual RPi setup (with
dual RPi cameras), and both are powered by a 5v 4a supply and power is
passed directly through the GPIO, bypassing the micro-USB power setup.  No
devices are plugged in the USB ports. The only thing plugged into the RPis
are the RPI cameras.  There are two R/C servos attached directly to the
same 5v 4a supply (pan/tilt setup for the dual RPi cameras), but the
intermittent network issue occurred before I connected them, so it is not a
noise issue from those motors.

* I like the idea of disabling auto-negotiation, and I plan to dig a bit
deeper into that suggestion today.  Is there any way of logging this
renegotiation so I can see it happening and can confirm this?

* I also thought it could be a cable issue, so I had already tried
replacing the cable (with a brand new cable).

* I have also seen this on three different Raspberry Pi's attached to the
same system so that rules out a hardware issue with a particular Raspberry
Pi (with slightly different setups, so I don't think the issue is on the
RPi side, but still open to suggestions there).

I don't think it is a hardware issue, and I think I have ruled out DHCP and
DNS.  I have also ruled out the specific RPi as problematic and the cable.
That leaves the possibility of a hardware issue on my laptop eth0 (are
there any logs I can check to see this? There is nothing in dmesg), or a
configuration issue (which is what I suspect).

I am also very confused by something I see in network-manager, and this may
be the key. I initially set up this shared connection when I was running
12.04 and I filled in the fields for the static network on eth0 and labeled
it "Shared Raspberry Pi connection".  When I first upgraded to 14.04,
network-manager was not included, so I installed it.  When I look at the
connections, my named "Shared Raspberry Pi connection" is still there and
it shows as active when the cable is connected, however, when I look at the
IPV4 settings, all the fields are blank (I don't see the IP, broadcast and
netmask settings, although they are obviously stored somewhere as they are
used when the cable is installed).  Perhaps something wonky is going on
between the two different network-managers and how they store/use the
static data fields.  That is one reason I have not tried disabling
auto-negotiation as I don't see a way to set a value at this time.

I really really appreciate all the help - thanx!


On Sat, Oct 25, 2014 at 1:59 PM, Rodney Radford <ncgadgetry at gmail.com>
wrote:

> I have my laptop (running Ubuntu 14.04) corrected via wifi to my home
> router - that connect is up and stable.
>
> I then connect the wired network of the laptop to my Raspberry Pi.  I have
> configured both the RPi and my laptop as static on a different subnet.
>
> On most days, all is well - I can ssh to my RPi, and I have ICS set up
> between the RPi through my laptop to my wifi, so I can grab updates on my
> RPi and ssh to it.
>
> However some days the connection between my laptop and the RPi is very
> unstable.  I plug in the Ethernet cable between the two, watch the
> interface (eth0) come up and can connect, but then it drops a few seconds
> later.  Running a watch command on "ifconfig eth0" shows that it toggles
> between up and down every few seconds.
>
> There are no errors listed on the ifconfig, and nothing is in dmesg
> indicating an error.
>
> Ifconfig output when everything is fine:
>
> rradford at asimov:~$ ifconfig
> eth0      Link encap:Ethernet  HWaddr 2c:27:d7:06:56:54
>           inet addr:10.42.0.1  Bcast:10.42.0.255  Mask:255.255.255.0
>           inet6 addr: fe80::2e27:d7ff:fe06:5654/64 Scope:Link
>           UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
>           RX packets:8607 errors:0 dropped:0 overruns:0 frame:0
>           TX packets:132232 errors:0 dropped:0 overruns:0 carrier:0
>           collisions:0 txqueuelen:1000
>           RX bytes:8871528 (8.8 MB)  TX bytes:21755527 (21.7 MB)
>
> lo        Link encap:Local Loopback
>           inet addr:127.0.0.1  Mask:255.0.0.0
>           inet6 addr: ::1/128 Scope:Host
>           UP LOOPBACK RUNNING  MTU:65536  Metric:1
>           RX packets:847951 errors:0 dropped:0 overruns:0 frame:0
>           TX packets:847951 errors:0 dropped:0 overruns:0 carrier:0
>           collisions:0 txqueuelen:0
>           RX bytes:134296144 (134.2 MB)  TX bytes:134296144 (134.2 MB)
>
> wlan0     Link encap:Ethernet  HWaddr 68:a3:c4:d5:57:7a
>           inet addr:192.168.0.82  Bcast:192.168.0.255  Mask:255.255.255.0
>           inet6 addr: fe80::6aa3:c4ff:fed5:577a/64 Scope:Link
>           UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
>           RX packets:344266 errors:0 dropped:0 overruns:0 frame:0
>           TX packets:290361 errors:0 dropped:0 overruns:0 carrier:0
>           collisions:0 txqueuelen:1000
>           RX bytes:260820609 (260.8 MB)  TX bytes:61832612 (61.8 MB)
>
> Static interface on the RPi is configured via network-manager GUI.  The
> eth0 interface is not in /etc/network/interfaces.
>
> Watching the eth0 on the RPi does not show any issues.
>
> I don't understand why the interface bounces up and down every few seconds
> (and usually finally gives up) on some days, but with no changes works fine
> another day. I know this will be very difficult to debug remotely, so what
> I am looking for is help on where I should look to help diagnose this
> problem.
>
> Btw, this was working reliably with no problems before the 14.04 upgrade a
> few months ago, if that matters.
>
> Any assistance or ideas are greatly appreciated.
>
> Thanx,
> Rodney
>
>
>
>


More information about the TriLUG mailing list