From owner-freebsd-stable@FreeBSD.ORG Mon Aug 27 09:28:24 2012 Return-Path: Delivered-To: freebsd-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 23972106566B for ; Mon, 27 Aug 2012 09:28:24 +0000 (UTC) (envelope-from stb@lassitu.de) Received: from gilb.zs64.net (gilb.zs64.net [IPv6:2a00:14b0:4200:32e0::1ea]) by mx1.freebsd.org (Postfix) with ESMTP id B08FC8FC0C for ; Mon, 27 Aug 2012 09:28:23 +0000 (UTC) Received: by gilb.zs64.net (Postfix, from stb@lassitu.de) id 1A72412E599; Mon, 27 Aug 2012 09:28:16 +0000 (UTC) Mime-Version: 1.0 (Apple Message framework v1278) Content-Type: text/plain; charset=us-ascii From: Stefan Bethke In-Reply-To: <2d4dfcb2637f4d0e9671899538b603d9@xtaz.co.uk> Date: Mon, 27 Aug 2012 11:28:15 +0200 Content-Transfer-Encoding: quoted-printable Message-Id: <67DFAA78-A9A2-49F9-9C29-CA5653ECE3C0@lassitu.de> References: <2d4dfcb2637f4d0e9671899538b603d9@xtaz.co.uk> To: Matt Smith X-Mailer: Apple Mail (2.1278) Cc: freebsd-stable@freebsd.org Subject: Re: 9.1 RELENG_9 Unable to cleanly dismount root partition on shutdown X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 27 Aug 2012 09:28:24 -0000 Am 27.08.2012 um 11:06 schrieb Matt Smith: > I posted on this mailing list two weeks ago and never received any = replies so I decided to raise a PR via the web form. But I think I = submitted it under the wrong category and it's marked as low priority as = well. But I think this is something that is a potential serious problem = if I end up getting a corrupted filesystem so I'm posting here again in = the hope somebody can help this time. The PR is amd64/170646. >=20 > I'm now running the latest RELENG_9 code as of 25th August as I've = done a new buildworld/kernel. I still get the same problem. When I = reboot it I get WARNING: / was not properly dismounted and it rebuilds = from journal. On shutdown I get the messages pasted below. I'm running = amd64 with GPT partitioning, UFS2 with softupdates and softupdates = journalling enabled. I have a custom kernel but I don't think I took = anything important out of it. >=20 > Syncing disks, vnodes remaining...7 7 2 0 0 done > All buffers synced. > fsync: giving up on dirty > 0xfffffe0007102780: tag devfs, type VCHR > usecount 1, writecount 0, refcount 2292 mountedhere = 0xfffffe000000729ca00 > flags (VI(0x200)) > v_object 0xfffffe0005101910 ref 0 pages 23509 > lock type devfs: EXCL by thread 0xfffffe00018fe08e0 (pid 1) > dev label/root > umount of / failed (35) >=20 > Then when the box comes back up again it detects that / was not = unmounted > cleanly and recovers from journal before marking it clean once more. > My fstab: > /dev/label/root / ufs rw 1 1 > /dev/label/swap none swap sw 0 0 Is there a particular reason you've decided to glabel your partitions = instead of using GPT labels? Which device did you do the newfs on, the = GPT partition or the glabel device? My hunch is that the label metadata = sector at the end of the GPT partition is interfering with the = filesystem. I'd try labelling my partitions (gpart modify -i 2 -l root ada0; gpart = modify -i 3 -l swap), then change fstab to reference the gpt labels = (dev(gpt/root) instead of the glabel ones. Stefan --=20 Stefan Bethke Fon +49 151 14070811