Discussion:
[Dnsmasq-discuss] Just listen on one interface
Mauricio Tavares
2018-07-10 17:46:32 UTC
Permalink
How much do I need in dnsmasq.conf to tell it to

1. Only do your thing on eth2. Leave other interfaces alone.
1.1. Listen only on eth2 only. I take this is done with

bind-interfaces
interface=eth2

1.2. Do not try to edit the /etc/resolv.conf file. I do want to keep
the DNS on that port completely separate from the one used on the rest
of the interfaces. Right now it is taking over:

cat /etc/resolv.conf
# Dynamic resolv.conf(5) file for glibc resolver(3) generated by resolvconf(8)
# DO NOT EDIT THIS FILE BY HAND -- YOUR CHANGES WILL BE OVERWRITTEN
nameserver 127.0.0.1
search domain.com

1.3. Listen to dhcp queries. I have

# DHCP IP range
dhcp-range=192.168.0.150,192.168.0.250,12h

And it is not answering any request.
john doe
2018-07-10 18:53:35 UTC
Permalink
Post by Mauricio Tavares
How much do I need in dnsmasq.conf to tell it to
1. Only do your thing on eth2. Leave other interfaces alone.
1.1. Listen only on eth2 only. I take this is done with
bind-interfaces
interface=eth2
Should be enough; do you have multiple IPs on the same interface?
Post by Mauricio Tavares
1.2. Do not try to edit the /etc/resolv.conf file. I do want to keep
the DNS on that port completely separate from the one used on the rest
cat /etc/resolv.conf
# Dynamic resolv.conf(5) file for glibc resolver(3) generated by resolvconf(8)
# DO NOT EDIT THIS FILE BY HAND -- YOUR CHANGES WILL BE OVERWRITTEN
nameserver 127.0.0.1
search domain.com
Dnsmasq has nothing to do with resolvconf(8).
You will need to disable resolvconf(8) in order to avoid resolv.conf(5)
to be overwritten.
Post by Mauricio Tavares
1.3. Listen to dhcp queries. I have
# DHCP IP range
dhcp-range=192.168.0.150,192.168.0.250,12h
And it is not answering any request.
This option will enable dhcp server for that range, thus clients should
get a dhcp lease if they are on the subnet given by eth2.

http://www.thekelleys.org.uk/dnsmasq/docs/dnsmasq-man.html
--
John Doe
Continue reading on narkive:
Loading...