NetBSD-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: NPF - npfctl_config_send: Invalid argument



"D'Arcy J.M. Cain" <darcy%NetBSD.org@localhost> wrote:
> # /etc/rc.d/npf restart
> Disabling NPF.
> Enabling NPF.
> npfctl: source /usr/src/sys/net/npf/npf_ctl.c line 174
> npfctl: npfctl_config_send: Invalid argument
> 
> That source reference doesn't seem to sync to anything in the actual
> source.  Anyone know what this message indicates?

It turns out that NetBSD's ptree.c implementation [1] has bugs (it happens
in certain corner cases, only if you insert prefixes in particular order).
I think you might be hitting this bug.  It is not worth fixing it (see the
resolution of PR/47931 I raised years ago).. Since NPF is the only user of
this implementation, we should remove it in favour of a better mechanism or
just a better PATRICIA trie implementation.

Meanwhile, if you do not use prefixes -- try a hash table or CDB type.

[1] http://nxr.netbsd.org/xref/src/common/lib/libc/gen/ptree.c

-- 
Mindaugas


Home | Main Index | Thread Index | Old Index