Commit 115411c3 authored by Jouke Witteveen's avatar Jouke Witteveen
Browse files

Bring dhcpcd support up to date (FS#66349)

With dhcpcd 9, the rundir has moved. We follow this change and no longer
support older versions of dhcpcd.
While here, also support information only use on IPv6, which has been
possible with dhcpcd for quite a while already.

Reported by: Antonio Rojas <arojas@archlinux.org>
parent 3bebcd7c
......@@ -7,10 +7,7 @@ dhcpcd_start() {
6) options=$DhcpcdOptions6;;
*) return 1;;
esac
if [[ $2 == "noaddr" ]]; then
report_error "Using 'dhcpcd' for configuration without address assignment is unsupported"
return 1
fi
[[ $2 == "noaddr" ]] && options+=" --inform6"
# If using own dns, tell dhcpcd to NOT replace resolv.conf
[[ $DNS ]] && options+=" -C resolv.conf"
if ! do_debug do_readable dhcpcd "-$1" -q -t "${TimeoutDHCP:-30}" $options "$Interface"; then
......@@ -21,7 +18,7 @@ dhcpcd_start() {
dhcpcd_stop() {
local stop="-x"
if [[ -f "/run/dhcpcd-$Interface-$1.pid" ]]; then
if [[ -f "/run/dhcpcd/$Interface-$1.pid" ]]; then
is_yes "${DHCPReleaseOnStop:-no}" && stop="-k"
do_debug dhcpcd "-$1" -q $stop "$Interface" > /dev/null
fi
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment