summaryrefslogtreecommitdiffstats
path: root/src/etc/rc.initial.reboot
diff options
context:
space:
mode:
authorjim-p <jimp@pfsense.org>2016-12-29 10:20:02 -0500
committerjim-p <jimp@pfsense.org>2016-12-29 10:20:02 -0500
commita2c453fdadc4e02bbdb77c6803a2667118b70bee (patch)
treee4e97435e391907946fa95fdcde8d9f81e7c8848 /src/etc/rc.initial.reboot
parentb34c29cbd92318c7986b8ee2d02cec23d9d35ce2 (diff)
downloadpfsense-a2c453fdadc4e02bbdb77c6803a2667118b70bee.zip
pfsense-a2c453fdadc4e02bbdb77c6803a2667118b70bee.tar.gz
Add reroot support to system_reboot_sync() and to the /etc/rc.initial.reboot menu. Ticket #6045
Diffstat (limited to 'src/etc/rc.initial.reboot')
-rwxr-xr-xsrc/etc/rc.initial.reboot8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/etc/rc.initial.reboot b/src/etc/rc.initial.reboot
index 0380f7c..87f4739 100755
--- a/src/etc/rc.initial.reboot
+++ b/src/etc/rc.initial.reboot
@@ -35,6 +35,7 @@ $fp = fopen('php://stdin', 'r');
echo "\n" . sprintf(gettext("%s will reboot. This may take a few minutes, depending on your hardware."), $g['product_name']) . "\n";
echo gettext("Do you want to proceed?") . "\n\n";
echo " " . gettext("Y/y: Reboot normally") . "\n";
+echo " " . gettext("R/r: Reroot (Stop processes, remount disks, re-run startup sequence)") . "\n";
echo " " . gettext("S: Reboot into Single User Mode (requires console access!)") . "\n";
echo " " . gettext("F: Reboot and run a filesystem check") . "\n\n";
@@ -51,11 +52,18 @@ switch (chop(fgets($fp))) {
echo "\n" . sprintf(gettext("%s is rebooting for a filesystem check now."), $g['product_name']) . "\n";
system_reboot_sync();
break;
+ case "R":
+ case "r":
+ echo "\n" . sprintf(gettext("%s is rerooting now."), $g['product_name']) . "\n";
+ system_reboot_sync(true);
+ break;
case "Y":
case "y":
echo "\n" . sprintf(gettext("%s is rebooting now."), $g['product_name']) . "\n";
system_reboot_sync();
break;
+ default:
+ break;
}
fclose($fp);
OpenPOWER on IntegriCloud