From: "Jingsong Fu" <JingsongFu@WoodsideNet.Com>
To: lartc@vger.kernel.org
Subject: RE: [LARTC] tc qdisc show - statistics truncated
Date: Tue, 07 Jan 2003 01:34:24 +0000 [thread overview]
Message-ID: <marc-lartc-104190335717193@msgid-missing> (raw)
In-Reply-To: <marc-lartc-104156498819233@msgid-missing>
I have tried the new tc source, however it still complains on "statistics truncated".
By looking into the function print_qdisc() of iproute2/tc/tc_qdisc.c, shown as follows,
if (RTA_PAYLOAD(tb[TCA_STATS]) < sizeof(struct tc_stats))
fprintf(fp, "statistics truncated");
struct tc_stats
{
__u64 bytes; /* NUmber of enqueues bytes */
__u32 packets; /* Number of enqueued packets */
__u32 drops; /* Packets dropped because of lack of resources */
__u32 overlimits; /* Number of throttle events when this
* flow goes out of allocated bandwidth */
__u32 bps; /* Current flow byte rate */
__u32 pps; /* Current flow packet rate */
__u32 qlen;
__u32 backlog;
#ifdef __KERNEL__
spinlock_t *lock;
#endif
};
RTA_PAYLOAD() is 36 bytes, which is __u32 aligned.
sizeof(struct tc_stats) is 40 bytes which is __u64 aligned.
Has anyone had the same issue, and what's the easy way to resolve it?
Thanks,
Jingsong
-----Original Message-----
From: Patrick McHardy [mailto:kaber@stinky.trash.net]
Sent: Thursday, January 02, 2003 7:39 PM
To: Jingsong Fu
Cc: lartc@mailman.ds9a.nl
Subject: Re: [LARTC] tc qdisc show - statistics truncated
On Thu, 2 Jan 2003, Jingsong Fu wrote:
>
> I am trying to show PRIO qdisc stats, and always get statistics truncated as follows, could someone help to explain why and how correct it?
> Thanks,
> Jingsong
>
> # tc -s qdisc show dev eth0
> qdisc prio 1: bands 8 priomap 7 6 5 4 3 2 1 0 7 7 7 7 7 7 7 7
> statistics truncated
Your tc binary is not matching your kernel version, i would say.
Install a new tc version, preferably from source.
Patrick
_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/
next prev parent reply other threads:[~2003-01-07 1:34 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-01-03 3:35 [LARTC] tc qdisc show - statistics truncated Jingsong Fu
2003-01-03 3:39 ` Patrick McHardy
2003-01-07 1:34 ` Jingsong Fu [this message]
2003-01-07 1:53 ` Patrick McHardy
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=marc-lartc-104190335717193@msgid-missing \
--to=jingsongfu@woodsidenet.com \
--cc=lartc@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.