So I've been trying to trouble-shoot this myself for weeks.
I have a Pi3 (and a Pi4, though the 4 causes no issues).
My Pi3 is fully up to date, on Raspbian Linux 4.19.81-v7+ This issue persisted prior to updates too.
The Pi serves the following tasks:
- Runs a cron job for a twitter bot
- Runs a push notification server for Apple PNS
- Runs PiHole (also acts as my DHCP and DNS server in my home)
- Executes a DynamicDNS job to update my domain registrar with my public IP
- SSH/VPN endpoint as I have a port forwarded to this device from my router
The load on the device is like 0.01 0.02 0.01 most of the time
Normally this all works perfectly for 3-6 days or so, then at some random point in time, I notice my MacBook or PC will stop working and it's clearly because the Pi is not serving DNS requests. I then notice that renewing a DNS lease does nothing, so the Pi has stopped serving these functions.
Also the Pi is not pingable and will not respond to SSH requests.
So I've been trawling through the logs and the unusual thing (to me) is that there are still items being printed during the "downtime", I have included the logs here below in a pastebin if anyone would like to view them.
Because my twitter bot runs every 10 mins, I know that this log above captures the 'falling over' about between 1am and 2am or so.
I did consider a hardware issue but I don't think it is one. It's really weird, can anyone help?
Nov 20 01:12:19 raspberrypi dhcpcd[466]: wlan0: carrier lost
Nov 20 01:12:19 raspberrypi dhcpcd[466]: wlan0: deleting address fe80::6bb:e56d:3d5a:8974
Nov 20 01:12:19 raspberrypi avahi-daemon[385]: Withdrawing address record for fe80::6bb:e56d:3d5a:8974 on wlan0.
Nov 20 01:12:19 raspberrypi avahi-daemon[385]: Leaving mDNS multicast group on interface wlan0.IPv6 with address fe80::6bb:e56d:3d5a:8974.
Nov 20 01:12:19 raspberrypi avahi-daemon[385]: Interface wlan0.IPv6 no longer relevant for mDNS.
Nov 20 01:12:19 raspberrypi avahi-daemon[385]: Withdrawing address record for 192.168.0.248 on wlan0.
Nov 20 01:12:19 raspberrypi avahi-daemon[385]: Leaving mDNS multicast group on interface wlan0.IPv4 with address 192.168.0.248.
Nov 20 01:12:19 raspberrypi avahi-daemon[385]: Interface wlan0.IPv4 no longer relevant for mDNS.
Nov 20 01:12:19 raspberrypi dhcpcd[466]: wlan0: deleting route to 192.168.0.0/24
Nov 20 01:12:19 raspberrypi dhcpcd[466]: wlan0: deleting default route via 192.168.0.1
Nov 20 01:12:19 raspberrypi wicd[383]: sending commands to master dhcpcd process
Nov 20 01:12:19 raspberrypi dhcpcd[31919]: sending commands to master dhcpcd process
Nov 20 01:12:19 raspberrypi dhcpcd[466]: control command: /sbin/dhcpcd -k wlan0
Nov 20 01:12:19 raspberrypi dhcpcd[466]: wlan0: removing interface
Nov 20 01:12:20 raspberrypi kernel: [344915.570800] IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready
Nov 20 01:12:20 raspberrypi kernel: [344915.570988] brcmfmac: power management disabled
Nov 20 01:12:20 raspberrypi wicd[383]: sending commands to master dhcpcd process
Nov 20 01:12:20 raspberrypi dhcpcd[31941]: sending commands to master dhcpcd process
Nov 20 01:12:20 raspberrypi dhcpcd[466]: control command: /sbin/dhcpcd -k docker0
Nov 20 01:12:20 raspberrypi dhcpcd[466]: docker0: removing interface
Nov 20 01:12:20 raspberrypi avahi-daemon[385]: Withdrawing address record for 172.17.0.1 on docker0.
Nov 20 01:12:20 raspberrypi avahi-daemon[385]: Leaving mDNS multicast group on interface docker0.IPv4 with address 172.17.0.1.
Nov 20 01:12:20 raspberrypi avahi-daemon[385]: Interface docker0.IPv4 no longer relevant for mDNS.
Nov 20 01:12:20 raspberrypi kernel: [344915.833591] IPv6: ADDRCONF(NETDEV_UP): docker0: link is not ready
Nov 20 01:12:20 raspberrypi wicd[383]: Failed to connect to non-global ctrl_ifname: docker0 error: No such file or directory
Nov 20 01:12:24 raspberrypi kernel: [344919.963658] IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready
Nov 20 01:12:24 raspberrypi kernel: [344919.963694] brcmfmac: power management disabled