I have setup a DDNS with DNS-O-MATIC using the DDNS LuCI app. I then set the DNS to the OpenDNS DNS servers, you login into your dashboard and you can do domain blocking and content filtering.
To cut a long story short I would like all my traffic to use the OpenDNS DNS's and I would like to stop any clients from overriding the DNS with a custom one like Google's (8.8.8.8).
My question is where do I actually set the DNS? There's three places I can think of:-
Network > Interfaces > WAN > Common Configuration > Advanced Settings > Use custom DNS servers
Network > Interfaces > LAN > DHCP Server > Advanced Settings > DHCP-options
Network > DHCP and DNS > Server Settings > DNS forwardings
You can use this method if you want Dnsmasq to be your primary DNS-server.
Dnsmasq will forward DNS-queries to custom DNS-servers.
It applies to both LAN-clients and local system by default.
It should be sufficient for most users.
This method is useful if you want to remove DNS-server role from Dnsmasq.
It applies only to LAN-clients.
This method is often used to provide DNS over HTTPS/TLS via Dnsmasq and dnscrypt-proxy/Stubby/Unbound.
It applies only to LAN-clients by default.
I'm trying to block use of any other DNS server. If I bypass the OpenDNS server set on the router using another DNS server on the client It defeats the objective of using OpenDNS' content filtering.
Did not know that, I will have to search the forum unless you know a link that can read about it.
Thank's I may be figuring out another way to solve the problem this weekend, I have a couple of devices that don't respect my DHCP servers wishes with "option6".
I actually know about Openwrt and it's option 6 box and I believe your second example is called tagging.
For over a year now I have been disabling Openwrt's DHCP server and using 2 Pihole"s, each running DHCP and DNS.
I just got a new Samsung S8 phone before Christmas and noticed in my logs that even though I had setup option6 on the DHCP server's to point to my PiHoles it would bypass them and go strait to Google's DNS servers every other device would use what I told it to.
This is a new feature that newer Android devices have started (for me) since Android 8 Oreo and the only cure I have found is to block Google's IPv4 and IPv6 DNS servers, This forces my phone to use my server and the iptable rules help which I might change over the weekend for a more approved method.
More and more devices in the future are going to hard code in their own preferred DNS servers.
I applaud Google for making the internet a bit easier for the masses but I wish they included a way to disable it for fringe cases like me, I have no idea what corporation's do who have strict rules about logging and what sites people are aloud to visit.
At the moment I'm back on my stock Linksys WRT1900AC firmware after I realised my ISP DNS servers weren't working on my own compiled OpenWRT build. I first tried my ISP router and everything worked so I then checked the stock firmware for my router and that seems to be working. As soon as I'm the only one on the internet I'm going to flash a stable 18.06.2 build and see if I can get the ISP DNS servers working, because that me a reason why my firewall ports weren't behaving. If no luck I will try
However, I did notice that with the the box 'Use DNS servers advertised by peer' checked and setting DHCP-option 6 to '6,208.67.220.220,208.67.222.222' actually established connections.
Also in regards to the hard encoded Google DNS servers, I can confirm that under the advanced options there is default options in the DNS server boxes.