ISC DHCP seesm to keep resetting itself

Started by Oli_wachno, December 09, 2025, 03:26:49 PM

Previous topic - Next topic
Hi there,

I have been running opnsense on a Protectli VP4650 since around mid of October now.(opnsense Version 25.7.9 Architecture amd64)

During the last weeks, my home network kept failing (as in windows complaining it has lost internet connection) on wired as well as on un-wired connections.

I think I have tracked down the cause of these connection losses, but I can't explain why this happens...

I can see errors occuring on the log like
2025-12-09T07:33:41 Error  dhcpd dhcp.c:4164: Failed to send 301 byte long packet over vlan0.2 interface.
2025-12-09T07:33:41 Error dhcpd send_packet: No buffer space available

Predceeding this, I can see on the inforamtion log something that is IMHO dhcpd restarting multiple times

025-12-09T07:33:42 Informational dhcpd All rights reserved.
2025-12-09T07:33:42 Informational dhcpd Copyright 2004-2022 Internet Systems Consortium.
2025-12-09T07:33:42 Informational dhcpd Internet Systems Consortium DHCP Server 4.4.3-P1
2025-12-09T07:33:41 Error dhcpd dhcp.c:4164: Failed to send 301 byte long packet over vlan0.2 interface.
2025-12-09T07:33:41 Error dhcpd send_packet: No buffer space available
2025-12-09T07:33:41 Informational dhcpd DHCPACK on 192.168.2.14 to 68:c6:ac:fd:83:e7 (tg-lenovo) via vlan0.2
2025-12-09T07:33:41 Informational dhcpd DHCPREQUEST for 192.168.2.14 from 68:c6:ac:fd:83:e7 via vlan0.2
2025-12-09T07:33:40 Informational dhcpd Server starting service.
2025-12-09T07:33:40 Informational dhcpd Sending on   Socket/fallback/fallback-net
2025-12-09T07:33:40 Informational dhcpd Sending on   BPF/vlan0.2/64:62:66:22:e8:ef/192.168.2.0/24
2025-12-09T07:33:40 Informational dhcpd Listening on BPF/vlan0.2/64:62:66:22:e8:ef/192.168.2.0/24
2025-12-09T07:33:40 Informational dhcpd Sending on   BPF/vlan0.3/64:62:66:22:e8:ef/192.168.3.0/24
2025-12-09T07:33:40 Informational dhcpd Listening on BPF/vlan0.3/64:62:66:22:e8:ef/192.168.3.0/24
2025-12-09T07:33:40 Informational dhcpd Sending on   BPF/vlan0.4/64:62:66:22:e8:ef/192.168.4.0/24
2025-12-09T07:33:40 Informational dhcpd Listening on BPF/vlan0.4/64:62:66:22:e8:ef/192.168.4.0/24
2025-12-09T07:33:40 Informational dhcpd Sending on   BPF/vlan0.10/64:62:66:22:e8:ef/192.168.10.0/24
2025-12-09T07:33:40 Informational dhcpd Listening on BPF/vlan0.10/64:62:66:22:e8:ef/192.168.10.0/24
2025-12-09T07:33:40 Informational dhcpd Sending on   BPF/vlan0.1/64:62:66:22:e8:ef/192.168.1.0/24
2025-12-09T07:33:40 Informational dhcpd Listening on BPF/vlan0.1/64:62:66:22:e8:ef/192.168.1.0/24
2025-12-09T07:33:40 Informational dhcpd Wrote 40 leases to leases file.
2025-12-09T07:33:40 Informational dhcpd Wrote 0 new dynamic host decls to leases file.
2025-12-09T07:33:40 Informational dhcpd Wrote 0 deleted host decls to leases file.
2025-12-09T07:33:40 Informational dhcpd For info, please visit https://www.isc.org/software/dhcp/
2025-12-09T07:33:40 Informational dhcpd All rights reserved.
2025-12-09T07:33:40 Informational dhcpd Copyright 2004-2022 Internet Systems Consortium.
2025-12-09T07:33:40 Informational dhcpd Internet Systems Consortium DHCP Server 4.4.3-P1
2025-12-09T07:33:40 Informational dhcpd PID file: /var/run/dhcpd.pid
2025-12-09T07:33:40 Informational dhcpd Database file: /var/db/dhcpd.leases
2025-12-09T07:33:40 Informational dhcpd Config file: /etc/dhcpd.conf
2025-12-09T07:33:40 Informational dhcpd For info, please visit https://www.isc.org/software/dhcp/
2025-12-09T07:33:40 Informational dhcpd All rights reserved.
2025-12-09T07:33:40 Informational dhcpd Copyright 2004-2022 Internet Systems Consortium.
2025-12-09T07:33:40 Informational dhcpd Internet Systems Consortium DHCP Server 4.4.3-P1
2025-12-09T07:33:13 Informational dhcpd Server starting service.
2025-12-09T07:33:13 Informational dhcpd Sending on   Socket/fallback/fallback-net
2025-12-09T07:33:13 Informational dhcpd Sending on   BPF/vlan0.2/64:62:66:22:e8:ef/192.168.2.0/24
2025-12-09T07:33:13 Informational dhcpd Listening on BPF/vlan0.2/64:62:66:22:e8:ef/192.168.2.0/24
2025-12-09T07:33:13 Informational dhcpd Sending on   BPF/vlan0.3/64:62:66:22:e8:ef/192.168.3.0/24
2025-12-09T07:33:13 Informational dhcpd Listening on BPF/vlan0.3/64:62:66:22:e8:ef/192.168.3.0/24
2025-12-09T07:33:13 Informational dhcpd Sending on   BPF/vlan0.4/64:62:66:22:e8:ef/192.168.4.0/24
2025-12-09T07:33:13 Informational dhcpd Listening on BPF/vlan0.4/64:62:66:22:e8:ef/192.168.4.0/24
2025-12-09T07:33:13 Informational dhcpd Sending on   BPF/vlan0.10/64:62:66:22:e8:ef/192.168.10.0/24
2025-12-09T07:33:13 Informational dhcpd Listening on BPF/vlan0.10/64:62:66:22:e8:ef/192.168.10.0/24
2025-12-09T07:33:13 Informational dhcpd Sending on   BPF/vlan0.1/64:62:66:22:e8:ef/192.168.1.0/24
2025-12-09T07:33:13 Informational dhcpd Listening on BPF/vlan0.1/64:62:66:22:e8:ef/192.168.1.0/24
2025-12-09T07:33:13 Informational dhcpd Wrote 40 leases to leases file.
2025-12-09T07:33:13 Informational dhcpd Wrote 0 new dynamic host decls to leases file.
2025-12-09T07:33:13 Informational dhcpd Wrote 0 deleted host decls to leases file.
2025-12-09T07:33:13 Informational dhcpd For info, please visit https://www.isc.org/software/dhcp/
2025-12-09T07:33:13 Informational dhcpd All rights reserved.
2025-12-09T07:33:13 Informational dhcpd Copyright 2004-2022 Internet Systems Consortium.
2025-12-09T07:33:13 Informational dhcpd Internet Systems Consortium DHCP Server 4.4.3-P1
2025-12-09T07:33:13 Informational dhcpd PID file: /var/run/dhcpd.pid
2025-12-09T07:33:13 Informational dhcpd Database file: /var/db/dhcpd.leases
2025-12-09T07:33:13 Informational dhcpd Config file: /etc/dhcpd.conf
2025-12-09T07:33:13 Informational dhcpd For info, please visit https://www.isc.org/software/dhcp/
2025-12-09T07:33:13 Informational dhcpd All rights reserved.
2025-12-09T07:33:13 Informational dhcpd Copyright 2004-2022 Internet Systems Consortium.
2025-12-09T07:33:13 Informational dhcpd Internet Systems Consortium DHCP Server 4.4.3-P1
2025-12-09T07:30:00 Informational dhcpd DHCPACK on 192.168.4.31 to 94:27:70:77:2c:b6 via vlan0.4
2025-12-09T07:30:00 Informational dhcpd DHCPREQUEST for 192.168.4.31 from 94:27:70:77:2c:b6 via vlan0.4



