[Dnsmasq-discuss] /etc/hosts query
Simon Kelley
simon at thekelleys.org.uk
Thu Jan 27 09:23:39 GMT 2011
Steve wrote:
> Not a problem, just a query, /etc/hosts on my dnsmasq server looked
> something like this:
>
> 127.0.0.1 localhost Shuttle
> 192.168.1.4 Shuttle shuttle
>
> When a client queried 'Shuttle' dnsmasq returned 127.0.0.1.
>
> I've changed the hosts file:
>
> 127.0.0.1 localhost
> 192.168.1.4 Shuttle shuttle
>
> and now it works as expected (returns 192.168.1.4)
>
> Was my hosts file wrong or have I missed something in the config? It
> seems to me that a response of 127.0.0.1 is always going to be wrong.
>
> Cheers
> Steve
>
Your /etc/hosts does look odd to me, but if there's a reason to have it
like that, you might like to look at the "localise-queries" dnsmasq
option, which will make dnsmasq's replies rather more sane in this
situation.
Cheers,
Simon.
More information about the Dnsmasq-discuss
mailing list