User avatar
bernd.wechner
Posts: 14
Joined: Wed Sep 21, 2016 10:50 am

Network does not come up when restarting ...

Sun Oct 06, 2019 11:43 pm

This is frustrating me immensely. I have a Raspberry Pi acting as a NextCloudPi server and it's been down regularly of late. I'm scheduling a rebuild but I want also time understand what is going on.

So when it goes down I check on its console (I have a monitor and keyboard on the pi) and I can see that it's running but the network is down. So I reboot, and the network doesn't come up. It stays down. The Pi is connected on the LAN with a CAT6 cable. Has been operational 24/7 for a long long time

I cant' ping my gateway, and ifconfig reports no ip address on eth0.

So I try sudo networking restart, but no luck.I have two Pi's side by side which is convenient and so I move the SD card over the other Pi, same story. Conclusion, it's not a hardware issue.

I look on-line and all I find is advice on giving a Pi a static IP. And it always refers to cat interfac and they describe this line in that file:

iface eth0 inet dhcp

but on my system that file lacks this line, and only loads:

source-directory /etc/network/interfaces.d

which directory is empty!

I have a fully functional Pi next to as I said, and I actually have the same screen and keyboard on a KVM switch. So I can compare them quickly and easily. The other one has fully functional networking. And /etc/network/interfaces is identical. And it's network comes up without any line in that file asking it to.

If I add the line:

iface eth0 inet dhcp

to:

source-directory /etc/network/interfaces

on my broken system, and run ifup the network comes up, and all is good.

If I reboot now. The network is down and stays down. But if I run ifup the network comes up, and all is good.

Conclusion: systemd brings the network up some other way, not using /etc/network/interfaces and not using ifup!

This is what the inxi dump look like:

Code: Select all


System:
  Host: nephele Kernel: 4.19.66-v7+ armv7l bits: 32 Console: tty 0 
  Distro: Raspbian GNU/Linux 10 (buster) 
Machine:
  Type: ARM Device System: Raspberry Pi 3 Model B Rev 1.2 details: BCM2835 
  rev: a22082 serial: 00000000dec04907 
CPU:
  Topology: Quad Core model: ARMv7 v7l variant: cortex-a53 bits: 32 
  type: MCP 
  Speed: 600 MHz min/max: 600/1200 MHz Core speeds (MHz): 1: 600 2: 600 
  3: 600 4: 600 
Graphics:
  Device-1: bcm2708-fb driver: bcm2708_fb v: kernel 
  Device-2: bcm2835-hdmi driver: N/A 
  Display: tty server: N/A driver: N/A tty: 80x53 
  Message: Advanced graphics data unavailable in console. Try -G --display 
Audio:
  Device-1: bcm2835-audio driver: bcm2835_audio 
  Device-2: bcm2835-hdmi driver: N/A 
  Sound Server: ALSA v: k4.19.66-v7+ 
Network:
  Device-1: Standard Microsystems SMSC9512/9514 Fast Ethernet Adapter 
  type: USB driver: smsc95xx 
  IF: eth0 state: up speed: 100 Mbps duplex: full mac: b8:27:eb:c0:49:07 
  IF-ID-1: wlan0 state: down mac: b8:27:eb:95:1c:52 
Drives:
  Local Storage: total: 961.29 GiB used: 73.75 GiB (7.7%) 
  ID-1: /dev/mmcblk0 model: EB1QT size: 29.81 GiB 
  ID-2: /dev/sda type: USB vendor: Western Digital 
  model: WD My Passport 259F size: 931.48 GiB 
Partition:
  ID-1: / size: 29.28 GiB used: 7.18 GiB (24.5%) fs: ext4 
  dev: /dev/mmcblk0p2 
  ID-2: /boot size: 42.4 MiB used: 39.1 MiB (92.2%) fs: vfat 
  dev: /dev/mmcblk0p1 
Sensors:
  Message: No sensors data was found. Is sensors configured? 
Info:
  Processes: 148 Uptime: 2h 39m Memory: 1002.1 MiB used: 307.1 MiB (30.6%) 
  gpu: 76.0 MiB Init: systemd runlevel: 5 Shell: bash inxi: 3.0.32 