In this particular case, this happen 22 times until the log calms down....

Any advice on how to investigate this issue?

Cheers
Oli


To add some more information:
All clients are connected to the FW via a LAG (two physical ports)

Yesterday, I exchanged the network cables from the FW to the switch.
Ran stable over night, no errors anymore, yet the original problem still persists.
BTW, I also spend two hours trying to get KEA up instead, but failed miserably, since my UniFi APs wouldn't get IP addresses.

I have read some Option 43 discussions, yet I am not having the problem of adoption problems, the APs don't seem to get IP addresses at all
BTW... still on IPv4

Happy New Year everyone!

For future reference, here are my findings:
Turned out that the issue wasn't related to ISC DHCP resetting itself. Instead the whole system was doing random reboots....

I have tried a fresh reinstall, but the issue wasn't solved... after some research with no real results, I stumbled over

https://eu.protectli.com/reduce-emmc-wear/

Since having nothing left to loose, I just tried disabling the logging as described in this article.

Now, some 48hrs later, my firewall is still running smoothly.

If this has really been the cause, it means that the standard logging configuration in opnsense causes issues on devices with EMMC memory... at least this is my current interpretation


Not only logging, but in particular RRD induces a lot of wear on the storage. It is for this reason you should use storage with high TBW.

However, that should not lead to random reboots unless the storage is really already damaged. You should use a ZFS install, because with that, you would notice if there were bad blocks. I would not trust a firewall system with potentially defective hardware.
 
Intel N100, 4* I226-V, 2* 82559, 16 GByte, 500 GByte NVME, ZTE F6005

1100 down / 800 up, Bufferbloat A+