From owner-freebsd-hackers Wed Sep 22 20:19:51 1999 Delivered-To: freebsd-hackers@freebsd.org Received: from whizzo.transsys.com (whizzo.TransSys.COM [144.202.42.10]) by hub.freebsd.org (Postfix) with ESMTP id 360AF1542F for ; Wed, 22 Sep 1999 20:19:48 -0700 (PDT) (envelope-from louie@whizzo.transsys.com) Received: from whizzo.transsys.com (localhost.transsys.com [127.0.0.1]) by whizzo.transsys.com (8.9.3/8.9.1) with ESMTP id XAA61915; Wed, 22 Sep 1999 23:19:47 -0400 (EDT) (envelope-from louie@whizzo.transsys.com) Message-Id: <199909230319.XAA61915@whizzo.transsys.com> X-Mailer: exmh version 2.0.2 2/24/98 To: Brian Dean Cc: freebsd-hackers@FreeBSD.ORG From: "Louis A. Mamakos" Subject: Re: how to shut down a TCP connection References: <199909212245.SAA02737@vger.foo.com> In-reply-to: Your message of "Tue, 21 Sep 1999 18:45:08 EDT." <199909212245.SAA02737@vger.foo.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Wed, 22 Sep 1999 23:19:47 -0400 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG > Hi, > > I'm doing TCP development on a custom operating system that I've > written and am using my FreeBSD box for testing my TCP stack. I'm in > the early stages right now and I have a lot of bugs. One of my bugs > is that I shut down a connection on my end but I'm doing something > wrong and the connection on the FreeBSD side stays up, i.e.: > > [bsd@vger]:/net- netstat > Active Internet connections > Proto Recv-Q Send-Q Local Address Foreign Address (state) > tcp 0 0 vger.telnet bos.5000 ESTABLISHED > > 'vger' is my FreeBSD machine and 'bos' is my experimental OS. The > connecton on 'bos' at this point is actually closed. > > Does anyone know how I can manually shutdown the above connection on > 'vger' short of waiting a really long time or rebooting? Since this is a telnet session, you could find out what login session this connection is associated with it, and write something to the pty so data will need to be sent on the connection. The remote end with either respond with a RST segment aborting the connection, or eventually the connection wil die due to an ACK timeout. Typically, I just use the write(1) command to do this to an abandoned telnet session. louie To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message