Gmirror on a partition of a slice
ivoras at freebsd.org
Mon Sep 24 12:44:57 PDT 2007
On 24/09/2007, n j <nino80 at gmail.com> wrote:
> On 9/21/07, Ivan Voras <ivoras at freebsd.org> wrote:
> > Actually, you *can* do it if you really want to, because every GEOM
> > provider is a "whole disk" to the system, it's just that usually it's
> > not what you want.
> That is what I thought at first, but I spent a couple of days trying
> to boot off such a geom "disk" and had absolutely no success until I
> skipped the two steps Pawel pointed out. Actually, I'm beginning to
> think that OS has to read the boot code from an actual (physical) disk
> partition like da0s1a/da1s1a. In case you skip fdisk&bsdlabel on the
> gmirrored partition, gm0 remains the exact copy of the actual boot
> partition, da0s1a, and OS boots. By fdisk'ing and bsdlabel'ing the
> newly created disk, gm0, my understanding is that you actually change
> the underlying (boot) partition, da0s1a, and mess it up enough to make
> the system unbootable.
> The above interpretation, OTOH, might be completely wrong. My
> understanding of the boot process is very vague and you might be
> right. I'm not saying it's not possible, I'm just saying that I tried
> it and it didn't work, no matter how hard I try. If you care to
> describe the necessary steps on how to do it, I'll try again.
When the machine boots, it sees the drives as ordinary devices, as it
has no knowledge of gmirror. You can boot from one of these "ordinary"
drives, and when the kernel boots, it recognizes gmirror's signature,
reconstitutes the RAID and continues to work with it. But in the time
between between when you turn the machine on and when kernel brings
the GEOM system up, all you have are individual, disconnected drives.
This works because the drives are by default accessed strictly
read-only in this time frame. This is also how all other software RAID
More information about the freebsd-geom