diff options
author | Ermal LUÇI <eri@pfsense.org> | 2014-11-27 08:41:48 +0100 |
---|---|---|
committer | Ermal LUÇI <eri@pfsense.org> | 2014-11-27 08:41:48 +0100 |
commit | e546d2d1aa5d7bade9ce801fec75f11bf684c6ae (patch) | |
tree | 747ee9d0591f564eec9b75587af2ec2b79236d6d | |
parent | 080036611277f714b6ee2e7faf6b58a4393f41b1 (diff) | |
download | pfsense-e546d2d1aa5d7bade9ce801fec75f11bf684c6ae.zip pfsense-e546d2d1aa5d7bade9ce801fec75f11bf684c6ae.tar.gz |
Do not run this code during upgrade and if ost is booting up
-rw-r--r-- | etc/inc/upgrade_config.inc | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/etc/inc/upgrade_config.inc b/etc/inc/upgrade_config.inc index 19e4363..5848424 100644 --- a/etc/inc/upgrade_config.inc +++ b/etc/inc/upgrade_config.inc @@ -2106,7 +2106,8 @@ function upgrade_054_to_055() { mwexec("$rrdtool resize {$rrddbpath}/{$database} 3 GROW 2000;/bin/mv resize.rrd {$rrddbpath}/{$database} 2>&1"); unset($rrdxmlarray); } - enable_rrd_graphing(); + if (!platform_booting()) + enable_rrd_graphing(); /* Let's save the RRD graphs after we run enable RRD graphing */ /* The function will restore the rrd.tgz so we will save it after */ exec("cd /; LANG=C NO_REMOUNT=1 RRDDBPATH='{$rrddbpath}' CF_CONF_PATH='{$g['cf_conf_path']}' /etc/rc.backup_rrd.sh"); @@ -2792,7 +2793,8 @@ function upgrade_080_to_081() { unlink_if_exists("{$g['tmp_path']}/{$xmldump}"); unlink_if_exists("{$g['tmp_path']}/{$xmldumpnew}"); } - enable_rrd_graphing(); + if (!platform_booting()) + enable_rrd_graphing(); /* Let's save the RRD graphs after we run enable RRD graphing */ /* The function will restore the rrd.tgz so we will save it after */ exec("cd /; LANG=C NO_REMOUNT=1 RRDDBPATH='{$rrddbpath}' CF_CONF_PATH='{$g['cf_conf_path']}' /etc/rc.backup_rrd.sh"); @@ -3071,7 +3073,8 @@ function upgrade_092_to_093() { rename("{$g['vardb_path']}/rrd/captiveportal-{$suffix}.rrd", "{$g['vardb_path']}/rrd/captiveportal-cpZone-{$suffix}.rrd"); - enable_rrd_graphing(); + if (!platform_booting()) + enable_rrd_graphing(); } function upgrade_093_to_094() { @@ -3128,7 +3131,8 @@ function upgrade_095_to_096() { mwexec("{$cmd} 2>&1"); } - enable_rrd_graphing(); + if (!platform_booting()) + enable_rrd_graphing(); /* Let's save the RRD graphs after we run enable RRD graphing */ /* The function will restore the rrd.tgz so we will save it after */ exec("cd /; LANG=C NO_REMOUNT=1 RRDDBPATH='{$rrddbpath}' CF_CONF_PATH='{$g['cf_conf_path']}' /etc/rc.backup_rrd.sh"); |