Posted: Wed Dec 01, 2021 22:02 Post subject: dnsmasq with dhcp forwarder
Hi.
I have all my DHCP on a windows server box (I'm loathed to change it as there's a lot of static mappings)
I'm running dd-wrt build 47695 on my Asus RT-AC68U C1
I'm trying to get dnsmasq running for DNS only to allow me to set some local dns entries.
Since I have dhcp set to forwarding rather than a local server, I don't get the tick box to use Dnsmasq for DNS.
dnsmasq is configured as follows, but just does not respond to dns queries. (If i switch on smartdns, I can get that working)
listen-address=192.168.1.254 # My router's IP
server=8.8.8.8 #Google
address=/mydomain.duckdns.org/192.168.1.45 #local address i want to use in preference to resolved address
Any clues or am I flogging a dead horse by having DHCP elsewhere?
Joined: 08 May 2018 Posts: 14217 Location: Texas, USA
Posted: Thu Dec 02, 2021 3:50 Post subject:
1) You don't need to use dhcp forwarder (and shouldn't).
2) Dnsmasq will normally listen on the router's IP by default.
3) If you are going to specify dns servers, you have the option of using the 3 static entries or no-resolv directive if you are going to use server= lines; to ensure that you don't use your ISP dns servers, set ignore wan dns.
4) You should be able to configure your windows dhcp server to hand out (dns server and) router/gateway IP address(es). I doubt anything has changed since NT4 server. _________________ "Life is but a fleeting moment, a vapor that vanishes quickly; All is vanity"
Contribute To DD-WRT Pogo - A minimal level of ability is expected and needed... DD-WRT Releases 2023 (PolitePol)
DD-WRT Releases 2023 (RSS Everything)
----------------------
Linux User #377467 counter.li.org / linuxcounter.net
I quote, "dnsmasq is a dns server" .
The check box you mean is for the dhcp server. Dhcp forwarder will still work but you must improve dns and dhcp at the network level. Routing dhcp is trickier without the server. It's not too tricky though. I use the "lan domain" option. *. yourdomian.com .
Once you prompted me that I don't need the DNS forwarder any more (it came from a time when I was trying to set up a guest network) - I was able to configure dnsmasq and it sprang into life (using nslookup to specify the server)
Once I'm happy it's doing what I expect, I'll update the windows DHCP server to supply the router IP as DNS.
The Server= line was intended to provide dnsmasq with a relay point - is this wrong/not necessary? Will it relay to the DNS root servers by default?