diff --git a/package/network/services/odhcpd/Makefile b/package/network/services/odhcpd/Makefile index c1facce6732..a287f2a5a1e 100644 --- a/package/network/services/odhcpd/Makefile +++ b/package/network/services/odhcpd/Makefile @@ -76,7 +76,6 @@ endif define Package/odhcpd/install $(INSTALL_DIR) $(1)/usr/sbin/ $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/odhcpd $(1)/usr/sbin/ - $(INSTALL_BIN) ./files/odhcpd-update $(1)/usr/sbin/ $(INSTALL_DIR) $(1)/etc/init.d $(INSTALL_BIN) ./files/odhcpd.init $(1)/etc/init.d/odhcpd $(INSTALL_DIR) $(1)/etc/uci-defaults diff --git a/package/network/services/odhcpd/files/odhcpd-update b/package/network/services/odhcpd/files/odhcpd-update deleted file mode 100755 index e777fcbb077..00000000000 --- a/package/network/services/odhcpd/files/odhcpd-update +++ /dev/null @@ -1,8 +0,0 @@ -#!/bin/sh -# Make dnsmasq reread hostfile by sending SIGHUP signal - -initscript=$0 - -. /lib/functions/procd.sh - -procd_send_signal dnsmasq diff --git a/package/network/services/odhcpd/files/odhcpd.defaults b/package/network/services/odhcpd/files/odhcpd.defaults index 050de23a28c..d3b7f2a83b8 100644 --- a/package/network/services/odhcpd/files/odhcpd.defaults +++ b/package/network/services/odhcpd/files/odhcpd.defaults @@ -18,9 +18,16 @@ uci_drop_option() { if [ -n "$(uci -q get dhcp.odhcpd)" ]; then commit=0 + if [ -z "$(uci -q get dhcp.odhcpd.leasedir)" ]; then + uci set dhcp.odhcpd.leasedir=/tmp/odhcpd/leases + commit=1 + fi + # Options odhcpd no longer supports uci_drop_option dhcp dhcpv4_forcereconf && commit=1 uci_drop_option odhcpd enable_tz && commit=1 + uci_drop_option odhcpd leasefile && commit=1 + uci_drop_option odhcpd leasetrigger && commit=1 [ "$commit" -eq 1 ] && uci commit dhcp @@ -64,11 +71,10 @@ EOF uci batch <