/var/log/boot.log shows:

Code: Select all

[FAILED] Failed to start dhcpcd on all interfaces.
See 'systemctl status dhcpcd.service' for details.
and so:

Code: Select all

$ systemctl status dhcpcd.service
● dhcpcd.service - dhcpcd on all interfaces
   Loaded: loaded (/lib/systemd/system/dhcpcd.service; enabled; vendor preset: enabled)
  Drop-In: /etc/systemd/system/dhcpcd.service.d
           └─wait.conf
   Active: failed (Result: exit-code) since Sun 2019-10-06 19:24:57 AEDT; 15h ago
  Process: 323 ExecStart=/usr/lib/dhcpcd5/dhcpcd -q -w (code=exited, status=6)

Oct 06 19:24:57 nephele systemd[1]: Starting dhcpcd on all interfaces...
Oct 06 19:24:57 nephele dhcpcd[323]: Not running dhcpcd because /etc/network/interfaces
Oct 06 19:24:57 nephele dhcpcd[323]: defines some interfaces that will use a
Oct 06 19:24:57 nephele dhcpcd[323]: DHCP client or static address
Oct 06 19:24:57 nephele systemd[1]: dhcpcd.service: Control process exited, code=exited, status=6/NOTCONFIGURED
Oct 06 19:24:57 nephele systemd[1]: dhcpcd.service: Failed with result 'exit-code'.
Oct 06 19:24:57 nephele systemd[1]: Failed to start dhcpcd on all interfaces.
Which is odd. Systemd is saying it didn't do DHCP (and this is probably the root failure as the hardware is fine and when the net is down it seems only to be because the device has no IP address) because I've asked for DHCP in

Code: Select all

/etc/network.interfaces
and yet having it in that file does not run it on boot I have to run

Code: Select all

ifup
to before I get an IP!

The basic question is, how is it that:

[*] ifup can get me an IP address
[*] systemd can't
[*] a seemingly identical system works fine
[*] this system still doesn't get an IP fine when the SD card is moved to the other Pi
[*] the other system gets one fine when its SD card is moved into this Pi

How is systemd DHCP configured and where are its logs, and why does all the on-line advice I find refer to

Code: Select all

/etc/network/interfaces
when clearly systemd doesn't like that file at all!

Eager to learn more. Will blow this system away and reinstall in time but would like to diagnose and understand if at all possible.

User avatar
topguy
Posts: 5898
Joined: Tue Oct 09, 2012 11:46 am
Location: Trondheim, Norway

Re: Network does not come up when restarting ...

Mon Oct 07, 2019 12:38 am

You have been reading a lot of old guides for older versions of Raspbian it seems.
Leave "/etc/network/interfaces" be and focus on guides that mention "/etc/dhcpcd.conf".

I think this is a hole in the RPF documentation, but it seem like they dont want to encourage people exposing the Pi on the internet via static IP and port-forwardning.
https://www.raspberrypi.org/documentati ... /README.md

Also dont forget that some routers allow you to assign static DHCP addresses to devices, that way you can leave the pi on DHCP.

User avatar
bernd.wechner
Posts: 14
Joined: Wed Sep 21, 2016 10:50 am

Re: Network does not come up when restarting ...

Mon Oct 07, 2019 2:18 am

Methinks it boils down to why dhcpcd stated recently to do this:

control command: /sbin/dhcpcd -k eth0

on boot. Restart the service and it doesn't do that! But on boot it does. Why would it choose to kill the interface?

More details to follow!
Last edited by bernd.wechner on Mon Oct 07, 2019 2:19 am, edited 1 time in total.

User avatar
bernd.wechner
Posts: 14
Joined: Wed Sep 21, 2016 10:50 am

Re: Network does not come up when restarting ...

Mon Oct 07, 2019 2:19 am

Hey, thanks for the quick reply. Indeed my supposition was and is, that much of what I find on-line is old and predates the systemd move on Debian.

Just couldn't find much else.

