lwip-users
[Top][All Lists]
Advanced

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

Re: [lwip-users] TCP keep-alive not working on half-closed connections


From: address@hidden
Subject: Re: [lwip-users] TCP keep-alive not working on half-closed connections
Date: Wed, 6 Jun 2018 22:10:22 +0200
User-agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.8.0

On 06.06.2018 21:58, Joel Cunningham wrote:

On 06/06/2018 02:13 PM, address@hidden wrote:
https://stackoverflow.com/questions/18110239/does-tcp-endpoint-that-has-sent-a-fin-still-send-keepalive
https://social.msdn.microsoft.com/Forums/en-US/d20e5e67-d23c-42a5-95c5-ba80f4263546/keepalive-packets-continue-being-sent-after-client-closes-server-socket-is-closewait-client

Here's some findings on a FIN_WAIT_2 timeout:

https://serverfault.com/questions/738300/why-are-connections-in-fin-wait2-state-not-closed-by-the-linux-kernel
https://www.akronohio.gov/manual/misc/fin_wait_2.html

I don't believe a FIN_WAIT_2 timeout is implemented in LwIP.
No, we don't have that. We always said it's OK for a connection to
stay in FIN_WAIT_2. However, it seems we must handle this differently
depending on wether the user has called "shutdown" or "close". Then we
can implement a timeout.
Agreed, if the application used shutdown() on only the TX pathway, we
would not want to start a timeout until the RX pathway is also
shutdown.  Maybe even further delay the timeout until the app is done
with the socket as indicated by close().

I have just added 2 bug entries for this.

Simon



reply via email to

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