mdconfig2 (208060) | mdconfig2 (264243) |
---|---|
1#!/bin/sh 2# 3# Copyright (c) 2006 The FreeBSD Project 4# All rights reserved. 5# 6# Redistribution and use in source and binary forms, with or without 7# modification, are permitted provided that the following conditions 8# are met: --- 10 unchanged lines hidden (view full) --- 19# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 20# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 21# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 22# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 23# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 24# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 25# SUCH DAMAGE. 26# | 1#!/bin/sh 2# 3# Copyright (c) 2006 The FreeBSD Project 4# All rights reserved. 5# 6# Redistribution and use in source and binary forms, with or without 7# modification, are permitted provided that the following conditions 8# are met: --- 10 unchanged lines hidden (view full) --- 19# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 20# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 21# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 22# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 23# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 24# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 25# SUCH DAMAGE. 26# |
27# $FreeBSD: head/etc/rc.d/mdconfig2 208060 2010-05-14 04:53:57Z dougb $ | 27# $FreeBSD: head/etc/rc.d/mdconfig2 264243 2014-04-07 22:40:29Z dteske $ |
28# 29 30# PROVIDE: mdconfig2 31# REQUIRE: mountcritremote 32# BEFORE: SERVERS 33 34. /etc/rc.subr 35 --- 170 unchanged lines hidden (view full) --- 206_mdconfig2_cmd="$1" 207if [ $# -gt 0 ]; then 208 shift 209fi 210[ -n "$*" ] && _mdconfig2_list="$*" 211 212load_rc_config $name 213 | 28# 29 30# PROVIDE: mdconfig2 31# REQUIRE: mountcritremote 32# BEFORE: SERVERS 33 34. /etc/rc.subr 35 --- 170 unchanged lines hidden (view full) --- 206_mdconfig2_cmd="$1" 207if [ $# -gt 0 ]; then 208 shift 209fi 210[ -n "$*" ] && _mdconfig2_list="$*" 211 212load_rc_config $name 213 |
214_mdconfig2_unit=0 | |
215if [ -z "${_mdconfig2_list}" ]; then | 214if [ -z "${_mdconfig2_list}" ]; then |
216 while :; do 217 eval _mdconfig2_config=\$mdconfig_md${_mdconfig2_unit} 218 if [ -z "${_mdconfig2_config}" ]; then 219 break 220 else 221 _mdconfig2_list="${_mdconfig2_list}${_mdconfig2_list:+ }md${_mdconfig2_unit}" 222 _mdconfig2_unit=$((${_mdconfig2_unit} + 1)) 223 fi | 215 for _mdconfig2_config in `list_vars mdconfig_md[0-9]\* | 216 sort_lite -nk1.12` 217 do 218 _mdconfig2_unit=${_mdconfig2_config#mdconfig_md} 219 _mdconfig2_list="$_mdconfig2_list md$_mdconfig2_unit" |
224 done | 220 done |
221 _mdconfig2_list="${_mdconfig2_list# }" |
|
225fi 226 227run_rc_command "${_mdconfig2_cmd}" | 222fi 223 224run_rc_command "${_mdconfig2_cmd}" |