Override default DNS server for specific domain queries?

Hey fellas...

I have a peculiar situation. My ISP throttles some servers and allows full speed on others. That's fine, as long as you use their DNS servers, you'll always be on the fastest servers. Note that the fastest servers don't have the lowest ping times, and the speed difference is HUGE so really need to stick with default.

However, it takes ages to propagate dns changes to this default server. Instead of 1-2min for most public dns servers it can take 30min for my default server.

Can I set an alternate dns server IP for use ONLY with my specified domains?

What's the easiest way to do it? Thanks!


address=, if I remember correctly.

editing the routers hosts file should work too.


1 Like

You sir, are a life saver! :tulip:

Luci doesn't have any of that, right?

Network -> DHCP and DNS -> Hostnames

quickest, as long as you only have a handful of hosts to (re)map.


Thanks. However it appears that those hostnames can only be bound to a static ip.

My domains change IPs daily. I guess I need to configure dnsmasq somehow, and do it so that the default servers are used except for a few domains.

hard to use non-dynamic DNS records with dynamic IPs :wink:

how do you see this, though ping or nslookup ?

pretty sure dnsmasq can be set to use different upstream servers based on FQDN.

but I'd just run a cron job with a fitting frequency, nslookuping the hosts, and
updating the dnsmasq specific hosts file, with the IPs reported back.

1 Like

I really apreciate your patience frollic. Your handle has reached legendary status in my book! :hugs:

I notice a cutout in service for around 20min every day when the IP updates. I ping my dns and it gives the wrong (older) IP. I query another dns and it gives the right IP. After a while they match.

Aha, cron job. I see. That would need to run every 5 min or something. Not a bad idea. I just wonder if there's a better solution. Hmm..

like I said, dnsmasq can do it.


ajax.googleapis.com will always be queried at

1 Like

On the DHCP page you can add to the DNS forwardings option like /example.org/ to forward example.org queries to DNS server


You guys are the best. I had no idea that what I was asking for was called "DNS forwarding". There it is in luci and it seems to be working.

Much appreciated! Now I need to figure out which dns server updates the fastest and use that. How exciting!

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