FreeBSD Port: dhcpcd-9.3.2

Douglas Thrift douglaswth at gmail.com
Sun Nov 15 01:27:22 UTC 2020


On 6/7/2020 2:39 AM, Roy Marples wrote:
> On 07/06/2020 09:37, driesm.michiels at gmail.com wrote:
>>> stop the previous dhcpcd manually and then I discovered that the 
>>> `pidfile`
>>> was still incorrect:
>>>
>>>          pidfile="/var/run/dhcpcd/dhcpcd-$ifn.pid"
>>>
>>> should actually be:
>>>
>>>          pidfile="/var/run/dhcpcd/$ifn.pid"
> 
> pidfile=$(dhcpcd -P $args)
> 
> dhcpcd -4 em0
> dhcpcd -6 em0
> 
> Give different pidfiles.
> 
>> It has already been committed to master and should be fixed in the new
>> dhcpcd-9.1.1 release.
> 
> This patch is also relevant for FreeBSD:
> https://roy.marples.name/cgit/dhcpcd.git/commit/?id=24019cdbe66a152a1e9936ad5c7ae1657713ef2c 
> 
> 
> Roy

It seems like dhcpcd-9.3.2 is working fine for me now in FreeBSD 12.2. I 
have attached a patch for the rc.d script for when it is run against an 
interface which matches Roy's suggestion.

-- 
Douglas William Thrift
<https://douglasthrift.net/>
-------------- next part --------------
Index: files/dhcpcd.in
===================================================================
--- files/dhcpcd.in	(revision 555156)
+++ files/dhcpcd.in	(working copy)
@@ -16,7 +16,7 @@
 	if [ -z "$flags" -a -n "$specific" ]; then
 		rc_flags="$specific"
 	fi
-	pidfile="/var/run/dhcpcd/dhcpcd-$ifn.pid"
+	pidfile="$($command -P $rc_flags $ifn)"
 else
 	pidfile="$($command -P $rc_flags)"
 	: ${dhcpcd_enable:=NO}


More information about the freebsd-ports mailing list