summary refs log tree commit diff
path: root/etc/freebsd/3
diff options
context:
space:
mode:
Diffstat (limited to 'etc/freebsd/3')
-rwxr-xr-xetc/freebsd/319
1 files changed, 19 insertions, 0 deletions
diff --git a/etc/freebsd/3 b/etc/freebsd/3
new file mode 100755
index 0000000..065cd30
--- /dev/null
+++ b/etc/freebsd/3
@@ -0,0 +1,19 @@
+#!/bin/sh
+
+echo 'Stopping services...'
+/command/svc -d /service/*
+/command/svwaitdown -t350 /service/* || \
+  ( echo 'Killing services...' ; /command/svc -k /service/* )
+
+echo 'Stopping log services...'
+/command/svc -d /service/*/log
+/command/svwaitdown -t35 /service/*/log
+
+echo 'Shutdown...'
+if test -r /etc/runit/reboot; then
+  /sbin/reboot
+else
+  /sbin/halt
+fi
+
+exit 0