[plug] DNS - returning correct ip address based on source
Patrick Coleman
blinken at gmail.com
Mon Jul 13 15:57:35 WST 2009
On Mon, Jul 13, 2009 at 1:59 PM, Carl Gherardi<carl.gherardi at gmail.com> wrote:
> Hi All,
>
> Working on a WAN and i'd like the local DNS servers to return a
> different IP based on which IP range the clients have DHCP'd from.
Aha, someone else does this! I went through exactly this problem
earlier in the year. BIND views will do what you want, but if you have
more than a couple of subnets it gets messy very quickly (lots of
duplicated information).
What I ended up doing was using dnsmasq - it's a little DNS server
designed for home ADSL setups, but it seems to perform well in a big
environment. It also has the nifty feature where if you define
multiple IPs for a given hostname it will return the appropriate entry
if one exists for the subnet the request came from, and will return
all the entries (as BIND does) otherwise.
I've set it up forwarding unknown requests to our BIND setup (make
sure you disable dnsmasq's cache, otherwise you'll get confused), and
defined just the multihomed hosts in dnsmasq. It works great.
-Patrick
--
http://www.labyrinthdata.net.au - WA Backup, Web and VPS Hosting
More information about the plug
mailing list