From owner-freebsd-bugs@FreeBSD.ORG Sat Jul 30 08:10:12 2011 Return-Path: Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 1F194106564A for ; Sat, 30 Jul 2011 08:10:12 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id E9EF28FC08 for ; Sat, 30 Jul 2011 08:10:11 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.4/8.14.4) with ESMTP id p6U8ABA9007761 for ; Sat, 30 Jul 2011 08:10:11 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.4/8.14.4/Submit) id p6U8ABQw007760; Sat, 30 Jul 2011 08:10:11 GMT (envelope-from gnats) Date: Sat, 30 Jul 2011 08:10:11 GMT Message-Id: <201107300810.p6U8ABQw007760@freefall.freebsd.org> To: freebsd-bugs@FreeBSD.org From: Andriy Gapon Cc: Subject: Re: kern/159222: [boot0] unusual behavior writing boot0 from single user mode X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Andriy Gapon List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 30 Jul 2011 08:10:12 -0000 The following reply was made to PR kern/159222; it has been noted by GNATS. From: Andriy Gapon To: Tim Newsham Cc: bug-followup@FreeBSD.org Subject: Re: kern/159222: [boot0] unusual behavior writing boot0 from single user mode Date: Sat, 30 Jul 2011 11:03:04 +0300 on 28/07/2011 19:59 Tim Newsham said the following: > On Thu, Jul 28, 2011 at 5:27 AM, Andriy Gapon wrote: >> I've noticed that you report a problem with performing some disk-related >> operations, but you haven't provided any information about your disk partitioning >> and filesystem layout. >> Also you emphasized that the problem occurs in the single user mode, but it is not >> immediately clear if you tested the same operations in the multi-user mode. > > I believe I got a permission denied error when trying in multi > user mode. I assumed it was due to secure level. I just tried it > again now and it asked me twice for confirmation and when I > did reported: > fdisk: Class not found > fdisk: Failed to write sector zero > > at this point none of the issues I reported in the bug occur. Can you also try to perform a supposedly equivalent operation using gpart? /sbin/gpart bootcode -b /boot/boot0 da0 Both in multi-user and single-user modes? > As for disks, I have tried on two separate systems. One system was > created just for this test in vmware and used the .iso installer > and accepted the default partitioning and slicing offered by the installer. > I assume there's nothing special about it: > > ******* Working on device /dev/da0 ******* > parameters extracted from in-core disklabel are: > cylinders=1044 heads=255 sectors/track=63 (16065 blks/cyl) > > Figures below won't work with BIOS for partitions not in cyl 1 > parameters to be used for BIOS calculations are: > cylinders=1044 heads=255 sectors/track=63 (16065 blks/cyl) > > Media sector size is 512 > Warning: BIOS sector numbering starts with sector 1 > Information from DOS bootblock is: > The data for partition 1 is: > sysid 165 (0xa5),(FreeBSD/NetBSD/386BSD) > start 63, size 16771797 (8189 Meg), flag 80 (active) > beg: cyl 0/ head 1/ sector 1; > end: cyl 1023/ head 254/ sector 63 > The data for partition 2 is: > > The data for partition 3 is: > > The data for partition 4 is: > Can you pls also provide gpart show and gpart list outputs? -- Andriy Gapon