From: Diego Sueiro Date: Thu, 20 Aug 2020 11:01:11 +0000 (+0100) Subject: tools/hotplug: Extend dhcpd conf, init and arg files search X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=17f80e7fc1e3bb49fc91794ef1b6e5a2f1b540cb;p=people%2Fsstabellini%2Fxen-unstable.git%2F.git tools/hotplug: Extend dhcpd conf, init and arg files search Newer versions of the ISC dhcp server expect the dhcpd.conf file to be located at /etc/dhcp directory. Also, some distributions and Yocto based ones have these installation paths by default: /etc/init.d/{isc-dhcp-server,dhcp-server} and /etc/default/dhcp-server. Signed-off-by: Diego Sueiro Reviewed-by: Bertrand Marquis Acked-by: Wei Liu --- diff --git a/tools/hotplug/Linux/xen-network-common.sh b/tools/hotplug/Linux/xen-network-common.sh index 82ee70aab4..42fa704e8d 100644 --- a/tools/hotplug/Linux/xen-network-common.sh +++ b/tools/hotplug/Linux/xen-network-common.sh @@ -64,18 +64,18 @@ first_file() find_dhcpd_conf_file() { - first_file -f /etc/dhcp3/dhcpd.conf /etc/dhcpd.conf + first_file -f /etc/dhcp/dhcpd.conf /etc/dhcp3/dhcpd.conf /etc/dhcpd.conf } find_dhcpd_init_file() { - first_file -x /etc/init.d/{dhcp3-server,dhcp,dhcpd} + first_file -x /etc/init.d/{isc-dhcp-server,dhcp-server,dhcp3-server,dhcp,dhcpd} } find_dhcpd_arg_file() { - first_file -f /etc/sysconfig/dhcpd /etc/defaults/dhcp /etc/default/dhcp3-server + first_file -f /etc/sysconfig/dhcpd /etc/defaults/dhcp /etc/default/dhcp-server /etc/default/dhcp3-server } # configure interfaces which act as pure bridge ports: