Simple LAN IP accounting
Nash Nipples
trashy_bumper at yahoo.com
Sun Jun 18 14:26:45 UTC 2006
ipfw add 5 skipto 500 ip from 192.168.110.1 to any out via tun0
ipfw add 10 skipto 500 ip from any to 192.168.110.1 to any in via tun0
ipfw add .. skipto 500 ip from 192.168.110... to any out via tun0
...
ipfw add 500 divert from any to any in via tun0 #back to normal rules
ipfw show
00005 274943 64986791 ip from 192.168.110.1 to any out via tun0
00010 274943 64986791 ip from any to 192.168.110.1 in via tun0
thats pretty stupid but works. and you need a program to proccess the output
thats what im working on time to time :)
it doesnt overload the filter cuz a matching rule is passed once at a time and the unmatched skipped to normal rules. if you get out of ipfw rules limits you might consider to split.. lol
anyone else?
nash
"Roger T. Harvey" <nightstalker.micronta at gmail.com> wrote: Ok, I've done research, and found this example to track bytes per ip on LAN:
$IPFW pipe 1 config mask src-ip 0xffffffff buckets 512
$IPFW pipe 2 config mask dst-ip 0xffffffff buckets 512
$IPFW add 32001 pipe 1 src-ip 192.168.110.0/24 bridged
$IPFW add 32002 pipe 2 dst-ip 192.168.110.0/24 bridged
Now that's all well and good, and I saw the output as well.
However, im not running bridged. or does that make a difference in this
instance?
Also, is there any scripts, etc to format the pipe info into a nice readable
format (pref html)
Doesn't need graphs, etc. Just Daily and Monthly totals would be nice.
(I am running MySQL so it can store the data)
Concidered to this list, you can call me a newbie for sure. as I only know
how to
Do a handful of things and that's about it. which is why im asking here.
TIA to everyone
_______________________________________________
freebsd-net at freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-net
To unsubscribe, send any mail to "freebsd-net-unsubscribe at freebsd.org"
---------------------------------
Do you Yahoo!?
Next-gen email? Have it all with the all-new Yahoo! Mail Beta.
---------------------------------
Do you Yahoo!?
Everyone is raving about the all-new Yahoo! Mail Beta.
More information about the freebsd-net
mailing list