[Dnsmasq-discuss] dhcp doesn't work with dnsmasq in multi ip environment

Kolmann Philipp kolmann at zid.tuwien.ac.at
Tue Aug 9 08:04:51 BST 2016


Hi Simon,

thanks for your answer. The Default Gateway (172.17.32.1) and the 172.18.92.60 are on the same interface of one linux server. Strangely if I use isc-dhcp-server, it works, but with dnsmasq it doesn't work. That are the two wireshark protocols I attached to my first mail.

The only difference I could spot, was that with isc-dhcpd the server-identifier is set to the same IP as the source address of the package and with dnsmasq I see that the DHCP ACK Package comes from the primary interface address (172.18.92.60) and the server-identifier is set to the Gateway IP (172.17.32.1).

So I was wondering, if I could specify the server-identifier via config file?

Thanks
Philipp

-----Ursprüngliche Nachricht-----
Von: Dnsmasq-discuss [mailto:dnsmasq-discuss-bounces at lists.thekelleys.org.uk] Im Auftrag von Simon Kelley
Gesendet: Freitag, 05. August 2016 17:35
An: dnsmasq-discuss at lists.thekelleys.org.uk
Betreff: Re: [Dnsmasq-discuss] dhcp doesn't work with dnsmasq in multi ip environment

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256



The DHCP client, once it establishes contact with the DHCP server will
need to be able to send packet to the address in the DHCP-identifier
option. This implies that once the client is set up and has an IP
address and default route, it can talk to the server-identifier
address (ie 172.18.92.60) Is that the case? If not that would explain
what you're seeing.

Cheers,

Simon.




On 04/08/16 08:45, Philipp Kolmann wrote:
> Hi,
> 
> I have a special setup with two IP Subnets on one Interface:
> 
> 3: eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc
> pfifo_fast state UP group default qlen 1000 inet 172.18.92.60/24
> brd 172.18.92.255 scope global eth1 valid_lft forever preferred_lft
> forever inet 172.17.32.1/24 brd 172.17.32.255 scope global eth1:0 
> valid_lft forever preferred_lft forever
> 
> primary IP is 172.18.92.60, secondary is 172.17.32.1
> 
> I now want to use dnsmasq to supply clients identified by MAC
> Address an IP address in the secondary range:
> 
> interface=eth1 dhcp-range = set:power, 172.17.32.0, static,
> 255.255.255.0 dhcp-host = set:power, 00:19:32:00:8f:90, fh-tuck-1p,
> 172.17.32.8,12h dhcp-option = tag:power, option:ntp-server,
> 172.17.32.1 dhcp-option = tag:power, option:dns-server,
> 172.17.32.1 dhcp-option = tag:power, option:router,  172.17.32.1
> 
> 
> My issue is now, that the Network-enabled power distribution unit
> (GUDE EXPERT POWER CONTROL NET D4X 1200) seems to have an issue if
> dnsmasq is providing an IP address from the secondary range. If I
> turn primary and secondary IP, it works.
> 
> I have now also tested with ISC DHCP server and there the PDU
> accepts the IP Address. The only difference that i found is the
> following:
> 
> The Source IP of the packets is the primary of the interface:
> 172.18.92.60
> 
> in ISC DHCP the option 54 IP (DHCP Server Identifier) is the
> primary, 172.18.92.60
> 
> in dnsmasq the option 54 IP is the secondary: 172.17.32.1
> 
> It seems that this is a discrepancy and therefore the PDU doesn't
> accept the IP address, since the IP source and the DHCP Server
> Identifier do not match.
> 
> Find attached the wireshark logs.
> 
> I tried to set
> 
> dhcp-option = tag:power, 54,  172.18.92.60
> 
> but this option is not used for the packet.
> 
> Any help is appriciated. Thanks Philipp
> 
> 
> 
> _______________________________________________ Dnsmasq-discuss
> mailing list Dnsmasq-discuss at lists.thekelleys.org.uk 
> http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss
> 
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.22 (GNU/Linux)

iQIcBAEBCAAGBQJXpLI/AAoJEBXN2mrhkTWi4vkP/jW109QkX/s5BLoBLiTMNKP1
cdf84Ogp+iZLbbPLqkOiLFhsNWeeUcLJ6SXEPC1qqdzbPKf36j3TF/dCNwQF7vkZ
sCc3kR8bnqyyXegoq/uAOU4ykHA2wR7g/VX7adQqmX1giRsrQP6TXv9URapppjSs
fGaC2Am25AhN8NC6u6K2ZkXTN8KAwr8LdgGm13O31VgEsZ/2mBxEqP8qBgZ9zv28
SYKw51cMpjpcyp7mZ0olOlsQGhH9VZsVzfgcF62Ewq32BhavOM3xS2I5sagCWvJp
hBuUN7Z7vdbWb90PKsBKzDPs48kaEDMcbGX47vyiaPjPThKHHpTLhltAXs44/pTz
t76rJyrGCJq6XWqNgu2TYJxgXNqDsgbCikj+JOvFkvZAbCkeSRFE/fiuijM50sIZ
CJB0M0v1yuVWvFK+dqqHXPreAZchTzKFlfpJLb+kCrcPZpaX1Z6BuU8MhunBRd62
g4sFbp/F4hLEcTKKRKj7wq365vV6uyRNI4lGeNX01qWVkbYeaR1ole0p07IiC93H
jMKhAt+w4ECbXEvIelH/tn0E2ytZwInVbvWtjDzzwVZDDXHxvXfFz6Mu7qT9+FAs
43LztA3f+TfzxuJawKnjpNYcWvgX1HBwcHy1TpezaftwEGJIc+rFW2BQgjy1PVyY
vxpA234EG82ns6XlypD/
=fFt+
-----END PGP SIGNATURE-----

_______________________________________________
Dnsmasq-discuss mailing list
Dnsmasq-discuss at lists.thekelleys.org.uk
http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss



More information about the Dnsmasq-discuss mailing list