From owner-freebsd-stable@FreeBSD.ORG Fri Apr 7 10:11:14 2006 Return-Path: X-Original-To: stable@freebsd.org Delivered-To: freebsd-stable@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 9D1F216A403 for ; Fri, 7 Apr 2006 10:11:14 +0000 (UTC) (envelope-from pjd@garage.freebsd.pl) Received: from mail.garage.freebsd.pl (arm132.internetdsl.tpnet.pl [83.17.198.132]) by mx1.FreeBSD.org (Postfix) with ESMTP id D048543D46 for ; Fri, 7 Apr 2006 10:11:13 +0000 (GMT) (envelope-from pjd@garage.freebsd.pl) Received: by mail.garage.freebsd.pl (Postfix, from userid 65534) id 0EE3352126; Fri, 7 Apr 2006 12:11:12 +0200 (CEST) Received: from localhost (pjd.wheel.pl [10.0.1.1]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.garage.freebsd.pl (Postfix) with ESMTP id 5CE6250F93; Fri, 7 Apr 2006 12:11:05 +0200 (CEST) Date: Fri, 7 Apr 2006 12:10:01 +0200 From: Pawel Jakub Dawidek To: Mike Jakubik Message-ID: <20060407101001.GA11939@garage.freebsd.pl> References: <440D74B3.3030309@vwsoft.com> <200603070939.30032.joao@matik.com.br> <54559.192.168.0.10.1141751042.squirrel@webmail.sd73.bc.ca> <20060316160813.GA15720@nowhere> <442033A2.2030208@rogers.com> <442043D0.6090206@centtech.com> <4432EA5E.3060003@rogers.com> <20060406081213.GA5578@garage.freebsd.pl> <443518AB.5090109@rogers.com> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="BXVAT5kNtrzKuDFl" Content-Disposition: inline In-Reply-To: <443518AB.5090109@rogers.com> X-PGP-Key-URL: http://people.freebsd.org/~pjd/pjd.asc X-OS: FreeBSD 7.0-CURRENT i386 User-Agent: mutt-ng/devel-r535 (FreeBSD) X-Spam-Checker-Version: SpamAssassin 3.0.4 (2005-06-05) on mail.garage.freebsd.pl X-Spam-Level: X-Spam-Status: No, score=-5.9 required=3.0 tests=ALL_TRUSTED,BAYES_00 autolearn=ham version=3.0.4 Cc: stable@freebsd.org Subject: Re: gmirror on existing filesystem (was Fresh install on gmirror'ed disks?) X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Apr 2006 10:11:14 -0000 --BXVAT5kNtrzKuDFl Content-Type: text/plain; charset=iso-8859-2 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Thu, Apr 06, 2006 at 09:33:31AM -0400, Mike Jakubik wrote: +> Pawel Jakub Dawidek wrote: +> >One can still see how many sectors exactly has the partition he is going +> >to create file system on and add additional newfs(8) flag +> >'-s '. +> > =20 +>=20 +> "gmirror utility uses on-disk metadata (stored in the provider's last se= ctor) to store all needed information." +>=20 +> Would creating a freebsd partition thats slightly smaller than the disk = resolve the issue (when mirroring the entire disk)? or does it still use th= e last sector of the=20 +> label? I'm not sure what one means by "provider" in this case. "provider" in this case is what you use to create mirror on. If you do it by: # gmirror label foo ad0 ad2 Then disks ad0 and ad2 are providers where gmirror puts metadata in their last sector. In most cases, you create slices and then partitions. If you configure a mirror on partitions, eg. # gmirror label foo ad0s1a ad2s1a then you need to create file system one sector smaller with newfs(8) when you do it on adXs1a. When you configure a mirror on slices, eg. # gmirror label foo ad0s1 ad2s1 then your last partition created on adXs1 must end up before the slice end (its offset+size should be one sector smaller than the size of the slice). When you configure a mirror on disks, eg. # gmirror label foo ad0 ad2 then your last slice created on adXs1 have to end up before the disk end (just like in the previous case). In most cases, last slice ends before the disk end, leaving plenty of space at the end, so you should be safe here. In other cases the whole space is allocated (not sure if really used). In any case, system may complain if information about the original provider size is stored somewhere, ie. partitions were created on one sector bigger slice than gmirror provider, so 'c' partition will be one sector too large. --=20 Pawel Jakub Dawidek http://www.wheel.pl pjd@FreeBSD.org http://www.FreeBSD.org FreeBSD committer Am I Evil? Yes, I Am! --BXVAT5kNtrzKuDFl Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.2 (FreeBSD) iD8DBQFENjp5ForvXbEpPzQRAibPAJ4hpe2VoKtJYB/EXQfCsGARvk/xUwCfezEW qB8gpq0cr5x7qXklDQGICiM= =fnyT -----END PGP SIGNATURE----- --BXVAT5kNtrzKuDFl--