blob: af93fc8a28db5cfac4fbc65e36d6af098cc1c58d (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
|
#!/bin/sh
#
# $NetBSD: raidframe,v 1.4 2000/05/16 16:54:33 oster Exp $
#
# PROVIDE: disks
. /etc/rc.subr
name="raidframe"
start_cmd="raidframe_start"
stop_cmd=":"
raidframe_start()
{
# Configure raid devices.
#
for dev in 0 1 2 3; do
if [ -f /etc/raid$dev.conf ]; then
raidctl -c /etc/raid$dev.conf raid$dev
fi
done
# Initiate parity/mirror reconstruction as needed.
# Backgrounded, and sequentially ordered.
#
(
for dev in 0 1 2 3; do
if [ -f /etc/raid$dev.conf ]; then
raidctl -P raid$dev
fi
done
) &
}
load_rc_config $name
run_rc_command "$1"
|