[Dnsmasq-discuss] hosts resolving to public addresses not private

Brent S. Elmer Ph.D. webe3vt at aim.com
Fri Feb 17 16:38:57 GMT 2012


On Fri, 2012-02-17 at 15:59 +0000, Chris Green wrote:

> > 
> > What I would like to do is set up dnsmasq to resolve local/private hosts
> > to local/private addresses not public addresses.
> > 
> Well surely dnsmasq only comes into it when someone asks it something.
> 
> What you're seeing, I *think* is the address returned by the *router*
> for the given name.
> 
> Certainly I get the LAN/internal IP addresses for all my networked
> computers behind a NAT router like yours.  However all my computers are
> set up to get both DHCP and DNS services from a single machine running
> dnsmasq. Most (but not quite all) linux and windows systems will
> correctly provide their name to the DHCP server when obtaining an IP
> address.
> 

That makes sense that computer 1 would not know anything about computer
2 or 3 other than through the router.

Computer 2 is set up use dnsmasq running on itself as the dns server
even though it gets its ip address for eth0 via the router.  dmsmasq on
computer 2 also hands out the dhcp address for wlan0 to computer 3.  So
it appears that dnsmasq running on computer 2 does not know about its
own ip address for eth0 since dnsmasq dhcp did not give out the address
the router did.  Is there a way to have dnsmasq on computer 2 to know
about its own DHCP given ip address associated with its own hostname?
Maybe by associating the NIC card address to the hostname or something?

Shouldn't computer 2 know the local ip address of computer 3 since
dnsmasq is running on computer 2 for dns lookup and also hands out the
DHCP ip address to computer 3?

Brent




More information about the Dnsmasq-discuss mailing list