I had found and examined /etc/dhcpcp.conf but alas I saw no clues as both the working config and the broken one looks very similar and end with:

Code: Select all

# A ServerID is required by RFC2131.
require dhcp_server_identifier

# Generate Stable Private IPv6 Addresses instead of hardware based ones
slaac private

# Example static IP configuration:
#interface eth0
#static ip_address=192.168.0.10/24
#static ip6_address=fd51:42f8:caae:d92e::ff/64
#static routers=192.168.0.1
#static domain_name_servers=192.168.0.1 8.8.8.8 fd51:42f8:caae:d92e::1

# It is possible to fall back to a static IP if DHCP fails:
# define static profile
#profile static_eth0
#static ip_address=192.168.1.23/24
#static routers=192.168.1.1
#static domain_name_servers=192.168.1.1

# fallback to static profile on eth0
#interface eth0
#fallback static_eth0
Very suspiciously interface eth0 is commented out, on both systems (one that works, and my broken one). So I didn't drill down to this as a clue. Yet your suggestion prompted me to look deeper and, on the good system:

Code: Select all

$ service dhcpcd status
● dhcpcd.service - dhcpcd on all interfaces
   Loaded: loaded (/lib/systemd/system/dhcpcd.service; enabled; vendor preset: enabled)
  Drop-In: /etc/systemd/system/dhcpcd.service.d
           └─wait.conf
   Active: active (running) since Sun 2019-10-06 13:49:15 AEDT; 22h ago
  Process: 290 ExecStart=/usr/lib/dhcpcd5/dhcpcd -q -w (code=exited, status=0/SUCCESS)
 Main PID: 383 (dhcpcd)
   CGroup: /system.slice/dhcpcd.service
           └─383 /sbin/dhcpcd -q -w

Oct 06 13:49:20 hermes dhcpcd[383]: eth0: soliciting a DHCPv6 lease
Oct 06 13:49:20 hermes dhcpcd[383]: eth0: ADV fd55:c3f2:2a6::a6d/128 from fe80::da58:d7ff:fe00:62e5
Oct 06 13:49:20 hermes dhcpcd[383]: eth0: REPLY6 received from fe80::da58:d7ff:fe00:62e5
Oct 06 13:49:20 hermes dhcpcd[383]: eth0: adding address fd55:c3f2:2a6::a6d/128
Oct 06 13:49:20 hermes dhcpcd[383]: eth0: renew in 21600, rebind in 34560, expire in 4294967295 seconds
Oct 06 13:49:22 hermes dhcpcd[383]: eth0: offered 192.168.0.16 from 192.168.0.1
Oct 06 13:49:22 hermes dhcpcd[383]: eth0: probing address 192.168.0.16/23
Oct 06 13:49:26 hermes dhcpcd[383]: eth0: leased 192.168.0.16 for 43200 seconds
Oct 06 13:49:26 hermes dhcpcd[383]: eth0: adding route to 192.168.0.0/23
Oct 06 13:49:26 hermes dhcpcd[383]: eth0: adding default route via 192.168.0.1
and on the bad:

Code: Select all

$ service dhcpcd status
● dhcpcd.service - dhcpcd on all interfaces
   Loaded: loaded (/lib/systemd/system/dhcpcd.service; enabled; vendor preset: enabled)
  Drop-In: /etc/systemd/system/dhcpcd.service.d
           └─wait.conf
   Active: active (running) since Mon 2019-10-07 12:49:48 AEDT; 2min 4s ago
  Process: 312 ExecStart=/usr/lib/dhcpcd5/dhcpcd -q -w (code=exited, status=0/SUCCESS)
 Main PID: 492 (dhcpcd)
    Tasks: 2 (limit: 2200)
   Memory: 4.5M
   CGroup: /system.slice/dhcpcd.service
           ├─387 wpa_supplicant -B -c/etc/wpa_supplicant/wpa_supplicant.conf -iwlan0 -Dnl80211,wext
           └─492 /sbin/dhcpcd -q -w

