public inbox for passt-dev@passt.top
 help / color / mirror / code / Atom feed
From: Stefano Brivio <sbrivio@redhat.com>
To: Jon Maloy <jmaloy@redhat.com>
Cc: passt-dev@passt.top, lvivier@redhat.com, dgibson@redhat.com
Subject: Re: [net, v2] tcp: correct handling of extreme memory squeeze
Date: Thu, 16 Jan 2025 22:14:22 +0100	[thread overview]
Message-ID: <20250116221422.2d977ba5@elisabeth> (raw)
In-Reply-To: <20250116022918.2225785-1-jmaloy@redhat.com>

On Wed, 15 Jan 2025 21:29:18 -0500
Jon Maloy <jmaloy@redhat.com> wrote:

> Testing with iperf3 using the "pasta" protocol splicer has revealed
> a bug in the way tcp handles window advertising in extreme memory
> squeeze situations. The problem occurs on the server side, and
> the socket in question is a completely regular socket with the
> default settings for the fedora40 kernel. We do not use SO_PEEK
> or SO_RCV_BUF on this socket.

SO_RCVBUF

I think what's missing, at this point, is a short description of the
issue.

That is (if I recall correctly), under memory pressure, we temporarily
advertise a zero-sized window, but this is not stored as part of socket
data, the reasoning being that it's a temporary setting which shouldn't
influence any further calculation.

However, by not storing this information in socket data, we also fail
to advertise a non-zero window once we have enough memory to receive
data.

Our notion of the window size is now different from what we
advertised to the peer. The peer won't send any data as a result, but
we won't recalculate the window, either, as long as we don't receive
any.

The rest looks good and very reasonable to me.

-- 
Stefano


  reply	other threads:[~2025-01-16 21:14 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-01-16  2:29 [net, v2] tcp: correct handling of extreme memory squeeze Jon Maloy
2025-01-16 21:14 ` Stefano Brivio [this message]
2025-01-17 21:40 [net,v2] " jmaloy
2025-01-17 22:09 ` Eric Dumazet
2025-01-17 22:27   ` Stefano Brivio
2025-01-18 17:01 ` Jason Xing
2025-01-18 20:04 ` Neal Cardwell
2025-01-20  5:03   ` Jon Maloy
2025-01-20 16:10     ` Jon Maloy
2025-01-20 16:22       ` Eric Dumazet

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=20250116221422.2d977ba5@elisabeth \
    --to=sbrivio@redhat.com \
    --cc=dgibson@redhat.com \
    --cc=jmaloy@redhat.com \
    --cc=lvivier@redhat.com \
    --cc=passt-dev@passt.top \
    /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.
Code repositories for project(s) associated with this public inbox

	https://passt.top/passt

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for IMAP folder(s).