[collectd] IPTABLES plugin with SHOREWALL ACCOUNTING
Luke Heberling
collectd at c-ware.com
Sat May 17 00:06:21 CEST 2008
Fabio De Martin wrote:
> I'm trying to use iptables plugin with shorewall accounting.
>
> Anyone have tried?
>
> Regards.
>
> Fabio De Martin
>
>
I've been doing it.
In /etc/shorewall/accounting per chain (In my case, a service/zone
permutation):
imap_lan_in:COUNT - - eth_lan tcp -
imap2,imap3,imaps
imap_lan_in:COUNT - - eth_lan tcp
imap2,imap3,imaps -
DONE imap_lan_in
imap_lan_out:COUNT - eth_lan - tcp
imap2,imap3,imaps -
imap_lan_out:COUNT - eth_lan - tcp -
imap2,imap3,imaps
DONE imap_lan_out
In collectd.conf, again per chain:
<Plugin iptables>
....
Chain filter imap_lan_in 3
Chain filter imap_lan_out 3
....
</Plugin>
The appropriate index to use can be seen using
# shorewall show imap_lan_in
and counting down lines until the RETURN rule.
Here's an example of the end result:
http://fiber.c-ware.com/drraw/index.cgi?Mode=view;Dashboard=1193363404.29533
user: collectd
password: goodforonemonth
Luke
More information about the collectd
mailing list