Oct 07 12:49:58 nephele dhcpcd[492]: eth0: accepted reconfigure key
Oct 07 12:49:58 nephele dhcpcd[492]: eth0: REPLY6 received from fe80::da58:d7ff:fe00:62e5
Oct 07 12:49:58 nephele dhcpcd[492]: eth0: adding address fd55:c3f2:2a6::4ed/128
Oct 07 12:49:58 nephele dhcpcd[492]: eth0: renew in 21600, rebind in 34560, expire in 4294967295 seconds
Oct 07 12:50:00 nephele dhcpcd[492]: control command: /sbin/dhcpcd -k eth0
Oct 07 12:50:00 nephele dhcpcd[492]: eth0: removing interface
Oct 07 12:50:00 nephele dhcpcd[492]: eth0: deleting address fd55:c3f2:2a6::4ed/128
Oct 07 12:50:00 nephele dhcpcd[492]: eth0: deleting address fd55:c3f2:2a6:0:5497:6614:6463:a307/64
Oct 07 12:50:00 nephele dhcpcd[492]: eth0: deleting route to fd55:c3f2:2a6::/64
Oct 07 12:50:00 nephele dhcpcd[492]: eth0: deleting address fe80::ba88:7327:5081:7455
but turns out I can fix it after boot as follows:

Code: Select all

$ service dhcpcd restart
$ service dhcpcd status
● dhcpcd.service - dhcpcd on all interfaces
   Loaded: loaded (/lib/systemd/system/dhcpcd.service; enabled; vendor preset: enabled)
  Drop-In: /etc/systemd/system/dhcpcd.service.d
           └─wait.conf
   Active: active (running) since Mon 2019-10-07 12:52:36 AEDT; 1min 2s ago
  Process: 2512 ExecStart=/usr/lib/dhcpcd5/dhcpcd -q -w (code=exited, status=0/SUCCESS)
 Main PID: 2601 (dhcpcd)
    Tasks: 2 (limit: 2200)
   Memory: 2.2M
   CGroup: /system.slice/dhcpcd.service
           ├─2528 wpa_supplicant -B -c/etc/wpa_supplicant/wpa_supplicant.conf -iwlan0 -Dnl80211,wext
           └─2601 /sbin/dhcpcd -q -w

Oct 07 12:52:34 nephele dhcpcd[2512]: eth0: REPLY6 received from fe80::da58:d7ff:fe00:62e5
Oct 07 12:52:34 nephele dhcpcd[2512]: eth0: adding address fd55:c3f2:2a6::4ed/128
Oct 07 12:52:34 nephele dhcpcd[2512]: eth0: renew in 21600, rebind in 34560, expire in 4294967295 seconds
Oct 07 12:52:35 nephele dhcpcd[2512]: Too few arguments.
Oct 07 12:52:36 nephele dhcpcd[2512]: Too few arguments.
Oct 07 12:52:36 nephele dhcpcd[2512]: forked to background, child pid 2601
Oct 07 12:52:36 nephele systemd[1]: Started dhcpcd on all interfaces.
Oct 07 12:52:38 nephele dhcpcd[2601]: eth0: leased 192.168.0.14 for 43200 seconds
Oct 07 12:52:38 nephele dhcpcd[2601]: eth0: adding route to 192.168.0.0/23
Oct 07 12:52:38 nephele dhcpcd[2601]: eth0: adding default route via 192.168.0.1
Stunning! So now I just need to work out why it fails at boot time. This is new., very recent ... always worked until recently. Something changed on this system that is causing the dhcpcd service to fails at boot time, but work fine once restarted. What could that be?

User avatar
bernd.wechner
Posts: 14
Joined: Wed Sep 21, 2016 10:50 am

Re: Network does not come up when restarting ...

Mon Oct 07, 2019 2:41 am

Aaargh, I tried an experiment, disabling the wifi in /boot/config.txt by adding:

Code: Select all

# Disable wifi and bluetooth on Nepehele (wired LAN only needed)
dtoverlay=pi3-disable-wifi
dtoverlay=pi3-disable-bt
Rebooted and it got an IP address on boot!

