Re: panic: nfssvc_nfsd(): debug.mpsafenet=1 && Giant

From: Christian Brueffer <chris_at_unixpages.org>
Date: Wed, 25 Aug 2004 17:07:24 +0200
On Tue, Aug 24, 2004 at 11:18:55PM -0400, Robert Watson wrote:
> 
> On Tue, 24 Aug 2004, Christian Brueffer wrote:
> 
> > I'm getting the following panic on 6-CURRENT as well as 5.3-BETA1 with
> > sources from today.  It's easily reproducible on both, with
> > debug.mpsafenet=1. 
> 
> Hmm.  Looks like something has acquired and failed to release Giant in the
> NFS server.  It could be we're leaking Giant in an error case that didn't
> turn up in previous testing, but for some reason is more common in your
> environment.  Unfortunately, as Giant can be acquired recursively, the
> "last acquired" information presented by WITNESS isn't useful to us.
> There are a couple of ways we could approach debugging this.  I think the
> easiest might be the following:
> 
> - Recompile your kernel with the following options:
> 
>   options KTR
>   options KTR_COMPILE=(KTR_LOCK|KTR_PROC)
>   options KTR_ENTRIES=16384
> 
> - At run-time, before triggering the crash, use sysctl to set the
>   following settings:
> 
>   sysctl debug.ktr.cpumask=0xff
>   sysctl debug.ktr.mask=`sysctl -n debug.ktr.compile`
> 
> - When the crash occurs, use "show ktr" to list recent lock operations.
>   Using your serial console, copy and paste a few pages of locking
>   operations into an e-mail, probably until you hit the next context
>   switch (mi_switch: new thread).  You'll notice that the entries are
>   sorted by event id, which generally results in reverse-chronological
>   order with most recent event earliest.  We'd like to look at all
>   acquisitions of Giant and releases of Giant since that context switch.
>   There should be one or more acquires than releases in the event stream,
>   and we'd like to figure out which is the one not associated with a
>   matching unlock.
> 

The complete output is available at

http://people.freebsd.org/~brueffer/screenlog.0.gz

- Christian

-- 
Christian Brueffer	chris_at_unixpages.org	brueffer_at_FreeBSD.org
GPG Key:	 http://people.freebsd.org/~brueffer/brueffer.key.asc
GPG Fingerprint: A5C8 2099 19FF AACA F41B  B29B 6C76 178C A0ED 982D

Received on Wed Aug 25 2004 - 13:07:33 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:38:08 UTC