OpenWrt Forum Archive

Topic: DHCP relay with dnsmasq

The content of this topic has been archived on 24 Apr 2018. There are no obvious gaps in this topic, but there may still be some posts missing at the end.

Hello everybody!

Recently, I needed to configure DHCP relay on several OpenWrt routers. It was necessary for working DHCP server over the IPSEC.

I have found that dnsmasq has an option for this: —dhcp-relay=<local address>,<server address>[,<interface]. Then I tried to find UCI options for dnsmasq dhcp-relay, but my search has not been successful. https://wiki.openwrt.org/doc/uci/dhcp and /etc/init.d/dnsmasq didn’t contain information about that.

I had to write a patch for /etc/init.d/dnsmasq which reads /etc/config/dhcp, and started dnsmasq with dhcp-relay parameter if this option is enabled in config file.

Is there anyone who else need this feature? Shall I offer this patch to the OpenWrt developers?

dmitriev_ka,

This sounds like exactly what I've been looking for but have been unable to get it working. Care to share your patch?

@tuxmartin seems to be looking for a similar solution :
https://forum.openwrt.org/viewtopic.php?id=60148

Thanks,
Earl

I am interested in this feature. I'm really surprised to find that I cannot find a DHCP Relay option in OpenWRT. I did notice as well that dnsmasq does have this option, but no way of configuring it with uci.

Be so kind to post support issues in General Discussion and RTFW (any DNSmasq feature can be enabled).

The discussion might have continued from here.