Multi Domain Server Settings- Local Server & Local Domain

I understand that Dnsmasq is a forwarder. My question is what should my settings be if I have two different DNS domains being Nat'd by this router?

idm.nac-issa.org is my first domain and it has a dns server.
ad.nac-issa.org is my other domain and it also has a dns server.

Why two different domains you ask? Because I am running Active Directory integrated with IdM. (It's by design and intended to work that way)

Here is my present config:

config dnsmasq
	option domainneeded '1'
	option localise_queries '1'
	option rebind_protection '1'
	option rebind_localhost '1'
	option authoritative '1'
	option readethers '1'
	option leasefile '/tmp/dhcp.leases'
	option expandhosts '1'
	option localservice '0'
	option nonwildcard '0'
	option local '/idm.nac-issa.org/'
	option domain 'idm.nac-issa.org'
	list server '8.8.8.8'

I started by uising the idm domain because most of my machines are in there. I have only one ad domain server/pc right now but there may be more in the future.

A quick search suggests I can add multiple domains to my dnsmasq.conf file
https://serverfault.com/questions/872109/resolv-conf-multiple-dns-servers-with-specific-domains
Based on what the article says I'd modify /etc/dnsmasq.conf as such:

server=/idm.nac-issa.org/172.30.50.8
server=/ad.nac-issa.org/172.30..50.10

So I am just a little unsure of the correct settings for-

Should I list both domains, nothing at all, or something else?

Thanks! :slight_smile:

You can specify just the upper level domain and that should cover all of its subdomains.

Ok, so would I even need to make changes in the dnsmasq.conf file or are local and domain changes sufficient?

https://openwrt.org/docs/guide-user/base-system/dhcp_configuration#selective_dns_forwarding

Oh, I think I may have glossed over or missed some of that section based on my understanding at the time. I've got a new understanding now after re-reading it. Awsome, thanks!

1 Like

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.