Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 18 Jan 2002 08:42:44 +1100
From:      Edwin Groothuis <edwin@mavetju.org>
To:        Skye Poier <skye@ffwd.cx>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: tcp service accounting
Message-ID:  <20020118084244.Z823@k7.mavetju.org>
In-Reply-To: <20020117102809.F89905@ffwd.cx>; from skye@ffwd.cx on Thu, Jan 17, 2002 at 10:28:09AM -0800
References:  <20020117102809.F89905@ffwd.cx>

next in thread | previous in thread | raw e-mail | index | archive | help
On Thu, Jan 17, 2002 at 10:28:09AM -0800, Skye Poier wrote:
> I'm looking for a package that will listen on an interface for all
> traffic going in/out of the box and tally up bytes based on the TCP port
> (service type - dst port if incoming, src port if outgoing) to basically
> break up the bandwidth my server is using by service type.
> 
> I'm using ipcad right now which is great but its summarized by host/network
> rather than port number.

I have for all destination-ports I want to monitor a rule in my
firewall script:

01000 allow tcp from any to any 20 via tun0
01000 allow tcp from any 20 to any via tun0
01000 allow tcp from any to any 21 via tun0
01000 allow tcp from any 21 to any via tun0
01000 allow tcp from any to any 25 via tun0
01000 allow tcp from any 25 to any via tun0
01000 allow tcp from any to any 80 via tun0
01000 allow tcp from any 80 to any via tun0
01000 allow tcp from any to any 110 via tun0
01000 allow tcp from any 110 to any via tun0
01000 allow tcp from any to any 995 via tun0
01000 allow tcp from any 995 to any via tun0
01000 allow tcp from any to any 443 via tun0
01000 allow tcp from any 443 to any via tun0
[...]

I don't monitor them for accounting but for graphing them: See
net/ipfw-graph. Maybe you should have a look at that to see if you
have an idea on how to use it.

Edwin

-- 
Edwin Groothuis   |              Personal website: http://www.MavEtJu.org
edwin@mavetju.org |           Interested in MUDs? Visit Fatal Dimensions:
------------------+                       http://www.FatalDimensions.org/

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?20020118084244.Z823>