4

I'm running the Pi 2B headless and keep having to pull the plug because it's not connecting to the network. Sometimes it connects, sometimes it doesn't. My setup has an Ethernet cable connecting the Pi directly to a laptop (running Ubuntu 14.04). While I can't be 100% positive it's the Pi's problem, the fact that it sometimes works and that I've had trouble even when connecting it directly to a router leads me to believe the computer's DHCP server is fine.

I followed the an Interlock guide for my setup. I also tried Meltwater's suggestion of adding ip=some_ip_in_proper_subnet_range to cmdline.txt.

Often the connecting works for awhile and then drops. Other times it doesn't connect at all. It can't be pinged and isn't assigned an IP address.

This got more interesting when I noticed this in /var/log/syslog:

May  6 23:32:25 raspberrypi dhcpcd[2284]: eth0: carrier acquired
May  6 23:32:25 raspberrypi dhcpcd[2284]: all: IPv6 kernel autoconf disabled
May  6 23:32:25 raspberrypi kernel: [  183.948122] smsc95xx 1-1.1:1.0 eth0: link up, 100Mbps, full-duplex, lpa 0xC5E1
May  6 23:32:25 raspberrypi dhcpcd[2284]: eth0: IAID eb:07:6b:7c
May  6 23:32:25 raspberrypi dhcpcd[2284]: eth0: soliciting a DHCP lease
May  6 23:32:25 raspberrypi ifplugd(eth0)[1580]: Link beat detected.
May  6 23:32:25 raspberrypi kernel: [  184.731896] smsc95xx 1-1.1:1.0 eth0: link down
May  6 23:32:26 raspberrypi dhcpcd[2284]: eth0: carrier lost
May  6 23:32:26 raspberrypi ifplugd(eth0)[1580]: Link beat lost.

This is just an excerpt, but it shows a pattern that is repeated over and over. The entire file is available on pastebin.

Specs:
Board: Pi 2B
OS: Raspbian Wheezy and Jessie (observed on both)
SD card: Verified genuine Sandisk Ultra 16GB microSDHC HSI I (class 10)

I've checked the voltage the Pi is getting and it's about 5.05V-5.10V, so that shouldn't be a problem. Also, nothing connected except the power and Ethernet.

What could be causing the problem? How can I make the connection work reliably? What other information may be helpful in diagnosing the problem?

EDIT: I should have mentioned that even when the Pi cannot connect the Ubuntu PC shows as being connected to the "Connection Sharing" Ethernet connection. Thus, the two are at least in some sort of communication.

EDIT2: It's been behaving again for the last few days (it's scared of you I guess), but I wouldn't be surprised if it happens again, given it's been so unpredictable. I'm leaving this open for now and will report back with any developments.

  • If you are sure the power supply is sufficient I fear it may be defective/damaged hardware. Has it always been like this? Have you tried more than one cable? – goldilocks Jan 19 '16 at 14:39
  • What are the LEDs on the LAN socket doing? (They were on the PWB on the older RPi B rev 1.0,1.1,2.0) but "LINK" and "100" are now on the socket for B+ and RPi 2 Bs... – SlySven Jan 19 '16 at 19:48
  • @goldilocks I'm pretty sure it was from the beginning, though I wasn't able to isolate it until recently because I was dealing with power and SD issues. Today it was working fine so I don't know what to think. Also, see edit (though I doubt it's significant). – Nateowami Jan 20 '16 at 13:54
  • @SlySven IIRC, they were blinking happily (not that I was paying much attention), but I'll check whenever the board decides to misbehave again. Today it's been working. Any pattern I should be looking for? It's a 2B, so yeah, they're on the socket/plug. – Nateowami Jan 20 '16 at 14:01
  • 1
    Which is consistent with those /var/log/syslog reports: "Link beat detected" & "Link beat lost" (beat being short for "heart-beat") - are you sure the patch cable is okay - a dodgy Cat 5/5e/6 network lead could do this... – SlySven Jan 21 '16 at 10:54
1

Errors with the carrier is usually caused by the physical layer of the network (Layer 1 of the OSI model). Check/change your cable. Blow on your RJ-45 sockets. Check your router/switch/pi ethernet ports for problems.

  • Thanks. I'll try that and get back (thought it may be some time). I have tried multiple cables (which are both known to work with other devices and have sometimes worked with the Pi). – Nateowami Feb 3 '16 at 8:13
0

I have exact situation and turns out there is IP conflict with another device in the network, disconnect your pi from network (physically) and ping its IP address, if you get response then there is a another device with you PI address (I know OP connected directly, but may help someone else).

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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