From owner-freebsd-current Sat Nov 2 2: 8:58 2002 Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6F37D37B401 for ; Sat, 2 Nov 2002 02:08:56 -0800 (PST) Received: from prg.traveller.cz (prg.traveller.cz [193.85.2.77]) by mx1.FreeBSD.org (Postfix) with ESMTP id 538E043E42 for ; Sat, 2 Nov 2002 02:08:55 -0800 (PST) (envelope-from mime@traveller.cz) Received: from prg.traveller.cz (localhost [127.0.0.1]) by prg.traveller.cz (8.12.2[KQ/pukvis]/8.12.2-prg) with ESMTP id gA2A8riT094145; Sat, 2 Nov 2002 11:08:53 +0100 (CET) Received: from localhost (mime@localhost) by prg.traveller.cz (8.12.2[KQ/pukvis]/8.12.2-prg/submit) with ESMTP id gA2A8rti094142; Sat, 2 Nov 2002 11:08:53 +0100 (CET) Date: Sat, 2 Nov 2002 11:08:53 +0100 (CET) From: Michal Mertl To: Bill Fenner Cc: current@FreeBSD.ORG Subject: Re: crash with network load (in tcp syncache ?) In-Reply-To: <200211012246.gA1Mki5n001478@stash.attlabs.att.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Fri, 1 Nov 2002, Bill Fenner wrote: > sonewconn() hands sofree() a self-inconsistent socket -- so->so_head is > set, so so must be on a queue, but sonewconn() hasn't put it on a queue yet. > Please try this patch. > > Bill > > Index: uipc_socket2.c > =================================================================== > RCS file: /home/ncvs/src/sys/kern/uipc_socket2.c,v > retrieving revision 1.104 > diff -u -r1.104 uipc_socket2.c > --- uipc_socket2.c 18 Sep 2002 19:44:11 -0000 1.104 > +++ uipc_socket2.c 1 Nov 2002 22:40:52 -0000 > @@ -192,7 +192,7 @@ > return ((struct socket *)0); > if ((head->so_options & SO_ACCEPTFILTER) != 0) > connstatus = 0; > - so->so_head = head; > + so->so_head = NULL; > so->so_type = head->so_type; > so->so_options = head->so_options &~ SO_ACCEPTCONN; > so->so_linger = head->so_linger; > @@ -209,6 +209,7 @@ > return ((struct socket *)0); > } > > + so->so_head = head; > if (connstatus) { > TAILQ_INSERT_TAIL(&head->so_comp, so, so_list); > so->so_state |= SS_COMP; > This patch fixes the panics for me. Thanks a lot. I believe it should be commited. BTW: I get about 850 fetches pers second on UP an 600 SMP (the same machine and settings). Don't know if it's expected in this usage pattern. -- Michal Mertl mime@traveller.cz To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message