In my environment I have a tight set of rule for DNS allowing queries from my internal DNS servers to only Quad9 DNS servers.
On my network there is a gaming PC and a TV which insist on querying 8.8.8.8. To avoid these connection attempts being logged by my DNS blocking rules, I've just created a rule to redirect these request to my internal DNS servers.
I am running OPNsense 26.1.5 and created one rule in Firewall: NAT: Destination NAT.
The two networks where these queries originate are in my UNTRUSTED firewall group.
A rule would appear like in the image Destination NAT Rule. I've included the relevant settings for this rule too.
You may already have a rule to allow DNS traffic to 127.0.0.1. If not, I expect the Default pass rule to work here, otherwise in the settings under Options, you could change the Firewall rule to pass.
On my network there is a gaming PC and a TV which insist on querying 8.8.8.8. To avoid these connection attempts being logged by my DNS blocking rules, I've just created a rule to redirect these request to my internal DNS servers.
I am running OPNsense 26.1.5 and created one rule in Firewall: NAT: Destination NAT.
The two networks where these queries originate are in my UNTRUSTED firewall group.
A rule would appear like in the image Destination NAT Rule. I've included the relevant settings for this rule too.
You may already have a rule to allow DNS traffic to 127.0.0.1. If not, I expect the Default pass rule to work here, otherwise in the settings under Options, you could change the Firewall rule to pass.
"