Unbound re-initializing when HA Backup is rebooted

Started by quantumjohnny, January 29, 2025, 04:26:53 PM

Previous topic - Next topic
January 29, 2025, 04:26:53 PM Last Edit: January 31, 2025, 08:58:35 AM by quantumjohnny Reason: Changed problem description.
Hi,

I have two OPNsense routers configured with High Availability. Unbound is running as DNS resolver for the network.
Whenever I reboot one of the machines, Unbound seems to "restart" on the other machine. For my network, the DNS is unavailable as long as Unbound needs. Previously that has been some minutes because I had configured some blocklists that it took a while to load. Now it still takes ~20s which is not too bad but I don't see why it is doing it.

When I reboot the BACKUP device, why would Unbound reload? (I'd also question why it would reload when the MASTER device becomes unavailable since it seems to defeat the purpose of HA).

All other services perform nicely whenever one HA device becomes unavailable but Unbound does not.

In the logs of Unbound on the MASTER device I only the following when I reboot the BACKUP device:
Closing logger
notice: init module 0: python
daemonize unbound dhcpd watcher
notice: init module 1: validator
notice: init module 2: iterator
Backgrounding unbound logging backend

This sounds like Unbound is re-initializing. Is there a way to prevent this? For me this is a serious issue because it means when I run a major update on the Backup device it should not affect my Master device. And when I enable the blacklists, not having DNS for a few minutes is not really acceptable in our network.

Would be happy for your support/ideas/insights. Thanks!