This isn't the end of my woes nor the final understanding as it wasn't working on an Pi2 and the SD card sits in a Pi3 only by chance right now as I'm faffing around with it. And the Pi3's Wifi confused the DHCP daemon. And yet this CAN'T be normal. I mean boot up a Pi3 on the wire and it should get a DHCP IP from the wire! Something else is wrong! But disabling wifi seems to have helped.

CTGreybeard
Posts: 7
Joined: Fri Nov 27, 2015 2:35 pm
Location: Western Connecticut, USA

Re: Network does not come up when restarting ...

Mon Oct 07, 2019 5:27 pm

Have you gotten anywhere with this? My Pi4 refuses to behave and bring up the wired interface. I did try disabling wifi and bt but that didn't fix it.

I can see from journalctl the the deadly /sbin/dhcpcd -k eth0 is at work here but I cannot figure out why.

Strangely, this all worked fine a few days ago the first time I started it up. But since then it hasn't worked.

I can't get it to start with either a static or dynamic IP.

User avatar
bernd.wechner
Posts: 14
Joined: Wed Sep 21, 2016 10:50 am

Re: Network does not come up when restarting ...

Mon Oct 07, 2019 8:43 pm

CTGreybeard wrote:
Mon Oct 07, 2019 5:27 pm
Have you gotten anywhere with this? My Pi4 refuses to behave and bring up the wired interface. I did try disabling wifi and bt but that didn't fix it.

I can see from journalctl the the deadly /sbin/dhcpcd -k eth0 is at work here but I cannot figure out why.

Strangely, this all worked fine a few days ago the first time I started it up. But since then it hasn't worked.

I can't get it to start with either a static or dynamic IP.
I sympathise I really do. That /sbin/dhcpcd -k eth0 is mysterious as and I can't seem to find any clues on-line or reasons for it. Alas I haven't worked it out either :-(. I only noticed yesterday that if I turned off the wifi with that patch it now boots up fine again. I wish I did know why the dhcpcd daemon elects, at boot, to kill the eth0 interface, but not when it's restarted. I wonder if at your end you find same as I did, that if you restart it from a console with sudo service dhcpcd restart then the daemon gets an IPv4 address just fine from my DHCP server.

Personally I'm loosely planning to blow that SD car away with a clean install. Alas it's a time consuming hassle but I try and keep good notes on customisations and hopefully they are complete. Mainly SSL certs needs a little work to configure (for remove ssh access and for serving https pages). But that's a digression. Point is, I find the uncertainty and my ignorance around what happened here with my network interface out of the blue so annoying I find the idea of a clean install appealing. So I put one on a new SD card yesterday and now just need to find a time to customize it on another RPi so I can swap it in and fingers crossed all works.

epoch1970
Posts: 3799
Joined: Thu May 05, 2016 9:33 am
Location: Paris, France

Re: Network does not come up when restarting ...

Mon Oct 07, 2019 9:35 pm

bernd.wechner wrote:
Mon Oct 07, 2019 8:43 pm
I wish I did know why the dhcpcd daemon elects, at boot, to kill the eth0 interface, but not when it's restarted.
If you want an address via DHCP on Raspbian Buster, it is very simple.
1) Configure NOTHING in dhcpcd.conf
2) Remove EVERYTHING from /etc/network/interfaces. ifupdown is obsolete.
3) Do NOT enable systemd-networkd. It is not enabled by default on Raspbian.

Stop using "ifup" and "ifdown", they read "/etc/network/interfaces" so they do nothing on Buster.
Use e.g. "ip link set dev eth0 up" or "ifconfig wlan0 up" instead.
(Commands "ifconfig" and "route" are obsoleted by "ip", they will disappear one day.)

Always refer to raspberrypi.org for documentation, it is maintained and current.
"S'il n'y a pas de solution, c'est qu'il n'y a pas de problème." Les Shadoks, J. Rouxel

CTGreybeard
Posts: 7
Joined: Fri Nov 27, 2015 2:35 pm
Location: Western Connecticut, USA

Re: Network does not come up when restarting ...

Mon Oct 07, 2019 10:45 pm

