[clug] Two networks, separate DNS: Fake Root?

Jeff jeffm at ghostgun.com
Wed May 19 18:17:00 MDT 2010


If it's just the one box (your host) you could edit /etc/hosts. 
Alternatively, if you want other machines on you local network to be 
able to find these hosts you may need to add authorative entries in the 
local dns server for the .lan zone. I'm guessing that you neither need 
or want different dns views, ie having the same name resolve to 
different IP address based on your source address. Unfortunately, I'm 
not familar with dnsmasq, but from a quick scan of the man page I'm 
guessing you can either add the hosts to /etc/hosts or create a another 
hosts file and use the *-H, --addn-hosts=<file>* option if you wish to 
keep the file separate for sys admining reasons.

Jeff.

On 20/05/10 9:46 AM, Alex Satrapa wrote:
> Just a quickie: I have two networks to connect to - one is a desktop lab consisting of an OpenWRT hosting its own DNS, with a bunch of lab equipment that I want to talk to, the other is the network I share with other computers and it's through this that I get to the Internet.
>
> In this environment, it would be nice if "host www.example.com" would resolve "real world" addresses, while "host equipmentX.lan" would resolve desktop lab addresses.
>
> Routing is already taken care of with a pretty simple routing table, but the DNS library only wants to talk to one host for DNS requests.
>
> Is there a way I can manipulate the DNS tables (I'm using dnsmasq at the moment) to fake a root server which says "for the '.lan' TLD, talk to that server, for everything else ask the normal server"?
>
> Perhaps I need to go work on my DNS-fu =(
>
> Alex
>
>    



More information about the linux mailing list