From owner-freebsd-hackers@FreeBSD.ORG Tue Apr 15 15:49:47 2014 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 8BD6C5B1 for ; Tue, 15 Apr 2014 15:49:47 +0000 (UTC) Received: from udns.ultimateDNS.NET (ultimatedns.net [209.180.214.225]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 468B11A59 for ; Tue, 15 Apr 2014 15:49:46 +0000 (UTC) Received: from udns.ultimateDNS.NET (localhost [127.0.0.1]) by udns.ultimateDNS.NET (8.14.5/8.14.5) with ESMTP id s3FFrPgt010036; Tue, 15 Apr 2014 08:53:31 -0700 (PDT) (envelope-from bsd-lists@bsdforge.com) Received: (from www@localhost) by udns.ultimateDNS.NET (8.14.5/8.14.5/Submit) id s3FFrKk4010033; Tue, 15 Apr 2014 08:53:20 -0700 (PDT) (envelope-from bsd-lists@bsdforge.com) Received: from udns.ultimatedns.net ([209.180.214.225]) (UDNSMS authenticated user chrish) by ultimatedns.net with HTTP; Tue, 15 Apr 2014 08:53:20 -0700 (PDT) Message-ID: In-Reply-To: <534D13A2.9000706@m5p.com> References: <534D13A2.9000706@m5p.com> Date: Tue, 15 Apr 2014 08:53:20 -0700 (PDT) Subject: Re: Clobbered MBR partition table From: "Chris H" To: "George Mitchell" User-Agent: UDNSMS/2.0.3 MIME-Version: 1.0 Content-Type: text/plain;charset=utf-8 Content-Transfer-Encoding: 8bit X-Priority: 3 (Normal) Importance: Normal Cc: freebsd-hackers@freebsd.org X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 15 Apr 2014 15:49:47 -0000 > My laptop has a hard disk I partitioned, whoops, I mean sliced, into > four slices when I installed 8.2-STABLE on it a couple of years ago. > The first, third, and fourth slices I reserved for future experiments, > and most of the space went into the second slice where I installed > 8.2-STABLE. Time went on and the second slice is currently running > 9.2-STABLE, and I installed 10.0-PRERELEASE on the first slice late > last year. But mostly I have been booting off the second slice, which > means pressing enter at the initial F1/F2/F3/F4 boot prompt. > > Then last Friday I was preparing to update the first slice to the > latest 10.0-STABLE. Things were going well until I rebooted and > typed F1 at the boot prompt. I immediately got a second prompt > offering me the options of second disk or PXE. At this point the > machine was unbootable, as whatever I typed would cycle between the > F1/F2/F3/F4 alternatives and the second disk/PXE alternatives. I hit > ctrl-alt-delete and got told there was no bootable disk. > > So I got a new disk and plugged in into the laptop and started over > again. (My first attempt was with a 10.0-RELEASE memstick image, > but that's a subject for another day.) Out of conservatism, I have > installed 8.4-STABLE on the new disk. Then the first thing I did > was to hook up the old disk through a USB adapter and dump it with > dd to a backup image. That's going to be finished in a couple of > hours, at which point I hope to poke around on the old disk and > repair what I assume is a clobbered master boot record partition > table. > > My question is: > What's the best tool to help reconstruct the partition table? I > think my problem will be mostly solved if I can find the BSD labels > on the old disk (which, by the way, has not exhibited any I/O errors > during the "dd" backup process). Do BSD labels have a recognizable > signature? Firstly; I'd have used dump(8), and restore(8). As opposed to dd(1). Because it's quite a bit more flexible, and rather than copying the entire disk/slice. It only copies the data actually consumed. Takes less time, and consumes less space. As to verifying, investigating the disk. I'd have a good look at gpart(8) -- gpart show, and gpart list, would be a good place to start. In fact, I just got finished mucking around with a few disks, and ultimately spent most of my time with gpart. As to your booting issue; you might want to have a look at boot0cfg(8). Best wishes. --Chris > > Thanks for your help and attention. -- George > _______________________________________________ > freebsd-hackers@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org" >