From: Martin Ottens <martin.ottens@fau.de>
To: Jamal Hadi Salim <jhs@mojatatu.com>
Cc: Stephen Hemminger <stephen@networkplumber.org>,
Cong Wang <xiyou.wangcong@gmail.com>,
Jiri Pirko <jiri@resnulli.us>,
"David S. Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@google.com>,
Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
Simon Horman <horms@kernel.org>,
netdev@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2] net/sched: netem: account for backlog updates from child qdisc
Date: Sat, 7 Dec 2024 17:37:19 +0100 [thread overview]
Message-ID: <b4f59f1c-b368-49ae-a0c4-cf6bf071c693@fau.de> (raw)
In-Reply-To: <CAM0EoMnTTQ-BtS0EBqB-5yNAAmvk9r67oX7n7S0Ywhc23s49EQ@mail.gmail.com>
On 05.12.24 13:40, Jamal Hadi Salim wrote:
> Would be nice to see the before and after (your change) output of the
> stats to illustrate
Setup is as described in my patch. I used a larger limit of
1000 for netem so that the overshoot of the qlen becomes more
visible. Kernel is from the current net-next tree (the patch to
sch_tbf referenced in my patch is already applied (1596a135e318)).
TCP before the fix (qlen is 1150p, exceeding the maximum of 1000p,
netem qdisc becomes "locked" and stops accepting packets):
qdisc netem 1: root refcnt 2 limit 1000 delay 100ms
Sent 2760196 bytes 1843 pkt (dropped 389, overlimits 0 requeues 0)
backlog 4294560030b 1150p requeues 0
qdisc tbf 10: parent 1:1 rate 50Mbit burst 1537b lat 50ms
Sent 2760196 bytes 1843 pkt (dropped 327, overlimits 7356 requeues 0)
backlog 0b 0p requeues 0
UDP (iperf3 sends 50Mbit/s) before the fix, no issues here:
qdisc netem 1: root refcnt 2 limit 1000 delay 100ms
Sent 71917940 bytes 48286 pkt (dropped 2415, overlimits 0 requeues 0)
backlog 643680b 432p requeues 0
qdisc tbf 10: parent 1:1 rate 50Mbit burst 1537b lat 50ms
Sent 71917940 bytes 48286 pkt (dropped 2415, overlimits 341057 requeues 0)
backlog 311410b 209p requeues 0
TCP after the fix (UDP is not affected by the fix):
qdisc netem 1: root refcnt 2 limit 1000 delay 100ms
Sent 94859934 bytes 62676 pkt (dropped 15, overlimits 0 requeues 0)
backlog 573806b 130p requeues 0
qdisc tbf 10: parent 1:1 rate 50Mbit burst 1537b lat 50ms
Sent 94859934 bytes 62676 pkt (dropped 324, overlimits 248442 requeues 0)
backlog 4542b 3p requeues 0
> Your fix seems reasonable but I am curious: does this only happen with
> TCP? If yes, perhaps the
> GSO handling maybe contributing?
> Can you run iperf with udp and see if the issue shows up again? Or
> ping -f with size 1024.
I was only able to reproduce this behavior with tbf and it happens
only when GSO packets are segmented inside the tbf child qdisc. As
shown above, UDP is therefore not affected. The behavior also occurs
if this configuration is used on the "outgoing" interface of a system
that just forwards packets between two networks and GRO is enabled on
the "incoming" interface.
next prev parent reply other threads:[~2024-12-07 16:46 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-11-25 23:18 [PATCH] " Martin Ottens
2024-12-03 3:13 ` Jakub Kicinski
2024-12-04 11:47 ` Martin Ottens
2024-12-04 12:29 ` [PATCH v2] " Martin Ottens
2024-12-05 12:40 ` Jamal Hadi Salim
2024-12-07 16:37 ` Martin Ottens [this message]
2024-12-09 21:13 ` Jamal Hadi Salim
2024-12-09 22:44 ` Jamal Hadi Salim
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=b4f59f1c-b368-49ae-a0c4-cf6bf071c693@fau.de \
--to=martin.ottens@fau.de \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=horms@kernel.org \
--cc=jhs@mojatatu.com \
--cc=jiri@resnulli.us \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=stephen@networkplumber.org \
--cc=xiyou.wangcong@gmail.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®