Index: etc/conf.d/rc =================================================================== --- etc/conf.d/rc (revision 2021) +++ etc/conf.d/rc (working copy) @@ -10,17 +10,21 @@ RC_PARALLEL_STARTUP="no" -# Dynamic /dev managers can trigger coldplug events which cause services to -# start before we are ready for them. If this happens, we can defer these -# services to start in the boot runlevel. If you don't want this then set -# RC_COLDPLUG to no. -# For more fine grained control you can list full service names to allow -# them to coldplug and prefix them with ! so they don't coldplug. -# Example - RC_COLDPLUG="net.wlan !net.*" -# This allows net.wlan and any service not matching net.* to coldplug. +# Do we allow services to be hotplugged? If not, set to RC_HOTPLUG="no" +# NOTE: This does not affect anything hotplug/udev related, just the +# starting/stopping of the init.d service triggered by hotplug. RC_COLDPLUG="yes" +# Some people want a finer grain over hotplug/coldplug. RC_PLUG_SERVICES is a +# list of services that are matched in order, either allowing or not. By +# default we allow services through as RC_COLDPLUG has to be yes +# anyway. +# Example - RC_PLUG_SERVICES="net.wlan !net.*" +# This allows net.wlan and any service not matching net.* to be plugged. + +RC_PLUG_SERVICES="" + # RC_NET_STRICT_CHECKING allows some flexibility with the 'net' service. # The following values are allowed: # none - The 'net' service is always considered up. Index: sbin/runscript.sh =================================================================== --- sbin/runscript.sh (revision 2021) +++ sbin/runscript.sh (working copy) @@ -34,14 +34,12 @@ # until after rc sysinit has completed so we punt them to the boot runlevel if [[ -e /dev/.rcsysinit ]] ; then eerror "ERROR: cannot run ${SVCNAME} until sysinit completes" - [[ ${RC_COLDPLUG} == "no" ]] && exit 1 - if [[ ${RC_COLDPLUG} != "yes" ]] ; then - for x in ${RC_COLDPLUG} ; do - # We don't quote ${x} so we can do globbing - [[ ${SVCNAME} == ${x} ]] && break - [[ "!${SVCNAME}" == ${x} ]] && exit 1 - done - fi + [[ ${RC_COLDPLUG:-yes} != "yes" ]] && exit 1 + set -f + for x in ${RC_PLUG_SERVICES} ; do + [[ ${SVCNAME} == ${x} ]] && break + [[ "!${SVCNAME}" == ${x} ]] && exit 1 + done eerror "${SVCNAME} will be started in the ${BOOTLEVEL} runlevel" if [[ ! -L /dev/.rcboot/"${SVCNAME}" ]] ; then [[ ! -d /dev/.rcboot ]] && mkdir /dev/.rcboot