From owner-freebsd-stable@FreeBSD.ORG Thu Apr 28 09:50:06 2011 Return-Path: Delivered-To: freebsd-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id DA23F1065673 for ; Thu, 28 Apr 2011 09:50:06 +0000 (UTC) (envelope-from edhoprima@gmail.com) Received: from mail-bw0-f54.google.com (mail-bw0-f54.google.com [209.85.214.54]) by mx1.freebsd.org (Postfix) with ESMTP id 5F47C8FC14 for ; Thu, 28 Apr 2011 09:50:05 +0000 (UTC) Received: by bwz12 with SMTP id 12so3052467bwz.13 for ; Thu, 28 Apr 2011 02:50:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc:content-type; bh=zicydOrStaNaf1O+EpLFL0n4FVPgP94QQJoCz0CG7yc=; b=MLF0kRU5bG6JpnVlzTLsk4kk9XBYEh27QQWnYO1+MxtkCI5mQTRJFXiE9PLsYtFPVL e/aJnM5ZTADAHBvWeQcgDQU0aNN+EwSwlvAwo5MIi9hqZsd8Q8sPagC1ac0IVHLJZHNk 2SZkocJ9KXx/MMb6lDO5p5ZZ9CMsxBIBxxXe4= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type; b=P3HYHpi8c+WSMv18RiSEHM1MzzZ30XymV/oZahs4dzsgLpFEIhsGljYk9s5jLXtoPj W7t062Im30O7qXUtjJ11Q8NaLF15wQqZD5TDxbaVy40quaC8qF1aZ2go9quEPtW6Geef 9WPXmqpJMLu3G9aXsNNgF0FQaPerceHse5hkk= Received: by 10.204.19.6 with SMTP id y6mr3024631bka.159.1303982473088; Thu, 28 Apr 2011 02:21:13 -0700 (PDT) MIME-Version: 1.0 Received: by 10.204.112.71 with HTTP; Thu, 28 Apr 2011 02:20:52 -0700 (PDT) In-Reply-To: <4DB9303E.9090305@digsys.bg> References: <20110427221554.GB22139@lava.net> <4DB9303E.9090305@digsys.bg> From: Edho P Arief Date: Thu, 28 Apr 2011 16:20:52 +0700 Message-ID: To: Daniel Kalchev Content-Type: text/plain; charset=UTF-8 Cc: freebsd-stable@freebsd.org Subject: Re: correct way to setup gmirror on 7.4? 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: Thu, 28 Apr 2011 09:50:06 -0000 On Thu, Apr 28, 2011 at 4:15 PM, Daniel Kalchev wrote: > > > On 28.04.11 01:30, Freddie Cash wrote: >> >> gmirror doesn't touch the start of the disk, but saves it's metadata >> in the last sector of the disk, and creates a new GEOM provider that's >> one sector shorter. >> >> GPT stores it's partition table in the first sector of the disk, and >> saves a backup copy of it in the last sector of the disk. > > This looks like layering issue to me. > > In theory, both gmirror and gpt should work on 'providers'. So if you give > an gmirrored provider to gpt it should touch the last sector of the gmirror, > but not the last sector of the disk - and not complain. It should not even > be able to see the last sector of the real disk. > > Is this hard to fix? > I believe it goes like this gmX: | gpt | data | gpt | which in actual disk goes like this: adY: | gpt | data | gpt | gmirror | so geom read gpt in the first sector but doesn't find it in the last sector.