From owner-freebsd-questions@FreeBSD.ORG Mon Apr 26 05:49:14 2004 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 1D8F816A4CE for ; Mon, 26 Apr 2004 05:49:14 -0700 (PDT) Received: from msr72.hinet.net (msr72.hinet.net [168.95.4.172]) by mx1.FreeBSD.org (Postfix) with ESMTP id 69B3E43D62 for ; Mon, 26 Apr 2004 05:49:13 -0700 (PDT) (envelope-from y2kbug@ms25.hinet.net) Received: from sonic.utopia.com (61-227-219-230.dynamic.hinet.net [61.227.219.230]) by msr72.hinet.net (8.9.3/8.9.3) with SMTP id UAA27851 for ; Mon, 26 Apr 2004 20:49:10 +0800 (CST) Date: Mon, 26 Apr 2004 20:46:39 +0800 From: Robert Storey To: freebsd-questions@freebsd.org Message-Id: <20040426204639.0f6fce69.y2kbug@ms25.hinet.net> In-Reply-To: <20040426203000.47eb04fc.y2kbug@ms25.hinet.net> References: <3C73D6BD-9718-11D8-931D-000393A4799C@nospammail.net> <20040426002855.GA49376@xor.obsecurity.org> <20040426160937.60dbbe5a.y2kbug@ms25.hinet.net> <20040426203000.47eb04fc.y2kbug@ms25.hinet.net> X-Mailer: Sylpheed version 0.9.7 (GTK+ 1.2.10; i386-portbld-freebsd5.2) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Subject: Re: Auto-mounting ext2 slices X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 26 Apr 2004 12:49:14 -0000 Just to make sure my partition table wasn't borked, I booted into Linux, and fsck on the same ext2 partition does work as expected: root@sonic:~> fsck /dev/hda6 fsck 1.35-WIP (21-Aug-2003) e2fsck 1.35-WIP (21-Aug-2003) /dev/hda6: clean, 7920/671744 files, 90705/1343427 blocks So, I don't know... - Robert On Mon, 26 Apr 2004 20:30:00 +0800 Robert Storey wrote: > I am not having good luck doing an fsck on /dev/ad0s6 (which is indeed a Linux > ext2 partition). Here's what happens (note that partition is unmounted): > > root@sonic:~> e2fsck /dev/ad0s6 > e2fsck 1.32 (09-Nov-2002) > The filesystem size (according to the superblock) is 1343427 blocks > The physical size of the device is 0 blocks > Either the superblock or the partition table is likely to be corrupt! > Abort? yes > > root@sonic:~> fsck_ext2fs /dev/ad0s6 > ** /dev/ad0s6 > BAD SUPER BLOCK: MAGIC NUMBER WRONG > ioctl (GCINFO): Inappropriate ioctl for device > /dev/ad0s6: can't read disk label > > This partition is not dirty, and I can mount and unmount it if I want to: > > root@sonic:~> mount_ext2fs /dev/ad0s6 /shared > root@sonic:~> ls -d b* > bison-1.35 bison-1.35.tar.gz book.txt > root@sonic:~> cd > root@sonic:~> umount /shared > root@sonic:~> cd /shared > root@sonic:/shared> ls > root@sonic:/shared> > > But how can I fsck it? I must be doing something wrong. > > best regards, > Robert > "