Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 02 Feb 2001 07:07:55 -0800
From:      Julian Elischer <julian@elischer.org>
To:        Luigi Rizzo <rizzo@aciri.org>
Cc:        "Rogier R. Mulhuijzen" <drwilco@drwilco.nl>, erwan@netvalue.com, roman@IPricot.com, freebsd-ipfw@FreeBSD.ORG, freebsd-net@FreeBSD.ORG
Subject:   Re: bandwidth analyser
Message-ID:  <3A7ACD4B.155B2657@elischer.org>
References:  <200101292359.f0TNxOU48488@iguana.aciri.org>

next in thread | previous in thread | raw e-mail | index | archive | help
Luigi Rizzo wrote:
> 
> > There's one downside though. You can get statistics from the bridge node on
> > packets and octects passed through the different parts of the bridge
> > setyup, but it's not IP based. Also using that bridging code there's no
> > bandwidth throttling or IPFW rule matching yet.
> >
> > Vitaly Belekhov wrote BW throttling and ipfw netgraph nodes for 3.X, and I
> > will be porting those to 5.X-CURRENT over the next few weeks.


The new ethernet node netgrpah interface (with 'upper' and 'lower')
may influence this.
also the ipfw he used is very old now.

> >
> > Using those you could get statistics really quickly by using libnetgraph
> > and querying the nodes yourself with some C code instead of shell/perl
> > scripting.
> 
> the real problem with any approach is that if you have very many
> flows, you have to fetch all the info every time you want to update
> your statistics. The ipfw implementation which is in the kernel
> now really does not help you there, because the stats are spread
> over lists and hash tables, and on top of this the data structure
> evolves dynamically as pkts come in, so you need to hold a lock
> while navigating on it.
> 
> This is why you do not want to download the stats 10-20 times per
> second, at least with this architecture.
> 
> I do not have a good solution in mind other than maybe
> change the data structures so that the flow descriptors
> (at least the part with the flow identifier and the stats)
> are in a contiguous chunk of memory whose only variable
> part is the size. This way you can either mmap the block,
> or copyout() it without having to get a lock.
> 
>         cheers
>         luigi
> ----------------------------------+-----------------------------------------
>  Luigi RIZZO, luigi@iet.unipi.it  . ACIRI/ICSI (on leave from Univ. di Pisa)
>  http://www.iet.unipi.it/~luigi/  . 1947 Center St, Berkeley CA 94704
>  Phone: (510) 666 2927
> ----------------------------------+-----------------------------------------
> 
> To Unsubscribe: send mail to majordomo@FreeBSD.org
> with "unsubscribe freebsd-net" in the body of the message

-- 
      __--_|\  Julian Elischer
     /       \ julian@elischer.org
    (   OZ    ) World tour 2000-2001
---> X_.---._/  
            v


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




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?3A7ACD4B.155B2657>