Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 18 Jun 2006 10:21:18 -0400
From:      Chuck Swiger <cswiger@mac.com>
To:        "Roger T. Harvey" <nightstalker.micronta@gmail.com>
Cc:        freebsd-net@freebsd.org
Subject:   Re: Simple LAN IP accounting
Message-ID:  <4495615E.3050604@mac.com>
In-Reply-To: <4495530f.265f68ff.360d.48fa@mx.gmail.com>
References:  <4495530f.265f68ff.360d.48fa@mx.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
Roger T. Harvey wrote:
> $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?

It means you should create pipe rules which match the traffic you want to 
count, rather than using the "bridged" keyword (which would match none of your 
traffic).

Something like "in via fxp0" and "out via fxp0" might be right, assuming for 
the sake of example that you had an Intel "Fast EEPro" card which was the 
interface on the subnet whose traffic you want to count.

> 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)

This kind of thing tends to be fairly idiosyncratic, and you'll probably have 
to modify or write something for your specific case...perhaps others have more 
useful sample scripts to contribute.

-- 
-Chuck



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4495615E.3050604>