From owner-freebsd-current Thu Mar 28 6:45:24 2002 Delivered-To: freebsd-current@freebsd.org Received: from mail14.speakeasy.net (mail14.speakeasy.net [216.254.0.214]) by hub.freebsd.org (Postfix) with ESMTP id 5F20A37B41F for ; Thu, 28 Mar 2002 06:45:08 -0800 (PST) Received: (qmail 22565 invoked from network); 28 Mar 2002 14:45:07 -0000 Received: from unknown (HELO server.baldwin.cx) ([216.27.160.63]) (envelope-sender ) by mail14.speakeasy.net (qmail-ldap-1.03) with DES-CBC3-SHA encrypted SMTP for ; 28 Mar 2002 14:45:07 -0000 Received: from laptop.baldwin.cx (gw1.twc.weather.com [216.133.140.1]) by server.baldwin.cx (8.11.6/8.11.6) with ESMTP id g2SEjnv95800; Thu, 28 Mar 2002 09:45:50 -0500 (EST) (envelope-from jhb@FreeBSD.org) Message-ID: X-Mailer: XFMail 1.5.2 on FreeBSD X-Priority: 3 (Normal) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 8bit MIME-Version: 1.0 In-Reply-To: <43760.1017325790@critter.freebsd.dk> Date: Thu, 28 Mar 2002 09:45:09 -0500 (EST) From: John Baldwin To: Poul-Henning Kamp Subject: RE: Surefire -current panic... Cc: current@freebsd.org Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On 28-Mar-2002 Poul-Henning Kamp wrote: > > On a diskless machine: > ktrace ntpdate -d $someserver > gives an sure-fire panic: > > ../../../kern/kern_synch.c:429: sleeping with "process lock" locked from > ../../. > ./kern/subr_trap.c:76 > Debugger("witness_sleep") > Stopped at Debugger+0x40: xorl %eax,%eax > db> trace > Debugger(c02f20c0) at Debugger+0x40 > witness_sleep(0,0,c02eeef8,1ad) at witness_sleep+0xfb > msleep(ccdfd2d8,0,4d,c02fbfce,0) at msleep+0x72 > nfs_flush(ccdfd294,cce37980,1,cce25700,1) at nfs_flush+0x663 > nfs_fsync(cce5cab4) at nfs_fsync+0x19 > vinvalbuf(ccdfd294,1,cce37980,cce25700,0,0) at vinvalbuf+0x9f > nfs_vinvalbuf(ccdfd294,1,cce37980,cce25700,1) at nfs_vinvalbuf+0x114 > nfs_write(cce5cbec,ccde6a40,cce25600,cce25888,cce5cbec) at nfs_write+0x120 > ktrwrite(ccdfd294,ccde6a40,0,5) at ktrwrite+0x101 > ktrpsig(ccdfd294,e,804a6b4,cce25888,0) at ktrpsig+0x78 > postsig(e) at postsig+0xaa > userret(cce25700,cce5cd48,11,0,0) at userret+0x4a > syscall(2f,2f,2f,0,0) at syscall+0x2b4 > syscall_with_err_pushed() at syscall_with_err_pushed+0x1b > --- syscall (4, FreeBSD ELF, write), eip = 0x280aac83, esp = 0xbfbffb50, ebp > = 0 > xbfbffb9c --- > db> Ktrace is evil and vile in this respect, so for now, don't use it. :) The fix is to move all the actual ktrwrite() stuff off into a worker async thread. I've done most of this (the ktrgenio needs some extra work still to properly synchronize so events don't get out of order) however, I need to finish the td_ucred stuff and then I can get back and finish it. It is next on the plate after td_ucred is done. -- John Baldwin <>< http://www.FreeBSD.org/~jhb/ "Power Users Use the Power to Serve!" - http://www.FreeBSD.org/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message