epoch1970 wrote:
Mon Oct 07, 2019 9:35 pm
If you want an address via DHCP on Raspbian Buster, it is very simple.
1) Configure NOTHING in dhcpcd.conf
2) Remove EVERYTHING from /etc/network/interfaces. ifupdown is obsolete.
3) Do NOT enable systemd-networkd. It is not enabled by default on Raspbian.
Yes, that is the documented way but it does not work on my system. Nor does assigning a static IP using the documented method. I think if you browsed through this thread you might see that this has been tried.

I am preparing a new Buster SD to try with. As this server has been built over several years with my custom software this might take a bit to transfer over. But it's an effort well worth it because it's also gathered enough cruft to need cleaning out.

User avatar
bernd.wechner
Posts: 14
Joined: Wed Sep 21, 2016 10:50 am

Re: Network does not come up when restarting ...

Tue Oct 08, 2019 12:37 am

That really does not help much alas. Sorry.

It's little more than an expression that "thinks work out of the box". And they do. And my RPi did. And it was good. And then it went off line, out of the blue (perhaps an auto update?).

I checked it at console. It was running. So I rebooted. It was still offline. I swapped cables. Still off line. I moved that cable to another RPi, it stayed on-line. I searched and search and searched and could find no clues that did not reference /etc/network/interfaces and saw that mine was empty. So I knew something had changed, and suspected it related to a shift to systemd. And so it was, when Jessie was released. And now there was a new way to do things. So I checked those, I compared configs with working Pi, saw no relevenat differences. Tested it manually and net came up (sudo service dhcpcd restart brings the net up). I checked boot longs. It fails at boot, for no explained reason. dhcpcd simply kills eth0. I don't understand why, nor does CTGreybeard .

1) Configure NOTHING in dhcpcd.conf - I never did. I didn't touch a thing. It just went off line one day! Don't know why. Don't know exactly when.
2) Remove EVERYTHING from /etc/network/interfaces. ifupdown is obsolete. - I know and said as much above. And yet, if you use it and ifup the link comes up. But then leaving it be and simple restarting the dhcp daemon also brings the link up.
3) Do NOT enable systemd-networkd. It is not enabled by default on Raspbian. - I didn't and it's not and never heard of that but just checked with service --status-all and confirmed no such service is enabled.

epoch1970
Posts: 3799
Joined: Thu May 05, 2016 9:33 am
Location: Paris, France

Re: Network does not come up when restarting ...

Tue Oct 08, 2019 4:36 pm

bernd.wechner wrote:
Sun Oct 06, 2019 11:43 pm

Code: Select all

$ systemctl status dhcpcd.service
...
Oct 06 19:24:57 nephele dhcpcd[323]: Not running dhcpcd because /etc/network/interfaces
Oct 06 19:24:57 nephele dhcpcd[323]: defines some interfaces that will use a
Oct 06 19:24:57 nephele dhcpcd[323]: DHCP client or static address
...
Is the wording of that error message unclear somehow?
"S'il n'y a pas de solution, c'est qu'il n'y a pas de problème." Les Shadoks, J. Rouxel

User avatar
bernd.wechner
Posts: 14
Joined: Wed Sep 21, 2016 10:50 am

Re: Network does not come up when restarting ...

Tue Oct 08, 2019 11:02 pm

That one is clear indeed. Apologies. I cleaned /etc/network/interfaces and it still doesn't run on boot, if you read my post. It instead simply reports: control command: /sbin/dhcpcd -k eth0

Which is where the mystery lies, which is unclear because it provides no reason. Full report I listed above but repeated is:

Code: Select all

$ service dhcpcd status
● dhcpcd.service - dhcpcd on all interfaces
   Loaded: loaded (/lib/systemd/system/dhcpcd.service; enabled; vendor preset: enabled)
  Drop-In: /etc/systemd/system/dhcpcd.service.d
           └─wait.conf
   Active: active (running) since Mon 2019-10-07 12:49:48 AEDT; 2min 4s ago
  Process: 312 ExecStart=/usr/lib/dhcpcd5/dhcpcd -q -w (code=exited, status=0/SUCCESS)
 Main PID: 492 (dhcpcd)
    Tasks: 2 (limit: 2200)
   Memory: 4.5M
   CGroup: /system.slice/dhcpcd.service
           ├─387 wpa_supplicant -B -c/etc/wpa_supplicant/wpa_supplicant.conf -iwlan0 -Dnl80211,wext
           └─492 /sbin/dhcpcd -q -w

