From owner-freebsd-hackers@FreeBSD.ORG Sun Sep 14 21:25:34 2003 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 5E48B16A4BF; Sun, 14 Sep 2003 21:25:34 -0700 (PDT) Received: from relay.macomnet.ru (relay.macomnet.ru [195.128.64.10]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9AC6D43F93; Sun, 14 Sep 2003 21:25:32 -0700 (PDT) (envelope-from maxim@macomnet.ru) Received: from news1.macomnet.ru (3m0zjb4i@news1.macomnet.ru [195.128.64.14]) by relay.macomnet.ru (8.11.6/8.11.6) with ESMTP id h8F4PPg15599539; Mon, 15 Sep 2003 08:25:25 +0400 (MSD) Date: Mon, 15 Sep 2003 08:25:25 +0400 (MSD) From: Maxim Konovalov To: Mike Silbersack In-Reply-To: <20030914230339.K1033@odysseus.silby.com> Message-ID: <20030915081818.F29770@news1.macomnet.ru> References: <16771.24.218.220.202.1063595471.squirrel@webmail.wvths.com> <20030914230339.K1033@odysseus.silby.com> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII cc: sysadmin@wvths.com cc: hackers@freebsd.org cc: rwatson@freebsd.org Subject: Re: 4.8-stable kernel panic X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 15 Sep 2003 04:25:34 -0000 On Sun, 14 Sep 2003, 23:05-0500, Mike Silbersack wrote: > > On Sun, 14 Sep 2003 sysadmin@wvths.com wrote: > > > Hello, > > > > It's been almost a month now since I posted the original message on the > > list and I'm wondering about the progress on resolving this problem. > > > > I still can reproduce the panics after cvs-supping to RELENG_4 ~ 23:00 EDT > > today. > > > > Thanks much. > > Ooops, I forgot to follow up on this. > > Ok, a few questions: > > 1. Can you compile INVARIANTS and INVARIANT_SUPPORT into your kernel? > That might help us track down the problem. > > 2. What does your network setup look like? Are you using divert sockets, > is there ppp in action, etc. > > I believe that I tried out your script at the time, and I couldn't find it > to cause any problems on my system. rwatson has fixed this panic in rev. 1.115 in -current: revision 1.115 date: 2003/08/26 14:11:48; author: rwatson; state: Exp; lines: +2 -0 M_PREPEND() with an argument of M_TRYWAIT can fail, meaning the returned mbuf can be NULL. Check for NULL in rip_output() when prepending an IP header. This prevents mbuf exhaustion from causing a local kernel panic when sending raw IP packets. PR: kern/55886 Reported by: Pawel Malachowski MFC after: 3 days and haven't MFCed it yet. Here is a patch for -stable: Index: sys/netinet/raw_ip.c =================================================================== RCS file: /home/ncvs/src/sys/netinet/raw_ip.c,v retrieving revision 1.64.2.17 diff -u -r1.64.2.17 raw_ip.c --- sys/netinet/raw_ip.c 9 Sep 2003 19:09:22 -0000 1.64.2.17 +++ sys/netinet/raw_ip.c 15 Sep 2003 04:21:59 -0000 @@ -257,6 +257,8 @@ return(EMSGSIZE); } M_PREPEND(m, sizeof(struct ip), M_WAIT); + if (m == NULL) + return(ENOBUFS); ip = mtod(m, struct ip *); ip->ip_tos = inp->inp_ip_tos; ip->ip_off = 0; %%% -- Maxim Konovalov, maxim@macomnet.ru, maxim@FreeBSD.org