From owner-freebsd-bugs@freebsd.org Tue Sep 5 16:44:11 2017 Return-Path: Delivered-To: freebsd-bugs@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id ADF31E11D30 for ; Tue, 5 Sep 2017 16:44:11 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2001:1900:2254:206a::16:76]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 84F556E9AC for ; Tue, 5 Sep 2017 16:44:11 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from bugs.freebsd.org ([127.0.1.118]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id v85GiBxL055411 for ; Tue, 5 Sep 2017 16:44:11 GMT (envelope-from bugzilla-noreply@freebsd.org) From: bugzilla-noreply@freebsd.org To: freebsd-bugs@FreeBSD.org Subject: [Bug 222074] TCP stall with rfc1323 enabled Date: Tue, 05 Sep 2017 16:44:11 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: kern X-Bugzilla-Version: 11.1-RELEASE X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Only Me X-Bugzilla-Who: aragon@phat.za.net X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: freebsd-bugs@FreeBSD.org X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version rep_platform op_sys bug_status bug_severity priority component assigned_to reporter Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 05 Sep 2017 16:44:11 -0000 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D222074 Bug ID: 222074 Summary: TCP stall with rfc1323 enabled Product: Base System Version: 11.1-RELEASE Hardware: Any OS: Any Status: New Severity: Affects Only Me Priority: --- Component: kern Assignee: freebsd-bugs@FreeBSD.org Reporter: aragon@phat.za.net I've stumbled upon some strange behaviour when RFC1323 is enabled in conjunction with multiple layers of MPD interfaces. TCP transfers stall, a= nd with net.inet.tcp.log_debug enabled I see one kernel message get logged when the stall occurs: Sep 5 18:12:28 roo kernel: TCP: [213.138.116.73]:80 to [192.168.104.0]:48841 tcpflags 0x12; tcp_do_segment: Timestamp not expected, no action My network setup looks like this: 192.168.104.0 [ng1] <-> MPD L2TP <-> 197.215.183.131 [ng0] <-> MPD PPPoE <-> Internet <-> 213.138.116.73 So in words, I'm running an L2TP tunnel over a PPPoE tunnel to my ISP, and = all these layers operate on the same host that's experiencing the RFC1323 relat= ed TCP issue. 213.138.116.73 above is pkg.FreeBSD.org, and 192.168.104.0 is the local tun= nel address on the affected host. When I do an HTTP GET, eg. curl -o /dev/null http://pkg.FreeBSD.org/FreeBSD:11:amd64/quarterly/All/bird-1.6.3_3.txz The transfer stalls after a few KB, and a tcpdump of ng1 shows this: 18:28:13.643389 IP 192.168.104.0.35277 > 213.138.116.73.80: Flags [S], seq 353584016, win 65535, options [mss 1360,nop,wscale 6,sackOK,TS val 764211736 ecr 0], length 0 18:28:13.835812 IP 213.138.116.73.80 > 192.168.104.0.35277: Flags [S.], seq 4183396526, ack 353584017, win 65535, options [mss 1310,nop,wscale 11,sackO= K,TS val 3582066608 ecr 764211736], length 0 18:28:13.835882 IP 192.168.104.0.35277 > 213.138.116.73.80: Flags [.], ack = 1, win 1043, options [nop,nop,TS val 764211928 ecr 3582066608], length 0 18:28:13.835970 IP 192.168.104.0.35277 > 213.138.116.73.80: Flags [P.], seq 1:127, ack 1, win 1043, options [nop,nop,TS val 764211928 ecr 3582066608], length 126: HTTP: GET /FreeBSD:11:amd64/quarterly/All/bird-1.6.3_3.txz HTTP= /1.1 18:28:14.028199 IP 213.138.116.73.80 > 192.168.104.0.35277: Flags [.], ack = 127, win 512, options [nop,nop,TS val 3582066800 ecr 764211928], length 0 18:28:14.028317 IP 213.138.116.73.80 > 192.168.104.0.35277: Flags [.], seq 1:1299, ack 127, win 512, options [nop,nop,TS val 3582066800 ecr 764211928], length 1298: HTTP: HTTP/1.1 200 OK 18:28:14.028482 IP 213.138.116.73.80 > 192.168.104.0.35277: Flags [.], seq 1299:2597, ack 127, win 512, options [nop,nop,TS val 3582066800 ecr 7642119= 28], length 1298: HTTP 18:28:14.028498 IP 192.168.104.0.35277 > 213.138.116.73.80: Flags [.], ack 2597, win 1023, options [nop,nop,TS val 764212121 ecr 3582066800], length 0 18:28:14.028524 IP 213.138.116.73.80 > 192.168.104.0.35277: Flags [.], seq 2597:3895, ack 127, win 512, options [nop,nop,TS val 3582066800 ecr 7642119= 28], length 1298: HTTP 18:28:14.028532 IP 213.138.116.73.80 > 192.168.104.0.35277: Flags [.], seq 3895:5193, ack 127, win 512, options [nop,nop,TS val 3582066800 ecr 7642119= 28], length 1298: HTTP 18:28:14.028744 IP 213.138.116.73.80 > 192.168.104.0.35277: Flags [.], seq 5193:6491, ack 127, win 512, options [nop,nop,TS val 3582066800 ecr 7642119= 28], length 1298: HTTP 18:28:14.028755 IP 213.138.116.73.80 > 192.168.104.0.35277: Flags [.], seq 6491:7789, ack 127, win 512, options [nop,nop,TS val 3582066800 ecr 7642119= 28], length 1298: HTTP 18:28:14.028828 IP 213.138.116.73.80 > 192.168.104.0.35277: Flags [.], seq 7789:9087, ack 127, win 512, options [nop,nop,TS val 3582066800 ecr 7642119= 28], length 1298: HTTP 18:28:14.028944 IP 213.138.116.73.80 > 192.168.104.0.35277: Flags [.], seq 9087:10385, ack 127, win 512, options [nop,nop,TS val 3582066800 ecr 764211928], length 1298: HTTP 18:28:14.029071 IP 213.138.116.73.80 > 192.168.104.0.35277: Flags [.], seq 10385:11683, ack 127, win 512, options [nop,nop,TS val 3582066800 ecr 764211928], length 1298: HTTP 18:28:14.220094 IP 213.138.116.73.80 > 192.168.104.0.35277: Flags [.], seq 11683:12981, ack 127, win 512, options [nop,nop,TS val 3582066992 ecr 764212121], length 1298: HTTP 18:28:14.220112 IP 192.168.104.0.35277 > 213.138.116.73.80: Flags [.], ack 2597, win 1043, options [nop,nop,TS val 764212313 ecr 3582066800,nop,nop,sa= ck 1 {11683:12981}], length 0 18:28:14.220136 IP 213.138.116.73.80 > 192.168.104.0.35277: Flags [.], seq 12981:14279, ack 127, win 512, options [nop,nop,TS val 3582066992 ecr 764212121], length 1298: HTTP 18:28:14.220159 IP 192.168.104.0.35277 > 213.138.116.73.80: Flags [.], ack 2597, win 1043, options [nop,nop,TS val 764212313 ecr 3582066800,nop,nop,sa= ck 1 {11683:14279}], length 0 18:28:14.412476 IP 213.138.116.73.80 > 192.168.104.0.35277: Flags [.], seq 14279:15577, ack 127, win 512, options [nop,nop,TS val 3582067184 ecr 764212313], length 1298: HTTP 18:28:14.412489 IP 192.168.104.0.35277 > 213.138.116.73.80: Flags [.], ack 2597, win 1043, options [nop,nop,TS val 764212505 ecr 3582066800,nop,nop,sa= ck 1 {11683:15577}], length 0 18:28:14.604109 IP 213.138.116.73.80 > 192.168.104.0.35277: Flags [.], seq 2597:3895, ack 127, win 512, options [nop,nop,TS val 3582067376 ecr 7642125= 05], length 1298: HTTP 18:28:14.604127 IP 192.168.104.0.35277 > 213.138.116.73.80: Flags [.], ack 3895, win 1023, options [nop,nop,TS val 764212697 ecr 3582067376,nop,nop,sa= ck 1 {11683:15577}], length 0 18:28:14.604236 IP 213.138.116.73.80 > 192.168.104.0.35277: Flags [.], seq 3895:5193, ack 127, win 512, options [nop,nop,TS val 3582067376 ecr 7642125= 05], length 1298: HTTP 18:28:14.604257 IP 192.168.104.0.35277 > 213.138.116.73.80: Flags [.], ack 5193, win 1023, options [nop,nop,TS val 764212697 ecr 3582067376,nop,nop,sa= ck 1 {11683:15577}], length 0 18:28:14.604287 IP 213.138.116.73.80 > 192.168.104.0.35277: Flags [.], seq 5193:6491, ack 127, win 512, options [nop,nop,TS val 3582067376 ecr 7642125= 05], length 1298: HTTP 18:28:14.604298 IP 213.138.116.73.80 > 192.168.104.0.35277: Flags [.], seq 6491:7789, ack 127, win 512, options [nop,nop,TS val 3582067376 ecr 7642125= 05], length 1298: HTTP 18:28:14.604357 IP 213.138.116.73.80 > 192.168.104.0.35277: Flags [.], seq 7789:7837, ack 127, win 512, options [nop,nop,TS val 3582067376 ecr 7642125= 05], length 48: HTTP 18:28:14.604367 IP 192.168.104.0.35277 > 213.138.116.73.80: Flags [.], ack 5193, win 1043, options [nop,nop,TS val 764212697 ecr 3582067376,nop,nop,sa= ck 2 {7789:7837}{11683:15577}], length 0 18:28:14.796498 IP 213.138.116.73.80 > 192.168.104.0.35277: Flags [.], seq 7837:9135, ack 127, win 512, options [nop,nop,TS val 3582067568 ecr 7642126= 97], length 1298: HTTP 18:28:14.796513 IP 192.168.104.0.35277 > 213.138.116.73.80: Flags [.], ack 5193, win 1043, options [nop,nop,TS val 764212889 ecr 3582067376,nop,nop,sa= ck 2 {7789:9135}{11683:15577}], length 0 18:28:14.796533 IP 213.138.116.73.80 > 192.168.104.0.35277: Flags [.], seq 9135:10433, ack 127, win 512, options [nop,nop,TS val 3582067568 ecr 764212697], length 1298: HTTP 18:28:14.796544 IP 213.138.116.73.80 > 192.168.104.0.35277: Flags [.], seq 10433:10481, ack 127, win 512, options [nop,nop,TS val 3582067568 ecr 764212697], length 48: HTTP 18:28:14.988262 IP 213.138.116.73.80 > 192.168.104.0.35277: Flags [.], seq 10481:11683, ack 127, win 512, options [nop,nop,TS val 3582067760 ecr 764212889], length 1202: HTTP 18:28:14.988275 IP 192.168.104.0.35277 > 213.138.116.73.80: Flags [.], ack 5193, win 1043, options [nop,nop,TS val 764213081 ecr 3582067376,nop,nop,sa= ck 2 {10481:15577}{7789:9135}], length 0 18:28:15.204013 IP 213.138.116.73.80 > 192.168.104.0.35277: Flags [.], seq 5193:6491, ack 127, win 512, options [nop,nop,TS val 3582067976 ecr 7642130= 81], length 1298: HTTP 18:28:15.204030 IP 213.138.116.73.80 > 192.168.104.0.35277: Flags [.], seq 6491:6503, ack 127, win 512, options [nop,nop,TS val 3582067976 ecr 7642130= 81], length 12: HTTP 18:28:15.820052 IP 213.138.116.73.80 > 192.168.104.0.35277: Flags [.], seq 5193:6491, ack 127, win 512, options [nop,nop,TS val 3582068592 ecr 7642130= 81], length 1298: HTTP 18:28:15.820066 IP 213.138.116.73.80 > 192.168.104.0.35277: Flags [.], seq 6491:6503, ack 127, win 512, options [nop,nop,TS val 3582068592 ecr 7642130= 81], length 12: HTTP 18:28:16.852097 IP 213.138.116.73.80 > 192.168.104.0.35277: Flags [.], seq 5193:6491, ack 127, win 512, options [nop,nop,TS val 3582069624 ecr 7642130= 81], length 1298: HTTP 18:28:16.852110 IP 213.138.116.73.80 > 192.168.104.0.35277: Flags [.], seq 6491:6503, ack 127, win 512, options [nop,nop,TS val 3582069624 ecr 7642130= 81], length 12: HTTP 18:28:18.716112 IP 213.138.116.73.80 > 192.168.104.0.35277: Flags [.], seq 5193:6491, ack 127, win 512, options [nop,nop,TS val 3582071488 ecr 7642130= 81], length 1298: HTTP 18:28:18.716125 IP 213.138.116.73.80 > 192.168.104.0.35277: Flags [.], seq 6491:6503, ack 127, win 512, options [nop,nop,TS val 3582071488 ecr 7642130= 81], length 12: HTTP 18:28:22.243953 IP 213.138.116.73.80 > 192.168.104.0.35277: Flags [.], seq 5193:6491, ack 127, win 512, options [nop,nop,TS val 3582075016 ecr 7642130= 81], length 1298: HTTP 18:28:22.243965 IP 213.138.116.73.80 > 192.168.104.0.35277: Flags [.], seq 6491:6503, ack 127, win 512, options [nop,nop,TS val 3582075016 ecr 7642130= 81], length 12: HTTP 18:28:29.099858 IP 213.138.116.73.80 > 192.168.104.0.35277: Flags [.], seq 5193:6491, ack 127, win 512, options [nop,nop,TS val 3582081872 ecr 7642130= 81], length 1298: HTTP 18:28:29.099872 IP 213.138.116.73.80 > 192.168.104.0.35277: Flags [.], seq 6491:6503, ack 127, win 512, options [nop,nop,TS val 3582081872 ecr 7642130= 81], length 12: HTTP 18:28:42.614902 IP 213.138.116.73.80 > 192.168.104.0.35277: Flags [.], seq 5193:6491, ack 127, win 512, options [nop,nop,TS val 3582095387 ecr 7642130= 81], length 1298: HTTP 18:28:42.614915 IP 213.138.116.73.80 > 192.168.104.0.35277: Flags [.], seq 6491:6503, ack 127, win 512, options [nop,nop,TS val 3582095387 ecr 7642130= 81], length 12: HTTP If I disable net.inet.tcp.rfc1323, the transfer succeeds with no kernel messages. If I enable net.inet.tcp.rfc1323, but I route IP traffic via the PPPoE interface (one less NG/MPD layer), the transfer succeeds with 1 kernel mess= age: Sep 5 18:39:45 roo kernel: TCP: [213.138.116.73]:80 to [197.215.183.131]:59766 tcpflags 0x12; tcp_do_segment: Timestamp n= ot expected, no action --=20 You are receiving this mail because: You are the assignee for the bug.=