From owner-freebsd-current@FreeBSD.ORG Wed Nov 12 16:16:47 2008 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 2F995106567D for ; Wed, 12 Nov 2008 16:16:47 +0000 (UTC) (envelope-from jdc@koitsu.dyndns.org) Received: from QMTA09.westchester.pa.mail.comcast.net (qmta09.westchester.pa.mail.comcast.net [76.96.62.96]) by mx1.freebsd.org (Postfix) with ESMTP id CB7488FC1A for ; Wed, 12 Nov 2008 16:16:46 +0000 (UTC) (envelope-from jdc@koitsu.dyndns.org) Received: from OMTA13.westchester.pa.mail.comcast.net ([76.96.62.52]) by QMTA09.westchester.pa.mail.comcast.net with comcast id eFYb1a01S17dt5G59GGmNn; Wed, 12 Nov 2008 16:16:46 +0000 Received: from koitsu.dyndns.org ([69.181.141.110]) by OMTA13.westchester.pa.mail.comcast.net with comcast id eGGl1a0032P6wsM3ZGGlJi; Wed, 12 Nov 2008 16:16:46 +0000 X-Authority-Analysis: v=1.0 c=1 a=QycZ5dHgAAAA:8 a=aoYfOkdCLitl7XRC0m4A:9 a=PwmAD6L5aw3FltTPbwIA:7 a=FkouZcnqdaKIlF9h1nNroozLn9kA:4 a=EoioJ0NPDVgA:10 a=SV7veod9ZcQA:10 a=LY0hPdMaydYA:10 Received: by icarus.home.lan (Postfix, from userid 1000) id D33C95C19; Wed, 12 Nov 2008 08:16:44 -0800 (PST) Date: Wed, 12 Nov 2008 08:16:44 -0800 From: Jeremy Chadwick To: Attilio Rao Message-ID: <20081112161644.GA98426@icarus.home.lan> References: <491AEBB5.8010001@zedat.fu-berlin.de> <20081112154240.GA28818@icarus.home.lan> <3bbf2fe10811120744hd740388s25e7413e84bbb8c1@mail.gmail.com> <20081112154744.GA28943@icarus.home.lan> <3bbf2fe10811120752k5e42b912nd0933771696519e0@mail.gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <3bbf2fe10811120752k5e42b912nd0933771696519e0@mail.gmail.com> User-Agent: Mutt/1.5.18 (2008-05-17) Cc: freebsd-current@freebsd.org, "O. Hartmann" Subject: Re: fsck_ufs after every reboot 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, 12 Nov 2008 16:16:47 -0000 On Wed, Nov 12, 2008 at 04:52:59PM +0100, Attilio Rao wrote: > 2008/11/12, Jeremy Chadwick : > > On Wed, Nov 12, 2008 at 04:44:52PM +0100, Attilio Rao wrote: > > > 2008/11/12, Jeremy Chadwick : > > > > On Wed, Nov 12, 2008 at 02:44:05PM +0000, O. Hartmann wrote: > > > > > I run FreeBSD 8.0/AMD64 on two boxes (one is a UP older AMD64 Athlon64 > > > > > 3500, other an 8-Core Dell Poweredge 1950). > > > > > > > > > > After nearly every reboot the box does fsck on all UFS2 filesystems. In > > > > > most cases, while shuting down, the box reports about not willing to die > > > > > processes and after a reboot, the filesystems are unclean. > > > > > > > > > > Is this a common problem at the moment or special? > > > > > > > > > > > > I've seen this happen on my CURRENT box at home when using "shutdown -p > > > > now". Instead of the box powering off, it would lock up near the very > > > > end of the shutdown process (before marking the filesystems clean). > > > > > > > > Oddly, this works fine in RELENG_7, so I'm guessing there's some ACPI > > > > development going on (I can't complain, it *is* CURRENT). > > > > > > This could cames after my VFS works. > > > Could you spend some time on this? > > > I will tell you what to look at. > > > > > > Sure thing! > > > > Let me know what I need to do to help, what information you need, or if > > I should revert some commits to see if the behaviour changes. Build > > date of the box (src-all csup'd about 45 minutes prior to the build > > date): > > > > FreeBSD icarus.home.lan 8.0-CURRENT FreeBSD 8.0-CURRENT #0: Fri Nov 7 14:19:03 PST 2008 root@icarus.home.lan:/usr/obj/usr/src/sys/X7SBA_CURRENT_amd64 amd64 > > Is this reproducible? I don't have an answer at this time. I've only performed "shutdown -p now" on this box twice since running CURRENT, and both times the problem described occurred. > I need you build a kernel with following options: > INVARIANT_SUPPORT > INVARIANTS > DEBUG_VFS_LOCKS > WITNESS > and without WITNESS_SKIPSPIN Will do. Relevant options I use: makeoptions DEBUG=-g # Build kernel with gdb(1) debug symbols options SCHED_ULE # ULE scheduler options PREEMPTION # Enable kernel thread preemption options BREAK_TO_DEBUGGER # Sending a serial BREAK drops to DDB options KDB # Enable kernel debugger support options KDB_TRACE # Print stack trace automatically on panic options DDB # Support DDB options GDB # Support remote GDB options INVARIANTS # Enable calls of extra sanity checking options INVARIANT_SUPPORT # Extra sanity checks of internal structures, required by INVARIANTS options WITNESS # Enable checks to detect deadlocks and cycles options DEBUG_VFS_LOCKS # vfs lock debugging I have physical access to the console of this machine on a regular basis. > once it hangs you have to break in DDB and look the state of the threads with: > db> ps > > This would be a start. > Other instructions will follow based on this result. Got it. Just need to wait a little while for world/kernel to build and then I'll be able to perform the necessary testing. I do have one question (and it's a general one): I assume without serial console (I'm excluding firewire because that's not an option here) or taking photos of the monitor, there's no way to effectively log all output from db> to disk for review/access later? (The obvious answer here is "yes that's correct", being as the kernel itself is more or less suspended at that point, but I thought I'd ask) -- | Jeremy Chadwick jdc at parodius.com | | Parodius Networking http://www.parodius.com/ | | UNIX Systems Administrator Mountain View, CA, USA | | Making life hard for others since 1977. PGP: 4BD6C0CB |