Configuring DNSMASQ for Internel Use and Internet Use

DNSMASQ or DNS Masquarading is a DNS proxy server used by the PublicIP system for the purpose of giving a wireless client DNS capabilities. Part of the reason the PublicIP system uses a DNS proxy server is so the wireless client does not need to configure a DNS server setting manually but instead the DHCP server giving the wireless client their IP address can also give them a specific DNS IP address setting as well.

One “feature” of dnsmasq is the ability to use local DNS IP addresses and names contained in a local file on the zonecd machine. This ability allows you to configure local servers which are NOT in the Internet DNS system to be accessed using a FQDN (Fully Qualified Domain Name) without having to use an “external” DNS server.

How, you might ask, would it be possible to configure the zonecd system to allow DNS names within the system but not have to register them in an Internet DNS server? Actually the answer is pretty simple once you understand “how” the dnsmasq proxy server works. When a request from the wireless client queries the dnsmasq server for a DNS name to IP translation the dnsmasq proxy server first checks it’s internal cache to see if it already “knows” the translation. If the requested DNS name does not match any entries within the dnsmasq cache the dnsmasq proxy server queries the next DNS server (external) for the name to address translation.

Now – here is the really cool part! When the dnsmasq proxy server first starts running it looks at a file in the /etc directory to see if there are any DNS name to IP Address translations it should know about! This is the “hook” we need to include DNS names for translation even if they are local only to our network and not listed in the Internet DNS servers per-se.

Leave a Reply

You must be logged in to post a comment.