Oct 07 12:49:58 nephele dhcpcd[492]: eth0: accepted reconfigure key
Oct 07 12:49:58 nephele dhcpcd[492]: eth0: REPLY6 received from fe80::da58:d7ff:fe00:62e5
Oct 07 12:49:58 nephele dhcpcd[492]: eth0: adding address fd55:c3f2:2a6::4ed/128
Oct 07 12:49:58 nephele dhcpcd[492]: eth0: renew in 21600, rebind in 34560, expire in 4294967295 seconds
Oct 07 12:50:00 nephele dhcpcd[492]: control command: /sbin/dhcpcd -k eth0
Oct 07 12:50:00 nephele dhcpcd[492]: eth0: removing interface
Oct 07 12:50:00 nephele dhcpcd[492]: eth0: deleting address fd55:c3f2:2a6::4ed/128
Oct 07 12:50:00 nephele dhcpcd[492]: eth0: deleting address fd55:c3f2:2a6:0:5497:6614:6463:a307/64
Oct 07 12:50:00 nephele dhcpcd[492]: eth0: deleting route to fd55:c3f2:2a6::/64
Oct 07 12:50:00 nephele dhcpcd[492]: eth0: deleting address fe80::ba88:7327:5081:7455
This is after booting. If I log into he console then run service dhcpcd restart it all comes good. Or if I disable the wifi as outlined above, it boots fine. But what is not clear is why:

Code: Select all

Oct 07 12:50:00 nephele dhcpcd[492]: control command: /sbin/dhcpcd -k eth0
Oct 07 12:50:00 nephele dhcpcd[492]: eth0: removing interface
Also a puzzle that only a REPLY6 is cited, as the LAN seems to be operating dual stack, and IPv4 is issued and the DNS on my gateway only reports IPv4 addresses for LAN names so they are more in use still.

User avatar
bernd.wechner
Posts: 14
Joined: Wed Sep 21, 2016 10:50 am

Re: Network does not come up when restarting ...

Thu Oct 10, 2019 9:40 pm

Aaaargh, the disabling of wifi helped ... for a while. It's now booting and has no net, Then service dhcpcd status reports:

control command: /sbin/dhcpcd -k eth0

again! And service dhcpcd restart brings the net up if executed from the console.

Bananas how hard it is diagnose why the dhcpcd daemon is electing to kill eth0.

As noted before, my plan i still a complete rebuild, I have a new SD card image already, on a new SD car, and I'll need to configure it when I get time, and run with that. I might then be able to do a study fo the two SD cards (diff) to see if I can nail what went wrong to cause dhcpcd to engage in such cryptic and difficult to diagnose behaviour.

CTGreybeard
Posts: 7
Joined: Fri Nov 27, 2015 2:35 pm
Location: Western Connecticut, USA

Re: Network does not come up when restarting ...

Sat Oct 19, 2019 5:36 pm

I had an interesting (disturbing) thing happen yesterday. The Pi hosed the network switch it is attached to. The symptom was that another (Intel NUC box) reported "Unexpected reset" of the ethernet port over and over again. The other systems on the switch could not communicate. At first I thought the network adapter on the NUC box had gone sour. Then I thought that the switch (Netgear dumb switch) had gone. But only after unplugging the Pi and power cycling everything did it all come back fine. No messages.

The logs on the switch (which was frozen I discovered this morning after attaching a monitor) show nothing unusual. Some minor complaints about no IPV6 address available (which is not true, IPV6 is enabled on my network) but nothing indicating errors on eth0. I have it back up on wlan0 only for now and will test with ethernet again when things settle.

I'm not sure this is related to the original "dhcp killing eth0" problem that I did have but it's suspicious.

Return to “Networking and servers”