Re: how to measure bandwidth per jail
Jnettop has the ability to: Measure bandwidth/packets in partecular intergace. Simply use: 0,1..9 to switch between interfaces. p to switch between packets/bandwidth b to measure in bytes/bits You better define your local ips in the .jnettop file, once that done your measurs would be more accurate specially when you aggregate traffic (in local/remote) by ip/protocol... Additional option is content filter mainly in web traffic. You can also add custom ips to measure using .jnettoo file. Sami On Mar 22, 2013 1:05 PM, "Nicolas de Bari Embriz Garcia Rojas" < nb...@inbox.im> wrote: > Hi, I tried jnettop but is something like 'trafshow', I am searching > something like vnstat, that could help me measure the rx/tx & total > consumed bandwidth. > > any ideas? > > > > On 03/21/2013 18:48, Sami Halabi wrote: > > Hi > Try jnettop from ports... exactly what your looking at. > > However its old, so the counters are 32 bit rather than 64 which means its > pretty effective on 100mbit links > plus its cpu consumer by design > Sami > On Mar 21, 2013 8:27 PM, "Nicolas de Bari Embriz Garcia Rojas" < > nb...@inbox.im> wrote: > >> Hi, one strange behavior I notice (freeBSD 9.1) is that I don't see the >> Obytes per IP only for the bce0 interface, but I do for the cloned >> interface lo1: >> >> here is a link with the output of netstat -ib >> http://pastebin.com/arrRsM78 >> >> any ideas ? >> >> regards. >> >> On 03/21/2013 18:12, Scott Lambert wrote: >> > On Thu, Mar 21, 2013 at 01:26:13AM +, Nicolas de Bari Embriz >> Garcia Rojas wrote: >> >> Hi, any tool, idea or method for measuring the bandwidth consumed per >> >> jail ? (or by IP) >> >> >> >> What about using pflow ( pseudo-device pflow) any advice ? >> > I found a thread about this topic yesterday via Google. It was on >> > the freebsd-...@frebbsd.org mailing list sometime in 2005 if I >> > remember correctly. >> > >> > They came up with a few options >> > >> > netflow, >> > >> > counting rules in IPFW/pf/ipf >> > >> > netstat -rni ( which gets you packet counts, >> > -rnbi gives you in-bytes and out-bytes) >> > >> > bandwidthd (in ports I believe) >> > >> > I suppose ntop could do similar things. >> > >> > My favorite option was netstat -rnbi | awk '{print $8,$11}' and >> > feeding that to MRTG. I have not gotten it implemented yet. >> > >> > One consideration is that on FreeBSD 8 and older, you don't get out >> > traffic per IP address with netstat, as far as I can tell. We're >> > moving to FreeBSD 9 pretty quickly anyway. >> > >> >> ___ >> freebsd-jail@freebsd.org mailing list >> http://lists.freebsd.org/mailman/listinfo/freebsd-jail >> To unsubscribe, send any mail to "freebsd-jail-unsubscr...@freebsd.org" >> > > ___ freebsd-jail@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-jail To unsubscribe, send any mail to "freebsd-jail-unsubscr...@freebsd.org"
Re: how to measure bandwidth per jail
On Thu, Mar 21, 2013 at 06:27:27PM +, Nicolas de Bari Embriz Garcia Rojas wrote: > Hi, one strange behavior I notice (freeBSD 9.1) is that I don't see the > Obytes per IP only for the bce0 interface, but I do for the cloned > interface lo1: > > here is a link with the output of netstat -ib http://pastebin.com/arrRsM78 > > any ideas ? Most of my jail host IPs are on lo0. Maybe you don't get out accounting if the IP is in the same subnet on the same interface with your gateway? Just a guess. I don't have any insight into how it works. I see the sambe behavior as you for IPs in the subnet with the default gateway, even if specified with: ifconfig alias ip/32. On the older boxes I have, all of the IPs were defined in the interface's main subnet. I may have been seeing the same behaviour but incorrectly ascribing it to the FreeBSD rev rather than how the IPs were specified. I cannot test it today. > On 03/21/2013 18:12, Scott Lambert wrote: > > On Thu, Mar 21, 2013 at 01:26:13AM +, Nicolas de Bari Embriz Garcia > > Rojas wrote: > >> Hi, any tool, idea or method for measuring the bandwidth consumed per > >> jail ? (or by IP) > >> > >> What about using pflow ( pseudo-device pflow) any advice ? > > I found a thread about this topic yesterday via Google. It was on > > the freebsd-...@frebbsd.org mailing list sometime in 2005 if I > > remember correctly. > > > > They came up with a few options > > > > netflow, > > > > counting rules in IPFW/pf/ipf > > > > netstat -rni ( which gets you packet counts, > > -rnbi gives you in-bytes and out-bytes) > > > > bandwidthd (in ports I believe) > > > > I suppose ntop could do similar things. > > > > My favorite option was netstat -rnbi | awk '{print $8,$11}' and > > feeding that to MRTG. I have not gotten it implemented yet. > > > > One consideration is that on FreeBSD 8 and older, you don't get out > > traffic per IP address with netstat, as far as I can tell. We're > > moving to FreeBSD 9 pretty quickly anyway. > > -- Scott LambertKC5MLE Unix SysAdmin lamb...@lambertfam.org ___ freebsd-jail@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-jail To unsubscribe, send any mail to "freebsd-jail-unsubscr...@freebsd.org"
Re: how to measure bandwidth per jail
Hi Try jnettop from ports... exactly what your looking at. However its old, so the counters are 32 bit rather than 64 which means its pretty effective on 100mbit links plus its cpu consumer by design Sami On Mar 21, 2013 8:27 PM, "Nicolas de Bari Embriz Garcia Rojas" < nb...@inbox.im> wrote: > Hi, one strange behavior I notice (freeBSD 9.1) is that I don't see the > Obytes per IP only for the bce0 interface, but I do for the cloned > interface lo1: > > here is a link with the output of netstat -ib http://pastebin.com/arrRsM78 > > any ideas ? > > regards. > > On 03/21/2013 18:12, Scott Lambert wrote: > > On Thu, Mar 21, 2013 at 01:26:13AM +, Nicolas de Bari Embriz Garcia > Rojas wrote: > >> Hi, any tool, idea or method for measuring the bandwidth consumed per > >> jail ? (or by IP) > >> > >> What about using pflow ( pseudo-device pflow) any advice ? > > I found a thread about this topic yesterday via Google. It was on > > the freebsd-...@frebbsd.org mailing list sometime in 2005 if I > > remember correctly. > > > > They came up with a few options > > > > netflow, > > > > counting rules in IPFW/pf/ipf > > > > netstat -rni ( which gets you packet counts, > > -rnbi gives you in-bytes and out-bytes) > > > > bandwidthd (in ports I believe) > > > > I suppose ntop could do similar things. > > > > My favorite option was netstat -rnbi | awk '{print $8,$11}' and > > feeding that to MRTG. I have not gotten it implemented yet. > > > > One consideration is that on FreeBSD 8 and older, you don't get out > > traffic per IP address with netstat, as far as I can tell. We're > > moving to FreeBSD 9 pretty quickly anyway. > > > > ___ > freebsd-jail@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-jail > To unsubscribe, send any mail to "freebsd-jail-unsubscr...@freebsd.org" > ___ freebsd-jail@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-jail To unsubscribe, send any mail to "freebsd-jail-unsubscr...@freebsd.org"
Re: how to measure bandwidth per jail
Hi, one strange behavior I notice (freeBSD 9.1) is that I don't see the Obytes per IP only for the bce0 interface, but I do for the cloned interface lo1: here is a link with the output of netstat -ib http://pastebin.com/arrRsM78 any ideas ? regards. On 03/21/2013 18:12, Scott Lambert wrote: > On Thu, Mar 21, 2013 at 01:26:13AM +, Nicolas de Bari Embriz Garcia Rojas > wrote: >> Hi, any tool, idea or method for measuring the bandwidth consumed per >> jail ? (or by IP) >> >> What about using pflow ( pseudo-device pflow) any advice ? > I found a thread about this topic yesterday via Google. It was on > the freebsd-...@frebbsd.org mailing list sometime in 2005 if I > remember correctly. > > They came up with a few options > > netflow, > > counting rules in IPFW/pf/ipf > > netstat -rni ( which gets you packet counts, > -rnbi gives you in-bytes and out-bytes) > > bandwidthd (in ports I believe) > > I suppose ntop could do similar things. > > My favorite option was netstat -rnbi | awk '{print $8,$11}' and > feeding that to MRTG. I have not gotten it implemented yet. > > One consideration is that on FreeBSD 8 and older, you don't get out > traffic per IP address with netstat, as far as I can tell. We're > moving to FreeBSD 9 pretty quickly anyway. > ___ freebsd-jail@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-jail To unsubscribe, send any mail to "freebsd-jail-unsubscr...@freebsd.org"
Re: how to measure bandwidth per jail
On Thu, Mar 21, 2013 at 01:26:13AM +, Nicolas de Bari Embriz Garcia Rojas wrote: > Hi, any tool, idea or method for measuring the bandwidth consumed per > jail ? (or by IP) > > What about using pflow ( pseudo-device pflow) any advice ? I found a thread about this topic yesterday via Google. It was on the freebsd-...@frebbsd.org mailing list sometime in 2005 if I remember correctly. They came up with a few options netflow, counting rules in IPFW/pf/ipf netstat -rni ( which gets you packet counts, -rnbi gives you in-bytes and out-bytes) bandwidthd (in ports I believe) I suppose ntop could do similar things. My favorite option was netstat -rnbi | awk '{print $8,$11}' and feeding that to MRTG. I have not gotten it implemented yet. One consideration is that on FreeBSD 8 and older, you don't get out traffic per IP address with netstat, as far as I can tell. We're moving to FreeBSD 9 pretty quickly anyway. -- Scott LambertKC5MLE Unix SysAdmin lamb...@lambertfam.org ___ freebsd-jail@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-jail To unsubscribe, send any mail to "freebsd-jail-unsubscr...@freebsd.org"
how to measure bandwidth per jail
Hi, any tool, idea or method for measuring the bandwidth consumed per jail ? (or by IP) What about using pflow ( pseudo-device pflow) any advice ? thanks in advance. regards. -- > nbari signature.asc Description: Message signed with OpenPGP using GPGMail