Open kriansa opened 2 weeks ago
I have just recently experienced the same issue. I cannot pinpoint when it started, however, as I have backup DNS that my system reverted to without me knowing. The outcome (Unbound shutting down) is the same if one were to use a different IP address in step #3 listed above.
most likely cause is an overlapping entry (e.g. *.my.org and host.my.org assigned), these are difficult to detect upfront and if I remember correctly will break startup.
Isn't "*" the reason why domain overrides exist?
most likely cause is an overlapping entry (e.g. *.my.org and host.my.org assigned), these are difficult to detect upfront and if I remember correctly will break startup.
Confirmed, I just tested, and this seems to be the pre-requisite for this issue. I updated the reproducing steps.
I dislike being on an island when it comes to error reporting. In almost every case it means I'm doing something wrong and/or stupid. My wildcard entry on Host Domains is the only entry on my list; no overlapping entries. I just have the one wildcard entry directed to my reverse proxy for keep-it-inside-LAN DNS overrides. (I think this is one application of this Opnsense functionality, yes?) As soon as I hit apply, it thinks for a bit and then Unbound turns off. When I disable it Unbound immediately turns back on.
check the logs??
@collinthorn are you doing this for the same domain your OPNSense device is, and thus generated an A record for itself?
@collinthorn are you doing this for the same domain your OPNSense device is, and thus generated an A record for itself?
Indeed this was my problem. I cannot speak to the more detailed use-case that is failing @kriansa in the original posting, but my Unbound no longer fails after changing my OPNsense domain.
In case of future searches: the origin of my problem was that I had attempted a Services/Unbound DNS/Overrides override for a domain that was identified as my Opnsense device domain in System/Settings/General/Domain.
It makes sense now that I see the fix but it wasn't intuitively obvious to me when I was attempting it. I very much appreciate the experts who chimed in. Cheers.
Important notices
Before you add a new report, we ask you kindly to acknowledge the following:
Describe the bug
Adding a DNS entry named * (wildcard) on a domain with an existing host override will be allowed by UI but will break Unbound initialization, thus making it immediately offline after applying the change.
According to the manual, wildcards should be accepted as host names for host overrides.
To Reproduce
Steps to reproduce the behavior:
drill @routerip abc.opnsense.com
to see that it returns an entry to 127.0.0.1Expected behavior
Unbound should stay up, and a subsequent
drill xyz.opnsense.com
should return an entry to '127.0.0.1'.Environment
I don't think it's relevant.