From: Francisco Date: Sun, 09 Apr 2006 22:42:14 +0000 Subject: Re: [LARTC] tc counters "problem" Message-Id: <200604091942.14257.ranmakun@arnet.com.ar> List-Id: References: <200604091624.20565.ranmakun@arnet.com.ar> In-Reply-To: <200604091624.20565.ranmakun@arnet.com.ar> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable To: lartc@vger.kernel.org The interface that I'm using is ppp0, the classes/qdiscs are created with t= he=20 interface (from /etc/ppp/ip-up file) but that doesn't matter anyway, the wa= y=20 the two graphics are created is: at time 0 look the total amount of bytes/bits transfered at time 5 (mins) I look the amount of bytes/bits transfered and do: (bits(t= =3D5)=20 - bits(t=3D0))/(300secs) =3D bps (similar with bytes) and repeat every five minutes, this is how MRTG graphs. So it really doesn't matter if the counters are different, what matters is = the=20 difference between time x and time y. The interface counters and the tc counters are fetched by SNMP and I'm 100%= =20 sure that my interface graph is accurate, I just don't understand why there= =20 is so much difference with the tc ones. On the other hand, I just made a test with a file transfer resetting all=20 counters: file: 14675760 lego.pdf iptables: Chain OUTPUT (policy ACCEPT 478208 packets, 1617032905 bytes) pkts bytes target prot opt in out source =20 destination 10725 15568354 MARK tcp -- any ppp0 anywhere =20 anywhere tcp spt:http MARK set 0x1e tc: class htb 1:30 parent 1:1 leaf 30: prio 3 rate 1000bit ceil 120000bit burst= =20 6Kb/8 mpu 0b overhead 0b cburst 1659b/8 mpu 0b overhead 0b level 0 Sent 15568302 bytes 10724 pkt (dropped 0, overlimits 0 requeues 0) rate 112bit 0pps backlog 0b 0p requeues 0 lended: 99 borrowed: 10625 giants: 0 tokens: -13832192 ctokens: -671 All this seems file, the bytes match, etc. So I'm not sure what I'm doing=20 wrong. I'll keep investigating, I just wanted to know if any of you saw=20 something wrong with my reasoning or if there were known issues with the=20 counters. Francisco El Domingo, 9 de Abril de 2006 16:50, Andreas Klauer escribi=F3: > On Sun, Apr 09, 2006 at 04:24:20PM -0300, Francisco wrote: > > I expected that meassuring the root class I would get values similar th= at > > the ones I get measuring the interface counters but they differ by a > > large amount. > > The statistics you posted seem to be fine. Which interface counters are > you talking about? tc starts counting only after the qdiscs/classes were > created, so if you have a separate count somewhere which started counting > some other time, the difference will of course be huge (as far as total > packet count is concerned). > > Regards > Andreas Klauer _______________________________________________ LARTC mailing list LARTC@mailman.ds9a.nl http://mailman.ds9a.nl/cgi-bin/mailman/listinfo/lartc