From owner-freebsd-current@FreeBSD.ORG Wed May 4 06:42:34 2011 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8F23F106564A; Wed, 4 May 2011 06:42:34 +0000 (UTC) (envelope-from yanegomi@gmail.com) Received: from mail-vx0-f182.google.com (mail-vx0-f182.google.com [209.85.220.182]) by mx1.freebsd.org (Postfix) with ESMTP id 32FF58FC1A; Wed, 4 May 2011 06:42:33 +0000 (UTC) Received: by vxc34 with SMTP id 34so1145205vxc.13 for ; Tue, 03 May 2011 23:42:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type :content-transfer-encoding; bh=3JIKyo3g+hmUdomcTALYFkL5gm2/dnwhDFiHqzAM6BA=; b=JXHw6Q2L3x8biV1YmLpQt9lEoiDUdZsOBUUICL7SUbYwfolPztC1heL5fU0RKQXWqp V8gqhcIKfapqk/MjMl9iPHZQ7xyKOIvezwkRu4IS8K0wlQw1sPyY4QQtRrQLHtCQKI8Y DnymY1pzWHvHJYzvl78M+WDjrMkDqMH8GmeXI= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; b=kIeEYN4c/4fdA22jEQgPQjdQ1wAyHfrYbpdcQyCdjDgHjN2XUlXnjyTdFLJe1eKuKw Y8F1AnGpjkeOjI9qYHmaczVLLv+kTcz7x0ZaZMkLKnq0pknRp1mfisgjJLJj08p+UfUJ TH2nBtfloMIgATfOyRsaQ73GQPCyb3Q5ZndSE= MIME-Version: 1.0 Received: by 10.220.202.77 with SMTP id fd13mr188001vcb.81.1304491353219; Tue, 03 May 2011 23:42:33 -0700 (PDT) Received: by 10.220.199.130 with HTTP; Tue, 3 May 2011 23:42:32 -0700 (PDT) In-Reply-To: <201105040559.p445xEJ5024585@chez.mckusick.com> References: <201105040559.p445xEJ5024585@chez.mckusick.com> Date: Tue, 3 May 2011 23:42:32 -0700 Message-ID: From: Garrett Cooper To: Kirk McKusick Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Cc: FreeBSD Current Subject: Re: Nasty non-recursive lockmgr panic on softdep only enabled UFS partition when filesystem full X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 04 May 2011 06:42:34 -0000 On Tue, May 3, 2011 at 10:59 PM, Kirk McKusick wrot= e: >> Date: Tue, 3 May 2011 22:40:26 -0700 >> Subject: Nasty non-recursive lockmgr panic on softdep only enabled UFS >> =A0partition when filesystem full >> From: Garrett Cooper >> To: Jeff Roberson , >> =A0 =A0 =A0 =A0 Marshall Kirk McKusick >> Cc: FreeBSD Current >> >> Hi Jeff and Dr. McKusick, >> =A0 =A0 Ran into this panic when /usr ran out of space doing a make >> universe on amd64/r221219 (it took ~15 minutes for the panic to occur >> after the filesystem ran out of space -- wasn't quite sure what it was >> doing at the time): >> >> ... >> >> =A0 =A0 Let me know what other commands you would like for me to run in = kgdb. >> Thanks, >> -Garrett > > You did not indicate whether you are running an 8.X system or a 9-current > system. It would be helpful to know that. I've actually been running CURRENT for a few years now, but you're right -- I didn't mention that part. > Jeff thinks that there may be a potential race in the locking code for > softdep_request_cleanup. If so, this patch for 9-current should fix it: > > Index: ffs_softdep.c > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > --- ffs_softdep.c =A0 =A0 =A0 (revision 221385) > +++ ffs_softdep.c =A0 =A0 =A0 (working copy) > @@ -11380,7 +11380,8 @@ > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0continue; > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0} > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0MNT_IUNLOCK(mp); > - =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 if (vget(lvp, LK_EXCLUSIVE = | LK_INTERLOCK, curthread)) { > + =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 if (vget(lvp, LK_EXCLUSIVE = | LK_NOWAIT | LK_INTERLOCK, > + =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 curthread)) { > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0MNT_ILOCK(= mp); > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0continue; > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0} > > If you are running an 8.X system, hopefully you will be able to apply it. I've applied it, rebuilt and installed the kernel, and trying to repro the case again. Will let you know how things go! Thanks! -Garrett