Home | History | Annotate | Line # | Download | only in rc.d
raidframe revision 1.7
      1 #!/bin/sh
      2 #
      3 # $NetBSD: raidframe,v 1.7 2002/09/03 15:35:55 abs Exp $
      4 #
      5 
      6 # PROVIDE: disks
      7 
      8 . /etc/rc.subr
      9 
     10 name="raidframe"
     11 start_cmd="raidframe_start"
     12 stop_cmd=":"
     13 
     14 raidframe_start()
     15 {
     16 	# Configure non-auto-configured raid devices.
     17 	# Ensure order by globbing raid[0-9].conf before raid[1-9][0-9].conf.
     18 	#
     19 	for cfg in /etc/raid[0-9].conf /etc/raid[1-9][0-9].conf ; do
     20 		[ ! -f $cfg ] && continue
     21 		dev=${cfg##*/}
     22 		dev=${dev%%.conf}
     23 		raidctl -c $cfg $dev
     24 	done
     25 }
     26 
     27 load_rc_config $name
     28 run_rc_command "$1"
     29