svn commit: r320944 - head/etc/rc.d

Gleb Smirnoff glebius at FreeBSD.org
Wed Aug 16 20:08:57 UTC 2017


  Emmanuel,

On Wed, Aug 16, 2017 at 04:08:50PM +0200, Emmanuel Vadot wrote:
E> > It could be that using "netgraph" action instead of "ngtee" and then
E> > returning packet back from netgraph to ipfw would show lower overhead.
E> > However, this setup is definitely going to be less robust and more prone
E> > to bugs in case of complex ipfw configurations.
E> 
E>  I should have been more clear, I didn't mean that it would have less
E> overhead in memory but in process time.
E>  Reading the source code I saw that ngtee simply m_dup the packet
E> and then ipfw directly continue with the original one, so it seems to
E> me that this would be the the fastest way to process packets.

Allocating memory, doing a memory copy, and freeing memory is also process time.

E>  Could you expand on "less robust and more prone to bugs" for the
E> "netgraph" case ?

The "netgraph" action send packet to netgraph allocating a tag so that
if later the ng_ipfw node receives the tagged packet back, it can inject
it to the next rule after the rule with "netgraph" action. This all is documented.

-- 
Totus tuus, Glebius.


More information about the svn-src-head mailing list