From owner-freebsd-current@FreeBSD.ORG Sun Mar 18 18:46:31 2007 Return-Path: X-Original-To: freebsd-current@freebsd.org Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 9352D16A401 for ; Sun, 18 Mar 2007 18:46:31 +0000 (UTC) (envelope-from julian@elischer.org) Received: from outR.internet-mail-service.net (outR.internet-mail-service.net [216.240.47.241]) by mx1.freebsd.org (Postfix) with ESMTP id 739A613C517 for ; Sun, 18 Mar 2007 18:46:31 +0000 (UTC) (envelope-from julian@elischer.org) Received: from mx0.idiom.com (HELO idiom.com) (216.240.32.160) by out.internet-mail-service.net (qpsmtpd/0.32) with ESMTP; Sun, 18 Mar 2007 11:18:52 -0700 Received: from [192.168.2.4] (home.elischer.org [216.240.48.38]) by idiom.com (Postfix) with ESMTP id A3F5C125B12; Sun, 18 Mar 2007 11:46:30 -0700 (PDT) Message-ID: <45FD8906.2060700@elischer.org> Date: Sun, 18 Mar 2007 11:46:30 -0700 From: Julian Elischer User-Agent: Thunderbird 1.5.0.10 (Macintosh/20070221) MIME-Version: 1.0 To: Robert Watson References: <20070308125927.GA1265@seekingfire.com> <20070308204041.GA55240@xor.obsecurity.org> <20070310153206.GF1230@seekingfire.com> <3bbf2fe10703100749h14e9b075wb6d730ed7c9189f8@mail.gmail.com> <20070310161423.GA1256@seekingfire.com> <20070310193946.GA96514@xor.obsecurity.org> <20070311044033.GB1256@seekingfire.com> <20070311062637.GA1256@seekingfire.com> <20070318125635.N62476@maildrop.int.zabbadoz.net> <20070318154536.U20456@fledge.watson.org> In-Reply-To: <20070318154536.U20456@fledge.watson.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: "Bjoern A. Zeeb" , freebsd-current@freebsd.org, Tillman Hodgson Subject: Re: Experiencing hangs on SMP box with no console messages given for clues. Details inside. 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: Sun, 18 Mar 2007 18:46:31 -0000 Robert Watson wrote: > > On Sun, 18 Mar 2007, Bjoern A. Zeeb wrote: > >> On Sun, 11 Mar 2007, Tillman Hodgson wrote: >> >>> On Sat, Mar 10, 2007 at 10:40:33PM -0600, Tillman Hodgson wrote: >>>> Shouldn't take more than a day or two to get the info requested in >>>> 11.9. >>> >>> As it turns out, a few hours. >>> >>> After capturing the information below I ran `panic`. While booting, >>> the following lock messages came up -- I thought it might be related >>> so I'll post it here: > > If using uid/gid firewall rules, make sure to read the pertinent man > pages regarding setting debug.mpsafenet=0 in loader.conf to avoid > deadlocks. This is only a workaround for the issue, and when > debug.mpsafenet is removed, this workaround will no longer be > available. The authors/maintainers of the various firewall packages > need to correct these problems or the lock order reversals (and > associated deadlocks) will persist. > I actually have some work on this in an experimental branch.. it removes the requirement for users of ipfw to hold a lock on it by making the firewall table an array rather than a lined list and then using a read-copy-replace write semantic with reference conts on the array.. a bit like the cred structures that processes and threads have.. i.e. you never change it, just replace it with a new one.. previosu users ofthe structure just keep using the one they have and release the reference when they are done.. (freeing if it goes to 0). the result is that since the firewall lock goes away, so does the lock order reversal.