[prev in list] [next in list] [prev in thread] [next in thread]
List: openbsd-bugs
Subject: kernel/1846: Honor TCPT_KEEP timer in state CLOSING
From: Armin Wolfermann <armin () wolfermann ! org>
Date: 2001-05-31 9:23:14
[Download RAW message or body]
>Number: 1846
>Category: kernel
>Synopsis: Honor TCPT_KEEP timer in state CLOSING
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: bugs
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Thu May 31 03:00:03 MDT 2001
>Last-Modified:
>Originator: Armin Wolfermann
>Organization:
net
>Release: 2.9
>Environment:
System : OpenBSD 2.9
Architecture: OpenBSD.i386
Machine : i386
>Description:
In a simultaneous close situation (server sends FIN, client
sends FIN shortly after) the connection enters state CLOSING
and a keepalive timer is set.
When this counter expires no check on idle time is made and
no probe packets are sent: the timer is reset to tcp_keepidle
and the connection loops forever.
>How-To-Repeat:
Run a lightly loaded webserver (2-3 hits/second) and observe
TCP connection state (eg via netstat). After a month of uptime
I had 100 connections looping in state CLOSING.
>Fix:
Index: tcp_timer.c
===================================================================
RCS file: /cvs/src/sys/netinet/tcp_timer.c,v
retrieving revision 1.20
diff -u -r1.20 tcp_timer.c
--- tcp_timer.c 2000/12/13 09:47:08 1.20
+++ tcp_timer.c 2001/05/30 15:14:15
@@ -390,7 +390,7 @@
if (TCPS_HAVEESTABLISHED(tp->t_state) == 0)
goto dropit;
if (tp->t_inpcb->inp_socket->so_options & SO_KEEPALIVE &&
- tp->t_state <= TCPS_CLOSE_WAIT) {
+ tp->t_state <= TCPS_CLOSING) {
if (tp->t_idle >= tcp_keepidle + tcp_maxidle)
goto dropit;
/*
>Audit-Trail:
>Unformatted:
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic