From owner-svn-src-head@FreeBSD.ORG Sun Dec 14 22:43:52 2008 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D4D4C106564A; Sun, 14 Dec 2008 22:43:52 +0000 (UTC) (envelope-from lulf@FreeBSD.org) Received: from mta2.eidsiva.net (mta2.eidsiva.net [82.147.40.138]) by mx1.freebsd.org (Postfix) with ESMTP id 0E0428FC1A; Sun, 14 Dec 2008 22:43:51 +0000 (UTC) (envelope-from lulf@FreeBSD.org) X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AjcsALsTRUlX+AYSPGdsb2JhbACTSQEBAQE1uS6Cfg X-IronPort-AV: E=Sophos;i="4.36,220,1228086000"; d="scan'208";a="6698280" Received: from 18.6.erx-lhm.eidsiva.net (HELO @) ([87.248.6.18]) by mtc2.eidsiva.net with ESMTP; 14 Dec 2008 23:13:41 +0100 Date: Sun, 14 Dec 2008 22:13:41 +0100 From: Ulf Lilleengen To: Pawel Jakub Dawidek Message-ID: <20081214211341.GA3575@nobby> References: <200812131414.mBDEEu0A031376@svn.freebsd.org> <20081214192100.GB16926@garage.freebsd.pl> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20081214192100.GB16926@garage.freebsd.pl> User-Agent: Mutt/1.5.18 (2008-05-17) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r186038 - head/sbin/geom/misc X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 14 Dec 2008 22:43:52 -0000 On Sun, Dec 14, 2008 at 08:21:01PM +0100, Pawel Jakub Dawidek wrote: > On Sat, Dec 13, 2008 at 02:14:56PM +0000, Ulf Lilleengen wrote: > > Author: lulf > > Date: Sat Dec 13 14:14:56 2008 > > New Revision: 186038 > > URL: http://svn.freebsd.org/changeset/base/186038 > > > > Log: > > - When writing metadata to a geom provider, open the it as read-write since it > > might do subsequent reads from other providers. This stopped geli (and > > probably other classes using g_metadata_store as well) from being put on top > > of gvinum raid5 volumes. > > > > Note: > > The reason it fails in the gvinum raid5 case is that gvinum will read back the > > old parity stripe before calculating the new parity stripe to be written out > > again. The write will then fail because the underlying disk to be read is > > opened write only. > > I think we discussed this in the past. In my opinion this change is > incorrect. The intend here is to only write something, that's why I use > O_WRONLY. If gvinum/raid5 needs also read something to satisfy the > write, this is gvinum/raid5's internal detail and should be handled > there. RAID5 by design needs to read before it can write (in most > cases), does it mean that the O_WRONLY flag became bogus suddenly? No. > The flag given to open(2) describes caller's intend, not provider's > internals. > Hmm, I understand your reasoning. But how can gvinum read from these internal providers then? Is there some way to override this internally in GEOM? -- Ulf Lilleengen