Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 24 Aug 1998 14:33:48 +0200
From:      Neil Blakey-Milner <nbm@rucus.ru.ac.za>
To:        Jeremy Malcolm <terminus@odyssey.apana.org.au>, freebsd-questions@FreeBSD.ORG
Subject:   Re: Measuring volume
Message-ID:  <19980824143348.A24140@rucus.ru.ac.za>
In-Reply-To: <Pine.BSF.4.02.9808241957180.28592-100000@odyssey.apana.org.au>; from Jeremy Malcolm on Mon, Aug 24, 1998 at 07:58:55PM %2B0800
References:  <Pine.BSF.4.02.9808241957180.28592-100000@odyssey.apana.org.au>

next in thread | previous in thread | raw e-mail | index | archive | help
On Mon 1998-08-24 (19:58), Jeremy Malcolm wrote:
> Hi,
> 
> At work we have a FreeBSD box as our Internet gateway.  We are paying
> a (high!) fixed fee per annum to our ISP and I am wondering whether it
> would be cheaper for us to pay volume.  I have asked the ISP how much
> volume we are pulling but received no reply (as usual).
> 
> Can anyone recommend a way for me to measure the volume our FreeBSD
> box is pulling?

Assuming you have IPFIREWALLING enabled in your kernel, you can use ipfw's
count parameter to help you out.

To get this to work, you'll need to know certain things about your network -
basically:

ipfw count ip from your-network to not your-network
ipfw count ip from not your-network to your-network

(your-network is in form ip/bits, or ip:netmask)

You can use "ipfw show" to show your usage since you last reset the counter -
I recommend you use "ipfw show" in your daily cron, followed by a "ipfw
zero", which will give you daily usage (you might miss a tiny bit between the
ipfw show and zero, but I'm sure that's not likely to make a huge
difference).

Neil
-- 
Neil Blakey-Milner
nbm@rucus.ru.ac.za

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message



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