>Synopsis: pfctl (new) queues loading bug
>Category: Network/PF
>Environment:
System : OpenBSD 5.6
Details : OpenBSD 5.6 (GENERIC.MP) #2: Fri Dec 5 09:09:33 CET 2014
root@xxxx:/usr/src/sys/arch/amd64/compile/GENERIC.MP
Architecture: OpenBSD.amd64
Machine : amd64
>Description:
When using the new (5.5/5.6) PF queuing system, I discovered a bug
by inadvertently using a inexistant queue name in my pf.conf file.
Instead of complaining about an inexistant queue, pfctl just hangs
with "pfctl: DIOCADDRULE: Device busy".
Moreover, after few tries, it is no even possible to load a "good"
pf.conf file, since pfctl hangs every time with
"pfctl: DIOCXCOMMIT: Invalid argument". The problem then persists
until reboot.
>How-To-Repeat:
Try to load the following buggy pf.conf file (note the mistyped queue
name) with pfctl -f <filename> :
ext_if="re0"
queue toto on $ext_if bandwidth 1M, max 1M default
match out on $ext_if set queue titi
Try to load it 3 or 4 times (getting "DIOCADDRULE: Device busy" error),
then it is not event possible to load any (good) configuration file,
since you are now stuck with "pfctl: DIOCXCOMMIT: Invalid argument"
until reboot.
>Fix:
Found no easy fix (appart avoid using unknown queue name in pf.conf
and/or rebooting)