#!/bin/sh # Use metastate (qv) to report on the health of our metadevices. # The only complication is discovering what metasets are in use on the # current system. PATH=/u/cks/sys/metacrunch:/usr/sbin:$PATH; export PATH if [ ! -x /usr/sbin/metastat ]; then exit 0 fi if mount | fgrep ' on /dev/md/' >/dev/null 2>&1; then : else # No metadevices exit 0 fi # I will assume (for now) that we have no machines without unnamed # metasets. So, first report on the root set: metastate # Discover other metaset(s) sets=`metawhatsets` if [ -n "$sets" ]; then for s in $sets; do metastate $s; done fi