Need Router to Act as Secondary DNS Server

Post new topic   Reply to topic    DD-WRT Forum Forum Index -> Broadcom SoC based Hardware
Author Message
djtech2k
DD-WRT Novice


Joined: 08 Feb 2009
Posts: 30

PostPosted: Tue Oct 08, 2013 23:37    Post subject: Need Router to Act as Secondary DNS Server Reply with quote
I have an Active Directory DNS Server that runs resolution for my household. I would like to have a secondary DNS Server online, so I would like to use my router with DD-WRT to be that DNS Server.

What I would like to do is have my router be the secondary DNS server and just host the records that are on the primary DNS server, kinda like a secondary zone. All other traffic can be forwarded out to the internet. If thats not possible, then I would like to be able to setup a conditional forwarder on the router so that if a request comes in for "domain.local", then it can just firward that traffic to my "domain.local" DNS server.

Does anyone know how to configure this?

I am using an Asus RT-N16 with version DD-WRT v24-sp2 (08/07/10) mini - build 14896.
Sponsor
djtech2k
DD-WRT Novice


Joined: 08 Feb 2009
Posts: 30

PostPosted: Wed Oct 09, 2013 20:38    Post subject: Reply with quote
I have read many threads similar to this, but nothing has worked. My primary DNS server on my network dos all local resolution and forwards all other traffic outbound. My DHCP clients get my DNS Server as their primary DNS Server. The DHCP clients get my router address as the secondary just in case my DNS server is offline.

The problem is that fairly often my clients start using the secondary DNS server (router), which cannot resolve any of my internal network names. So that starts causing failures.

I need to get this setup so that if my primary DNS server is offline, then internal and external name resolution will still work.
crashfly
DD-WRT Guru


Joined: 24 Feb 2009
Posts: 2023
Location: Sol System > Earth > USA > Arkansas

PostPosted: Thu Oct 10, 2013 3:44    Post subject: Reply with quote
You should consider using dnsmasq on the router for local name resolution. There are a couple of articles in the DD-WRT wiki about dnsmasq and how to set it up to resolve "specific" addresses as well as local addresses.
_________________
E3000 22200M KongVPN K26
WRT600n v1.1 refirb mega 18767 BS K24 NEWD2 [not used]
WRT54G v2 16214 BS K24 [access point]

Try Dropbox for syncing files - get 2.5gb online for free by signing up.

Read! Peacock thread
*PLEASE* upgrade PAST v24SP1 or no support.
djtech2k
DD-WRT Novice


Joined: 08 Feb 2009
Posts: 30

PostPosted: Thu Oct 10, 2013 12:59    Post subject: Reply with quote
I run my home network along with multiple test lab networks from 1 Active Directory. So I naturally am using AD Integrated DNS for those purposes. I need to keep that running for name resolution for the domain I host. All internet resolution needs to be forwarded outbound.

I would like to have dnsmasq either host a copy of my internal DNS zone OR at the least just forward any requests it receives for my internal domain to my internal DNS server.

I have read lots of stuff, but I am not able to get it to work the way I need it to. Frankly, its almost impossible to eve test it because any change i make gets overwritten when the router restarts. I have tried adding all kinds of options into the dnsmasq box in the UI, but nothing seems to work.

At a minimum, if the router could point any requests for "domain.local" to a specific IP, then that would at least be a little help.
djtech2k
DD-WRT Novice


Joined: 08 Feb 2009
Posts: 30

PostPosted: Fri Oct 11, 2013 14:34    Post subject: Reply with quote
Ok, so I may have something working. It looks ok now, but you guys let me know if this sounds bad.

I Enabled local DNS under the services tab. In the DNSMASQ options, I put in my home DNS server like this:

server=/domain.local/10.10.10.10

Then I created a "startup script" under Administration > Commands. The script basically removed the rebind command that is always there. I do not have a button to remove it even though my DD-WRT version appears to be up to date on the site. Anyway, here is the startup script:

Code:

grep -v "stop-dns-rebind" /tmp/dnsmasq.conf > /tmp/test-dnsmasq.conf
cp /tmp/test-dnsmasq.conf /tmp/dnsmasq.conf

killall dnsmasq
dnsmasq --conf-file=/tmp/dnsmasq.conf


How does this look? Does this present any problem or danger? I am a very novice Linux guy, so this is not my area of expertise.[/code]
Display posts from previous:    Page 1 of 1
Post new topic   Reply to topic    DD-WRT Forum Forum Index -> Broadcom SoC based Hardware All times are GMT

Navigation

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum