gmirror questions

Pawel Jakub Dawidek pjd at FreeBSD.org
Mon Sep 27 00:46:23 PDT 2004


On Mon, Sep 27, 2004 at 09:28:20AM +0300, Ruslan Ermilov wrote:
+> 1.  When I try to "bsdlabel -B /dev/mirror/m0", I get:
+> 
+> # bsdlabel -B /dev/mirror/m0
+> bsdlabel: Geom not found
+> 
+> Hopefully, using "/dev/mirror/m0c" works.  Any clue why this
+> doesn't work?

I can't reproduce it. Could you show me whole process starting from
creating a mirror?

+> 2.  Before a reboot, the state of the mirror was "COMPLETE".
+> 
+> After a first reboot, everything was ok.  After a second
+> reboot, I got this:
+> 
+> ad0: 38166MB <ST340014A/3.06> [77545/16/63] at ata0-master UDMA100
+> ad1: 38204MB <SAMSUNG SV0411N/UA100-11> [77622/16/63] at ata0-slave UDMA100
+> ad2: 38166MB <ST340014A/3.06> [77545/16/63] at ata1-master UDMA100
+> ad3: 38204MB <SAMSUNG SV0411N/UA100-11> [77622/16/63] at ata1-slave UDMA100
+> GEOM_MIRROR: Device m0 created (id=411263865).
+> GEOM_MIRROR: Device m0: provider ad1 detected.
+> GEOM_MIRROR: Device m0: provider ad3 detected.
+> GEOM_MIRROR: Device m0: provider ad3 activated.
+> GEOM_MIRROR: Device m0: provider mirror/m0 launched.
+> GEOM_MIRROR: Device m0: rebuilding provider ad1.
+> 
+> Any idea why it thinks ad1 should be rebuilt?

Because you use reboot(8) instead of shutdown(8) to reboot your machine?
When shutdown(8) is used, swap partition will be removed before reboot,
in your case, mirror is still open for writing on reboot, so it will
rebuild components on next boot, because they are marked as dirty.

+> 3.  The syncing process takes very long, how do I tune it using
+>     the kern.geom.mirror sysctls?

The kern.geom.mirror.syncs_per_sec sysctl means number of synchronization
requests per second, so you should increase it.
Increasing hz should also help, but I'm not sure actually.
There is a simple way to increase synchronization performance by adding
more g_mirror_sync_one() calls, but I need to think of some understandable
way to tune it.

+> 4.  Will the following work with GEOM_MIRROR?
+> 
+>     - mirror m0 is originally from two 10G providers (p1 and p2)
+>     - remove p2 from the mirror
+>     - add p3 of size 20G to the mirror
+>     - wait until p3 synchronizes with p1
+>     - remove p1 from the mirror
+> 
+>     Will m0's size grow up to 20G after this procedure?

No. Changing provider's attributes (such as mediasize, sectorsize), while
it is running is not supported by GEOM, AFAIK.

-- 
Pawel Jakub Dawidek                       http://www.FreeBSD.org
pjd at FreeBSD.org                           http://garage.freebsd.pl
FreeBSD committer                         Am I Evil? Yes, I Am!
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 187 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/freebsd-current/attachments/20040927/0654ed9e/attachment.bin


More information about the freebsd-current mailing list