From owner-freebsd-fs@FreeBSD.ORG Mon Feb 4 21:03:06 2008 Return-Path: Delivered-To: freebsd-fs@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9EFFD16A420 for ; Mon, 4 Feb 2008 21:03:06 +0000 (UTC) (envelope-from jhs@berklix.org) Received: from tower.berklix.org (tower.berklix.org [83.236.223.114]) by mx1.freebsd.org (Postfix) with ESMTP id 0D8CA13C465 for ; Mon, 4 Feb 2008 21:03:05 +0000 (UTC) (envelope-from jhs@berklix.org) Received: from js.berklix.net (p549A7E7E.dip.t-dialin.net [84.154.126.126]) (authenticated bits=0) by tower.berklix.org (8.13.6/8.13.6) with ESMTP id m14L33gQ097040; Mon, 4 Feb 2008 21:03:03 GMT (envelope-from jhs@berklix.org) Received: from fire.js.berklix.net (fire.js.berklix.net [192.168.91.41]) by js.berklix.net (8.13.8/8.13.8) with ESMTP id m14L4vu9025875; Mon, 4 Feb 2008 22:04:57 +0100 (CET) (envelope-from jhs@berklix.org) Received: from fire.js.berklix.net (localhost [127.0.0.1]) by fire.js.berklix.net (8.13.8/8.13.8) with ESMTP id m14L4lep052239; Mon, 4 Feb 2008 22:04:52 +0100 (CET) (envelope-from jhs@fire.js.berklix.net) Message-Id: <200802042104.m14L4lep052239@fire.js.berklix.net> To: Martin Cracauer In-reply-to: <20080204205801.GA7398@cons.org> References: <20080201172214.GA55957@cons.org> <200802021916.m12JGUjN049706@fire.js.berklix.net> <20080204163308.GA96092@cons.org> <200802041727.m14HREuN049123@fire.js.berklix.net> <20080204205801.GA7398@cons.org> Comments: In-reply-to Martin Cracauer message dated "Mon, 04 Feb 2008 15:58:01 -0500." Date: Mon, 04 Feb 2008 22:04:47 +0100 From: "Julian H. Stacey" Cc: freebsd-fs@freebsd.org Subject: Re: fsck and mount disagree on whether superblocks are usable X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 04 Feb 2008 21:03:06 -0000 Martin Cracauer wrote: > Julian H. Stacey wrote on Mon, Feb 04, 2008 at 06:27:14PM +0100: > > Martin Cracauer wrote: > > > Julian H. Stacey wrote on Sat, Feb 02, 2008 at 08:16:30PM +0100: > > > > Martin Cracauer wrote: > > > > > This is not an emergency but I find it odd. Mount and fsck agree on > > > > > whether superblocks are usable. Mount can mount readonly, but fsck > > > > > can use neither the primary superblock nor the alternatives. > > > > > > > > > > 32 is not a file system superblock > > > > > > > > Just in case, You know secondary block on newer FSs moved from 32 ? > > > > Ref man fsck_ufs > > > > -b Use the block specified immediately after the flag as the super > > > > block for the file system. An alternate super block is usually > > > > located at block 32 for UFS1, and block 160 for UFS2. > > > > > > Thanks, Julian. > > > > > > I'm honestly don't know how to tell whether I have ufs1 or ufs2. > > > > I didnt either, but wanted to know & just found one way: > > > > dumpfs /dev/____ | grep -i ufs > > Yupp, there you go. > The reason why it failed for me is that it was looking for the > superblocks in the wrong place. > > This works: > fsck_ffs -b 160 /dev/ad0s1a > > I now need to debug why the target machine's fsck seemed to think it's > ufs1 or why else it looked at 32 when the source machine didn't. Yup, always nice to understand whats going on/went on, but at some stage in your shoes, I'd copy all data to another place & then newfs & copy back, for peace of mind :-) -- Julian Stacey. BSD Unix Linux Net Consultant, Munich. http://berklix.com