Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 10 Feb 2000 13:18:54 +0200
From:      Ruslan Ermilov <ru@ucb.crimea.ua>
To:        Ernst de Haan <ernst@znerd.demon.nl>
Cc:        freebsd-questions@FreeBSD.ORG
Subject:   Re: Boot record repair program?
Message-ID:  <20000210131854.A68362@relay.ucb.crimea.ua>
In-Reply-To: <38A28D6F.DE8BADDF@znerd.demon.nl>; from Ernst de Haan on Thu, Feb 10, 2000 at 11:05:35AM %2B0100
References:  <38A2778A.4F76CB8B@znerd.demon.nl> <20000210104119.B29395@relay.ucb.crimea.ua> <38A28D6F.DE8BADDF@znerd.demon.nl>

next in thread | previous in thread | raw e-mail | index | archive | help
On Thu, Feb 10, 2000 at 11:05:35AM +0100, Ernst de Haan wrote:
> It was in `compatible' mode, cuz Winblows didn't start up if me 2nd disk
> was in `dangerously dedicated mode'.
>=20
> Any help would be greatly appreciated. I'm going to install a new harddisk
> now and install FreeBSD on that one and then try to copy all data from the
> old disk to the new. Problem is, I don't know where the partitions start
> :(
>=20
> I used to have my partitions like this (for what I recall):
>=20
> 1st FreeBSD  (about 3 GB)
> 2nd Linux (about 3 GB?)
> 3rd Linux swap (about 120 MB)
>=20
> But this is what FIPS gives me under DOS (i compressed the table):
>=20
> --------------------
> Which Drive (1=3D0x80/2=3D0x81/=08)? 2
>=20
> Partition table:
>=20
>  |boot|    Start |      |     End    | Start  |Number of|
> #|able|Hd Cyl Sec|System|Hd  Cyl  Sec| Sector |Sectors  |  MB
> -+----+----------+------+------------+--------+---------+----
> 1|yes | 1 768  63|   FFh|254 1917  63|16711935| 16753663|8180
> 2| no | 0 894  63|   FFh|254 1807  63|16753663| 16747519|8177
> 3| no | 0 768  63|   FFh|  0 1792  63|16711935| 16711935|8160
> 4| no | 0 768  63|   FFh|  0 1792  63|16711935| 16711935|8160
>=20
> Checking root sector ...=20
> Error: Invalid root sector signature: FF AA
>=20
> This is weird as I dont recall havig _4_ partitions (but it could be I
> created different partitions for / and /usr (?) ) and the size of the
> partitions are way out of bounds for my Quantum Fireball 6.4A (6.4 GB)
>=20
>=20
FreeBSD fdisk(8) has a number of options to cope with MBR (including
partition table); it can install new boot code (/boot/mbr by default),
initialize the disk in "dedicated" mode, set active partition, etc.
Refer to the fdisk(8) manpage for details.

But if partition table is clobberred... it should be restored somehow,
and this is a not-so-easy, though still possible, task.  Basically,
you would need to scan through the disk and find the BSD disklabel,
and then manually re-create partition table, but this is beyond this
discussion, and I think ports/sysutils/gpart is more intelligent on
this one:

: A port of a tool which tries to guess the primary partition table of a PC=
-type
: hard disk in case the primary partition table in sector 0 is damaged, inc=
orrect
: or deleted. The guessed table can be written to a file or device.
:=20
: Supported (guessable) filesystem or partition types: DOS/Windows FAT, Lin=
ux
: ext2 and swap, OS/2 HPFS, Windows NTFS, FreeBSD and Solaris/x86 disklabel=
s,
: Minix FS, Reiser FS
:=20
: Author: Michail Brzitwa <mb@ichabod.han.de>
: WWW: http://home.pages.de/~michab/gpart/
:=20
: - Andrew Stevenson
: <andrew@ugh.net.au>


HTH,
--=20
Ruslan Ermilov		Sysadmin and DBA of the
ru@ucb.crimea.ua	United Commercial Bank,
ru@FreeBSD.org		FreeBSD committer,
+380.652.247.647	Simferopol, Ukraine

http://www.FreeBSD.org	The Power To Serve
http://www.oracle.com	Enabling The Information Age


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




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