summaryrefslogtreecommitdiffstats
path: root/etc/rc.shutdown
diff options
context:
space:
mode:
authordougb <dougb@FreeBSD.org>2005-12-02 20:06:07 +0000
committerdougb <dougb@FreeBSD.org>2005-12-02 20:06:07 +0000
commit997405c1cadb59927aff9fe3f831061a3a60fcae (patch)
tree51bcd0baa3852d62ab93efd232c48f0a2015ed8a /etc/rc.shutdown
parentf88100d008c54fc484c3dc2634b2079c11aea469 (diff)
downloadFreeBSD-src-997405c1cadb59927aff9fe3f831061a3a60fcae.zip
FreeBSD-src-997405c1cadb59927aff9fe3f831061a3a60fcae.tar.gz
Introduce startup scripts from the local_startup directories to
the base rcorder. This is accomplished by running rcorder twice, first to get all the disks mounted (through mountcritremote), then again to include the local_startup directories. This dramatically changes the behavior of rc.d/localpkg, as all "local" scripts that have the new rc.d semantics are now run in the base rcorder, so only scripts that have not been converted yet will run in rc.d/localpkg. Make a similar change in rc.shutdown, and add some functions in rc.subr to support these changes. Bump __FreeBSD_version to reflect this change.
Diffstat (limited to 'etc/rc.shutdown')
-rw-r--r--etc/rc.shutdown8
1 files changed, 7 insertions, 1 deletions
diff --git a/etc/rc.shutdown b/etc/rc.shutdown
index 075881f..ebe79d7 100644
--- a/etc/rc.shutdown
+++ b/etc/rc.shutdown
@@ -82,7 +82,13 @@ fi
#
rcorder_opts="-k shutdown"
[ `/sbin/sysctl -n security.jail.jailed` -eq 1 ] && rcorder_opts="$rcorder_opts -s nojail"
-files=`rcorder ${rcorder_opts} /etc/rc.d/* 2>/dev/null`
+
+case ${local_startup} in
+[Nn][Oo] | '') ;;
+*) find_local_scripts_new ;;
+esac
+
+files=`rcorder ${rcorder_opts} /etc/rc.d/* ${local_rc} 2>/dev/null`
for _rc_elem in `reverse_list $files`; do
debug "run_rc_script $_rc_elem faststop"
OpenPOWER on IntegriCloud