How to detect when gmirror sync is complete?

Mel Flynn mel.flynn+fbsd.questions at
Wed May 27 19:27:37 UTC 2009

On Tuesday 26 May 2009 22:33:54 Peter Steele wrote:
> I know I could have a script that continually checks "gmirror status" to
> detect when a gmirror synchronization has completed, but is there a more
> event-driven approach? Something that could be used to trigger and event
> like devd does for drive pulls/inserts would be nice. Is this possible?

Doesn't look like gmirror notifies devd. Look at devctl_notify examples[1] in 
the source tree to add it, where the hard part is figuring out when a gmirror 
sync is complete. Or you can file a PR requesting the feature, I'm sure you're 
not alone.

[1] Prototype: sys/bus.h, example: sys/dev/acpica/acpi.c.

More information about the freebsd-questions mailing list