aboutsummaryrefslogtreecommitdiff
path: root/etc/rc.d/init.d/reboot
diff options
context:
space:
mode:
Diffstat (limited to 'etc/rc.d/init.d/reboot')
-rwxr-xr-xetc/rc.d/init.d/reboot47
1 files changed, 47 insertions, 0 deletions
diff --git a/etc/rc.d/init.d/reboot b/etc/rc.d/init.d/reboot
new file mode 100755
index 00000000..b41b0339
--- /dev/null
+++ b/etc/rc.d/init.d/reboot
@@ -0,0 +1,47 @@
+#!/bin/sh
+########################################################################
+# Begin reboot
+#
+# Description : Reboot Scripts
+#
+# Authors : Gerard Beekmans - [email protected]
+# DJ Lucas - [email protected]
+# Updates : Bruce Dubbs - [email protected]
+# : Pierre Labastie - [email protected]
+#
+# Version : LFS 7.0
+#
+# Notes : Update March 24th, 2022: change "stop" to "start".
+# Add the $last facility to Required-start
+#
+########################################################################
+
+### BEGIN INIT INFO
+# Provides: reboot
+# Required-Start: $last
+# Should-Start:
+# Required-Stop:
+# Should-Stop:
+# Default-Start: 6
+# Default-Stop:
+# Short-Description: Reboots the system.
+# Description: Reboots the System.
+# X-LFS-Provided-By: LFS
+### END INIT INFO
+
+. /lib/lsb/init-functions
+
+case "${1}" in
+ start)
+ log_info_msg "Restarting system..."
+ reboot -d -f -i
+ ;;
+
+ *)
+ echo "Usage: ${0} {start}"
+ exit 1
+ ;;
+
+esac
+
+# End reboot