Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 23 Aug 1998 13:27:07 -0700
From:      Phil Staub <phils@casagate.staub.net>
To:        freebsd-fs@FreeBSD.ORG
Subject:   Need help recovering a trashed partition
Message-ID:  <35E07B1B.F7BC7E1C@staub.net>

next in thread | raw e-mail | index | archive | help
Apologies in advance if this question should have been sent to a
different list, but I thought this might have been a good place to
start. 

The situation: FreeBSD 2.2.7-STABLE running on a drive shared with two
other operating systems: Windoze 95 on slice 1, FreeBSD on slice 2,
Linux (sorry!) using slices 3 and 4.

In an attempt to install Linux on slices 3 and 4, I have somehow managed
to trash something (maybe several things) on my FreeBSD slice, in spite
of being very careful *not* to touch that slice when dealing with the
Linux partitions. Needless to say, I've set aside the Linux installation
for the time being, but now I have to deal with possible recovery of
whatever is left of FreeBSD.

First of all, I consider it to be a good sign that at least the
disklabel read from the disk seems to be intact. However, the bootstrap
was missing. (OS-BS boot menu reports "No operating system found"). So,
I went back in with the fixit disk and used disklabel -B to reinstall
the bootstrap. Now, OS-BS finds enough of the partition to see the
bootloader, but all it does is print one '-' out of the spinning bar
sequence, and hangs.

So I decided to try fsck. Back to the fixit disk, I ran fsck
/mnt2/dev/wd0s2 and it tells me that the superblock has a bad magic
number. It also said that the disk is labeled as a 4.2 filesystem, but
that the block length is zero. So I tried fsck -b 32 to try to use the
first alternate superblock. Now it just says bad magic number.

More information: I went into the disk partitioning and disk label
utility in sysinstall. They seemed to know about all of my partitions on
the FreeBSD slice. However, except for re-installing the bootstrap, I
haven't written anything else to the disk before I got some further
advice.

At this point, I've just about exhausted what little knowledge I have
about the FreeBSD filesystem layout. 

So the question is, is there any hope, and where do I go from here? (OK,
so it's two questions...)

Thanks,
Phil

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-fs" in the body of the message



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?35E07B1B.F7BC7E1C>