summaryrefslogtreecommitdiffstats
path: root/usr/local/www/diag_backup.php
diff options
context:
space:
mode:
authorScott Ullrich <sullrich@pfsense.org>2006-04-22 21:13:22 +0000
committerScott Ullrich <sullrich@pfsense.org>2006-04-22 21:13:22 +0000
commite57f259a8bc38c20ff8a2a3fd6db2e257e37bd86 (patch)
treedcfe5976e5d5c6ca572f099dafabd3fb982a862c /usr/local/www/diag_backup.php
parentb249c3bfd19cce72226a28e6980c7428bf07496b (diff)
downloadpfsense-e57f259a8bc38c20ff8a2a3fd6db2e257e37bd86.zip
pfsense-e57f259a8bc38c20ff8a2a3fd6db2e257e37bd86.tar.gz
Reboot after configuration restore.
Diffstat (limited to 'usr/local/www/diag_backup.php')
-rwxr-xr-xusr/local/www/diag_backup.php22
1 files changed, 5 insertions, 17 deletions
diff --git a/usr/local/www/diag_backup.php b/usr/local/www/diag_backup.php
index 0513e0c..3e57c2d 100755
--- a/usr/local/www/diag_backup.php
+++ b/usr/local/www/diag_backup.php
@@ -149,10 +149,9 @@ if ($_POST) {
/* this will be picked up by /index.php */
conf_mount_rw();
touch("/needs_package_sync");
- $reloadall = true;
$reboot_needed = true;
$savemsg = "The configuration has been restored. The firewall is now rebooting.";
- /* remove cache, we will force a config reload */
+ /* remove cache, we will force a config reboot */
if(file_exists("/tmp/config.cache"))
unlink("/tmp/config.cache");
$config = parse_config(true);
@@ -188,10 +187,10 @@ if ($_POST) {
if ($ver2restore <> "") {
$conf_file = "{$g['cf_conf_path']}/bak/config-" . strtotime($ver2restore) . ".xml";
if (config_install($conf_file) == 0) {
- $reloadall = true;
- $savemsg = "The configuration has been restored. The firewall is now rebooting.";
+ $reboot_needed = true;
+ $savemsg = "The configuration has been restored. The firewall is now rebooting.";
} else {
- $input_errors[] = "The configuration could not be restored.";
+ $input_errors[] = "The configuration could not be restored.";
}
} else {
$input_errors[] = "No version selected.";
@@ -255,7 +254,7 @@ include("head.inc");
Open a pfSense configuration XML file and click the button below to restore the configuration. <br /><br /> Restore area: <?php spit_out_select_items("restorearea"); ?>
<p><input name="conffile" type="file" class="formfld" id="conffile" size="40"></p>
<p><input name="Submit" type="submit" class="formbtn" id="restore" value="Restore configuration"></p>
- <p><strong><span class="red">Note:</span></strong><br />The firewall will reload the settings after restoring the configuration.<br /></p>
+ <p><strong><span class="red">Note:</span></strong><br />The firewall will reboot after restoring the configuration.<br /></p>
</td>
</tr>
<?php if($config['installedpackages']['package'] != "") { ?>
@@ -291,15 +290,4 @@ if($reboot_needed == true) {
exit;
}
-if($reloadall == true) {
-
- if(file_exists("{$g['tmp_path']}/config.cache"))
- unlink("{$g['tmp_path']}/config.cache");
-
- parse_config();
-
- reload_all();
-
-}
-
?> \ No newline at end of file
OpenPOWER on IntegriCloud