From owner-freebsd-geom@FreeBSD.ORG Sat Jun 23 19:17:18 2007 Return-Path: X-Original-To: freebsd-geom@freebsd.org Delivered-To: freebsd-geom@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 5A98916A421 for ; Sat, 23 Jun 2007 19:17:18 +0000 (UTC) (envelope-from nonsolosoft@diff.org) Received: from smtpi1.ngi.it (smtpi1.ngi.it [88.149.128.20]) by mx1.freebsd.org (Postfix) with ESMTP id ED42113C4B7 for ; Sat, 23 Jun 2007 19:17:17 +0000 (UTC) (envelope-from nonsolosoft@diff.org) Received: from k7.diff.org (81-174-26-135.static.ngi.it [81.174.26.135] (may be forged)) by smtpi1.ngi.it (8.13.8/8.13.8) with ESMTP id l5NDt90m014525; Sat, 23 Jun 2007 15:55:10 +0200 Received: from [127.0.0.1] (localhost [127.0.0.1]) by k7.diff.org (8.13.8/8.13.8) with ESMTP id l5NDtnG7068094; Sat, 23 Jun 2007 15:55:52 +0200 (CEST) (envelope-from nonsolosoft@diff.org) Message-ID: <467D2665.4030903@diff.org> Date: Sat, 23 Jun 2007 15:55:49 +0200 From: Ferruccio Zamuner Organization: NonSoLoSoft - Italy - http://www.nonsolosoft.com/ User-Agent: Thunderbird 1.5.0.9 (X11/20070110) MIME-Version: 1.0 To: freebsd-geom@freebsd.org Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: nonsolosoft@diff.org Subject: gmirror and offset X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 23 Jun 2007 19:17:18 -0000 /dev/ad4 has running FreeBSD 6.2-RELEASE from where: r1# dd if=/dev/zero of=/dev/ad6 bs=512 count=79 79+0 records in 79+0 records out 40448 bytes transferred in 0.012255 secs (3300543 bytes/sec) r1# /usr/sbin/sysinstall to create ad6s1, ad6s2, ad6s3 and made ad6s1 "active" r1# fdisk /dev/ad6 ******* Working on device /dev/ad6 ******* parameters extracted from in-core disklabel are: cylinders=232581 heads=16 sectors/track=63 (1008 blks/cyl) Figures below won't work with BIOS for partitions not in cyl 1 parameters to be used for BIOS calculations are: cylinders=232581 heads=16 sectors/track=63 (1008 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 167766732 (81917 Meg), flag 80 (active) beg: cyl 0/ head 1/ sector 1; end: cyl 1023/ head 254/ sector 63 The data for partition 2 is: sysid 165 (0xa5),(FreeBSD/NetBSD/386BSD) start 167766795, size 2104515 (1027 Meg), flag 0 beg: cyl 1023/ head 255/ sector 63; end: cyl 1023/ head 254/ sector 63 The data for partition 3 is: sysid 165 (0xa5),(FreeBSD/NetBSD/386BSD) start 169871310, size 64565235 (31525 Meg), flag 0 beg: cyl 1023/ head 255/ sector 63; end: cyl 1023/ head 254/ sector 63 The data for partition 4 is: r1# bsdlabel ad6s1 # /dev/ad6s1: 8 partitions: # size offset fstype [fsize bsize bps/cpg] c: 167766732 0 unused 0 0 # "raw" part, don't edit I want to create a mirror on ad6s1: r1# gmirror label -h -v -b split -s 4096 gm0 ad6s1 Metadata value stored on ad6s1. Done. r1# gmirror load r1# bsdlabel /dev/mirror/gm0 # /dev/mirror/gm0: 8 partitions: # size offset fstype [fsize bsize bps/cpg] c: 167766732 63 unused 0 0 # "raw" part, don't edit partition c: partition extends past end of unit bsdlabel: partition c doesn't start at 0! bsdlabel: partition c doesn't cover the whole unit! bsdlabel: An incorrect partition c may cause problems for standard system utilities What have I done wrong? I've tried to edit bsdlabel: r1# bsdlabel -e /dev/mirror/gm0 and when I'm in the editor I find: ----- # /dev/mirror/gm0: 8 partitions: # size offset fstype [fsize bsize bps/cpg] a: 234441632 16 unused 0 0 c: 167766732 63 unused 0 0 # "raw" part, don't edit ----- Then I modify it to: ----- # /dev/mirror/gm0: 8 partitions: # size offset fstype [fsize bsize bps/cpg] a: 2097152 0 4.2BSD 0 0 0 c: 167766732 0 unused 0 0 # "raw" part, don't edit e: 12582912 2097152 4.2BSD 0 0 0 f: 20971520 14680064 4.2BSD 0 0 0 g: 14680064 35651584 4.2BSD 0 0 0 h: 117435084 50331648 4.2BSD 0 0 0 ----- BUT bsdlabel writes: ----- partition c: partition extends past end of unit bsdlabel: partition c doesn't cover the whole unit! bsdlabel: An incorrect partition c may cause problems for standard system utilities partition h: partition extends past end of unit re-edit the label? [y]: ----- How can I fix it? Bye, \fer