From owner-freebsd-current@FreeBSD.ORG Thu Nov 12 01:58:22 2009 Return-Path: Delivered-To: current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 80E4C1065679 for ; Thu, 12 Nov 2009 01:58:22 +0000 (UTC) (envelope-from xcllnt@mac.com) Received: from asmtpout026.mac.com (asmtpout026.mac.com [17.148.16.101]) by mx1.freebsd.org (Postfix) with ESMTP id 6D9168FC1B for ; Thu, 12 Nov 2009 01:58:22 +0000 (UTC) MIME-version: 1.0 Content-type: text/plain; charset=iso-8859-1 Received: from macbook-pro.lan.xcllnt.net (mail.xcllnt.net [75.101.29.67]) by asmtp026.mac.com (Sun Java(tm) System Messaging Server 6.3-8.01 (built Dec 16 2008; 32bit)) with ESMTPSA id <0KSZ00DPD459P030@asmtp026.mac.com> for current@freebsd.org; Wed, 11 Nov 2009 17:58:22 -0800 (PST) From: Marcel Moolenaar In-reply-to: <86d43omsb0.fsf@ds4.des.no> Date: Wed, 11 Nov 2009 17:58:20 -0800 Content-transfer-encoding: quoted-printable Message-id: <7D0E66F2-A3E1-40F9-949B-7C4347E61E21@mac.com> References: <86tyx0mxjw.fsf@ds4.des.no> <94D5F246-3413-4256-A0FB-6DF2D3BFE9D0@mac.com> <86d43omsb0.fsf@ds4.des.no> To: =?iso-8859-1?Q?Dag-Erling_Sm=F8rgrav?= X-Mailer: Apple Mail (2.1077) Cc: current@freebsd.org Subject: Re: How to confuse geom_part_mbr X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 12 Nov 2009 01:58:22 -0000 On Nov 11, 2009, at 5:43 PM, Dag-Erling Sm=F8rgrav wrote: > Marcel Moolenaar writes: >> Dag-Erling Sm=F8rgrav writes: >>> The machine won't boot, even though you have a valid partition table >>> on ad0 that points to a valid bsdlabel in ad0s1. >> No, you don't have a valid partition table on ad0, because >> you didn't remove the BSD disklabel in sector 2 on ad0. >=20 > Yes, I do have a valid partition table. It is exactly byte-by-byte > identical to the one I get after I zero sector two and re-run fdisk. > The fact that there is unwanted data in sector 2 does *not* make it = any > less valid. Of course it does. It's the same as GPT. There's a MBR in front of it and if you don't know about GPT tables, you'll see the MBR, otherwise you'll use the GPT. The difference is that the MBR in front of a BSD disklabel is not supposed to have partitions. But you may not be able to distinguish boot code from a valid partition entry. >=20 > What's more, this could have easily been avoided if geom_whatever gave > the partition table precedence over the label it found in sector 2. That break standard BSD disklabels, because they would be probed as MBRs. --=20 Marcel Moolenaar xcllnt@mac.com