[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [lwip-users] zero window probe causes duplicated byte to be received

From: Joel Cunningham
Subject: Re: [lwip-users] zero window probe causes duplicated byte to be received
Date: Sat, 01 Apr 2017 19:36:26 -0500

There was a bug where send_nxt was not advanced during the zero window probe 
and thus the zero window probe ACK caused LwIP to send back another ACK, 
creating an ACK storm. This has been fixed on master. I can dig up the bug 
report if you need it (away from git history at the moment)

Even with this fixed, you'll still see some of the behavior you described about 
repeating the same probe byte even if the remote side ACKs it. This is because 
LwIP can't send or ACK a partial segment, only the full segment. Once the 
window opens back up, the probe byte will be sent again as part of the full 
segment. Wireshark typically marks it as a retransmission 


> On Apr 1, 2017, at 17:33, Yao Lin <address@hidden> wrote:
> Hi,
> I am using Stable 1.4.1 in my device. This device sends 4MB of TCP data to a
> Windows laptop. I am using netcomm API.
> 1. When Windows is about to use up its TCP buffer, it sends a packet (P1)
> with rwnd = 0 and ACK to, say, 2M.
> 2. Within 0.12s after receiving P1, lwip sends a packet (P2) with seq = 2M
> and len = 1.
> 3. Windows sends P3 with ACK = 2M + 1 and rwnd = 0.
> 4. Now we go through many iterations of 4.1 and 4.2:
>    4.1. lwip sends P4 with seq = 2M and len = 0.
>    4.2. Windows sends P5 with ACK = 2M + 1 and rwnd = 0.
> 5. Eventually, Windows opens up its rwnd. So it sends P6 with ACK = 2M + 1
> and rwnd = 4096 (or something similar).
> 6. Lwip sends P7 with seq = 2M and len = 1460.
> Now you can see Windows receives the duplicated byte 2M.
> So my question is, why does lwip send P4 and P7 with seq = 2M instead of 2M
> + 1? Note that Windows ACK = 2M + 1 in P3, P5, and P6.
> Thanks.
> --
> View this message in context: 
> http://lwip.100.n7.nabble.com/zero-window-probe-causes-duplicated-byte-to-be-received-tp29221.html
> Sent from the lwip-users mailing list archive at Nabble.com.
> _______________________________________________
> lwip-users mailing list
> address@hidden
> https://lists.nongnu.org/mailman/listinfo/lwip-users

reply via email to

[Prev in Thread] Current Thread [Next in Thread]