The quick and nasty guide to Ip Accounting using Iptables ========================================================= Shanker Balan http://shankerbalan.com/ Changelog: Wed Apr 30 15:07:40 IST 2003 - Initial commit On the gateway box (or any box running with prmicous mode) add the following line to rc.fw: iplist="1 21 24 33 38 51 84 100" for aa in $iplist do /sbin/iptables -A FORWARD -s 192.168.1.$aa done To list the accounting data: iptables -L -v -x --line-numbers|grep "^[0-9]"|awk '{print $2 "\t" $8}' There are better ways to do ip accounting under Linux, search freshmeat,net for packaged solutions.