All of lore.kernel.org
 help / color / mirror / Atom feed
* Counting Connections
@ 2009-01-14  8:28 Peter Renzland
  2009-01-14  8:49 ` Artūras Šlajus
  0 siblings, 1 reply; 3+ messages in thread
From: Peter Renzland @ 2009-01-14  8:28 UTC (permalink / raw)
  To: netfilter

I can count packets and bytes, by LAN IP and direction, with something  
like this:


LAN="192.168.0"; Hosts="100 102 103 105 108 120 122 124 126 130 132"

for SD in s d; do
   iptables -N traffic_$SD
   iptables -I FORWARD -j traffic_$SD
   for IP in $HOSTS; do
     iptables -A traffic_$SD -$SD $LAN.$IP
   done
done


I would also like to count connections (those that have been tracked),  
just like the packets and bytes that have been moved.
Can someone please show me how that can be done?

I should mention that the routers I am working with are stuck with  
Netfilter 1.3.7 on Linux 2.4.20.


Thanks!

Peter

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2009-01-17 18:08 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-01-14  8:28 Counting Connections Peter Renzland
2009-01-14  8:49 ` Artūras Šlajus
2009-01-17 18:08   ` Peter Renzland

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.