From owner-freebsd-current@FreeBSD.ORG Wed Jun 3 16:09:46 2009 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 27AD31065673 for ; Wed, 3 Jun 2009 16:09:46 +0000 (UTC) (envelope-from wxs@atarininja.org) Received: from syn.atarininja.org (syn.csh.rit.edu [129.21.60.158]) by mx1.freebsd.org (Postfix) with ESMTP id EBCCF8FC08 for ; Wed, 3 Jun 2009 16:09:45 +0000 (UTC) (envelope-from wxs@atarininja.org) Received: by syn.atarininja.org (Postfix, from userid 1001) id 8270F5C37; Wed, 3 Jun 2009 12:09:45 -0400 (EDT) Date: Wed, 3 Jun 2009 12:09:45 -0400 From: Wesley Shields To: Dmitry Marakasov , bz@FreeBSD.org, jamie@FreeBSD.org Message-ID: <20090603160945.GC21014@atarininja.org> References: <20090601182012.GA21543@darkthrone.kvedulv.de> <20090603121307.GA15659@hades.panopticon> <20090603152810.GA21014@atarininja.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20090603152810.GA21014@atarininja.org> User-Agent: Mutt/1.5.19 (2009-01-05) Cc: Michael Moll , freebsd-current@freebsd.org Subject: Re: Kernel panic when accessing ZFS-Filesystem via NFS 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, 03 Jun 2009 16:09:46 -0000 On Wed, Jun 03, 2009 at 11:28:10AM -0400, Wesley Shields wrote: > On Wed, Jun 03, 2009 at 04:13:07PM +0400, Dmitry Marakasov wrote: > > * Michael Moll (kvedulv@kvedulv.de) wrote: > > > > Very same panic here. > > > > Also, for some reason writing dumps to disk don't work, it either > > stops after writing some megabytes in `Dumping 1554 MB: ...' (maximum > > value it managed to write is ~800MB), or just freezes with > > buffer-related message (may try to reproduct panic to get it). > > I'm seeing the same thing but I got a useful vmcore and crash.txt out of > it. I can put them online if anyone wants to see them. [ The panic message and backtrace from ddb is at http://people.freebsd.org/~wxs/crash.txt ] (kgdb) frame 12 #12 0xffffffff80572e7f in prison_priv_check (cred=0xffffff00168f5900, priv=334) at /usr/home/wxs/freebsd/src/head/sys/kern/kern_jail.c:3315 3315 switch (priv) { (kgdb) p priv $6 = 334 334 is PRIV_VFS_MOUNT_OWNER sys/kern/kern_jail.c: 3451 case PRIV_VFS_MOUNT_OWNER: 3452 if (cred->cr_prison->pr_allow & PR_ALLOW_MOUNT) 3453 return (0); 3454 else 3455 return (EPERM); (kgdb) p/x *cred $7 = {cr_ref = 0x1, cr_uid = 0x0, cr_ruid = 0x0, cr_svuid = 0x0, cr_ngroups = 0x1, cr_groups = {0x0 }, cr_rgid = 0x0, cr_svgid = 0x0, cr_uidinfo = 0x0, cr_ruidinfo = 0x0, cr_prison = 0x0, cr_vimage = 0x0, cr_flags = 0x0, cr_pspare = {0x0, 0x0}, cr_label = 0x0, cr_audit = {ai_auid = 0x0, ai_mask = {am_success = 0x0, am_failure = 0x0}, ai_termid = {at_port = 0x0, at_type = 0x0, at_addr = {0x0, 0x0, 0x0, 0x0}}, ai_asid = 0x0, ai_flags = 0x0}} (kgdb) cred->cr_prison is null? It is my understanding that when not jailed cred->cr_prison should be &prison0 with the new hierarchical jails. The fact that it is null is causing prison_priv_check to enter the switch statement, leading to the crash. I'm not sure why cred->cr_prison is null in this case. -- WXS