Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 27 Jun 2012 12:05:22 -0700
From:      Marcel Moolenaar <marcel@xcllnt.net>
To:        Pawel Jakub Dawidek <pjd@FreeBSD.org>
Cc:        freebsd-current <freebsd-current@FreeBSD.org>, freebsd-hackers <freebsd-hackers@FreeBSD.org>, "Andrey V. Elsukov" <bu7cher@yandex.ru>, Andriy Gapon <avg@FreeBSD.org>
Subject:   Re: [CFC/CFT] large changes in the loader(8) code
Message-ID:  <05236C69-0029-4FB1-ADFA-243D64AA3079@xcllnt.net>
In-Reply-To: <20120627183446.GC1401@garage.freebsd.pl>
References:  <4FE9B01C.30306@yandex.ru> <201206261337.11741.jhb@freebsd.org> <20120626212308.GE1399@garage.freebsd.pl> <CAN6yY1vBSPjeP6HzuH4ityRhguGhi-b9Nd=YRfyAtfNZaNSC7A@mail.gmail.com> <20120626214330.GG1399@garage.freebsd.pl> <E5F4BCA6-8AEF-40C2-B44A-D2050069D0A7@xcllnt.net> <20120627183446.GC1401@garage.freebsd.pl>

next in thread | previous in thread | raw e-mail | index | archive | help

On Jun 27, 2012, at 11:34 AM, Pawel Jakub Dawidek wrote:
> 
> I'm sorry, Marcel, but what you describe here has nothing to do with
> reality. To be able to implement realiable mirroring you have to use
> on-disk metadata. There is no way around that. You can implement
> non-redundant GEOM classes without using on-disk metadata, but
> out-of-band configuration in case of mirroring is simply naive. How do
> you detect that components are out of sync, for example?

GEOM configuration and per-class runtime state are not to be
treated the same. Out-of-band configuration is trivial.
Per-class runtime state, like whether elements in a mirrored
configuration are in sync or not is more difficult, but does
not a priori require on-disk metadata as it's implemented now.
You can have the configuration tell the GEOM where that state
is being kept, so that you can put it in a partition on the
disks involved, or even keep it independent from the disks,
which then requires disks to be uniquely identifiable, for
sure. But that's what GPT gives you anyway.

But even without identification, you can invert the question
from "how do I detect that components are out of sync" to
"how do I prove they are in fact in sync". That question has
a very simple O(n) answer. So, if time isn't a concern or
your storage is small, you can always scan all sectors as
such prove that the disks are in sync.

The point being: the current implementation isn't the only
one. Granted, it can easily be the simplest one or even the
best one in some cases, but that's besides the point you were
making.

-- 
Marcel Moolenaar
marcel@xcllnt.net





Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?05236C69-0029-4FB1-ADFA-243D64AA3079>