Re: A gmirror question.

2008-10-29 Thread Stefan Moro
Ok, that explains it.

Thanks for the quick answers!

BR
Stefan
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: A gmirror question.

2008-10-28 Thread Mel
On Tuesday 28 October 2008 17:53:20 Stefan Moro wrote:

> But if this is the case, how does gmirror know that it should use (in
> my example above) ad10 and not ad4 as the additional disk in the
> mirror.
> Or does gmirror use something else than the /dev entries to address disks??
>
> I'm just curious how gmirror does this.

It doesn't care about the device name. Geom modules that are loaded into the 
kernel, register a 'taste' function, with the geom(4) subsystem, that tastes 
if a provider is something they want to work with. Effectively, this taste 
function reads the last sector and checks if it has gmirror metadata.
The geom system is the 'magician', which basically hands all providers to the 
loaded modules.

-- 
Mel

Problem with today's modular software: they start with the modules
and never get to the software part.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: A gmirror question.

2008-10-28 Thread Wojciech Puchar

If I have understood things correctly, gmirror stores all relevant
information about the mirror in the last sector on the provider.


exactly. it doesn't matter how the disks are connected.

all data is in last sector.

for non-mirrored drives it's useful to use glabel to get the same
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: A gmirror question.

2008-10-28 Thread Chris St Denis

Stefan Moro wrote:

Hi!

I've got a question regarding the way that gmirror identifies what
"components" (if that is the right term) are included in a mirror.

I recently created a mirror over two disks, ad2 and ad4. After some
bios changes (activating PATA) these devices were changed to ad6 and
ad10 respectively.
The "magic" thing (which probably isn't so magic =) ) here is that
after reboot, gmirror still managed to identify the mirror, now using
ad6 and ad10.

If I have understood things correctly, gmirror stores all relevant
information about the mirror in the last sector on the provider.

So I guess one possible solution is that gmirror ,during startup,
scans all disks/slices for this magic sector and then "starts" the
mirror.
But if this is the case, how does gmirror know that it should use (in
my example above) ad10 and not ad4 as the additional disk in the
mirror.
Or does gmirror use something else than the /dev entries to address disks??

I'm just curious how gmirror does this.


BR Stefan
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"
  


I don't know the technical details of the internal working of gmirror, 
but it likely uses the volume serial number or other such identifier.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"