aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjim-p <jimp@pfsense.org>2014-11-06 08:13:59 -0500
committerjim-p <jimp@pfsense.org>2014-11-06 08:13:59 -0500
commit86a5ead2aa506d5ff67a1f7727be367d12dbbb92 (patch)
tree8b8f40ed65ac44893cad87b16201004bddb7d34e
parent8fcc2a00607cf9e2f86b5bd109d98be1fd463b05 (diff)
parent4f282a597ab24f0fbc6abc6dab2e8b9386f7811b (diff)
downloadpfsense-packages-86a5ead2aa506d5ff67a1f7727be367d12dbbb92.tar.gz
pfsense-packages-86a5ead2aa506d5ff67a1f7727be367d12dbbb92.tar.bz2
pfsense-packages-86a5ead2aa506d5ff67a1f7727be367d12dbbb92.zip
Merge pull request #724 from phil-davis/patch-1
-rw-r--r--config/squid3/31/swapstate_check.php4
-rw-r--r--config/squid3/33/swapstate_check.php4
-rw-r--r--pkg_config.10.xml4
-rw-r--r--pkg_config.8.xml4
-rw-r--r--pkg_config.8.xml.amd644
5 files changed, 12 insertions, 8 deletions
diff --git a/config/squid3/31/swapstate_check.php b/config/squid3/31/swapstate_check.php
index 6ecfff3c..52a6c66c 100644
--- a/config/squid3/31/swapstate_check.php
+++ b/config/squid3/31/swapstate_check.php
@@ -41,6 +41,8 @@ else
if ($settings['harddisk_cache_system'] != "null"){
$cachedir =($settings['harddisk_cache_location'] ? $settings['harddisk_cache_location'] : '/var/squid/cache');
$swapstate = $cachedir . '/swap.state';
+ if (!file_exists($swapstate))
+ return;
$disktotal = disk_total_space(dirname($cachedir));
$diskfree = disk_free_space(dirname($cachedir));
$diskusedpct = round((($disktotal - $diskfree) / $disktotal) * 100);
@@ -55,4 +57,4 @@ if ($settings['harddisk_cache_system'] != "null"){
log_error(gettext(sprintf("Squid swap.state file exceeded size limits. Removing and rotating. File was %d bytes, %d%% of total disk space.", $swapstate_size, $swapstate_pct)));
}
}
-?> \ No newline at end of file
+?>
diff --git a/config/squid3/33/swapstate_check.php b/config/squid3/33/swapstate_check.php
index a0b3c98b..616b8fd9 100644
--- a/config/squid3/33/swapstate_check.php
+++ b/config/squid3/33/swapstate_check.php
@@ -42,6 +42,8 @@ else
if ($settings['harddisk_cache_system'] != "null"){
$cachedir =($settings['harddisk_cache_location'] ? $settings['harddisk_cache_location'] : '/var/squid/cache');
$swapstate = $cachedir . '/swap.state';
+ if (!file_exists($swapstate))
+ return;
$disktotal = disk_total_space(dirname($cachedir));
$diskfree = disk_free_space(dirname($cachedir));
$diskusedpct = round((($disktotal - $diskfree) / $disktotal) * 100);
@@ -55,4 +57,4 @@ if ($settings['harddisk_cache_system'] != "null"){
log_error(gettext(sprintf("Squid cache and/or swap.state exceeded size limits. Removing and rotating. File was %d bytes, %d%% of total disk space.", $swapstate_size, $swapstate_pct)));
}
}
-?> \ No newline at end of file
+?>
diff --git a/pkg_config.10.xml b/pkg_config.10.xml
index 1c31cc2d..95338abd 100644
--- a/pkg_config.10.xml
+++ b/pkg_config.10.xml
@@ -901,7 +901,7 @@
<pkginfolink>https://forum.pfsense.org/index.php/topic,48347.0.html</pkginfolink>
<website>http://www.squid-cache.org/</website>
<category>Network</category>
- <version>3.1.20 pkg 2.1.1</version>
+ <version>3.1.20 pkg 2.1.2</version>
<status>beta</status>
<required_version>2.2</required_version>
<maintainer>marcellocoutinho@gmail.com fernando@netfilter.com.br seth.mos@dds.nl mfuchs77@googlemail.com jimp@pfsense.org</maintainer>
@@ -925,7 +925,7 @@
<pkginfolink>https://forum.pfsense.org/index.php/topic,48347.0.html</pkginfolink>
<website>http://www.squid-cache.org/</website>
<category>Network</category>
- <version>3.3.11_1 pkg 2.2.7</version>
+ <version>3.3.11_1 pkg 2.2.8</version>
<status>beta</status>
<required_version>2.2</required_version>
<maintainer>marcellocoutinho@gmail.com fernando@netfilter.com.br seth.mos@dds.nl mfuchs77@googlemail.com jimp@pfsense.org</maintainer>
diff --git a/pkg_config.8.xml b/pkg_config.8.xml
index 23d0a56e..8d7bcd94 100644
--- a/pkg_config.8.xml
+++ b/pkg_config.8.xml
@@ -1157,7 +1157,7 @@
<pkginfolink>https://forum.pfsense.org/index.php/topic,48347.0.html</pkginfolink>
<website>http://www.squid-cache.org/</website>
<category>Network</category>
- <version>3.1.20 pkg 2.1.1</version>
+ <version>3.1.20 pkg 2.1.2</version>
<status>beta</status>
<required_version>2.0</required_version>
<maintainer>marcellocoutinho@gmail.com fernando@netfilter.com.br seth.mos@dds.nl mfuchs77@googlemail.com jimp@pfsense.org</maintainer>
@@ -1184,7 +1184,7 @@
<pkginfolink>https://forum.pfsense.org/index.php/topic,48347.0.html</pkginfolink>
<website>http://www.squid-cache.org/</website>
<category>Network</category>
- <version>3.3.10 pkg 2.2.6</version>
+ <version>3.3.10 pkg 2.2.8</version>
<status>beta</status>
<required_version>2.0</required_version>
<maintainer>marcellocoutinho@gmail.com fernando@netfilter.com.br seth.mos@dds.nl mfuchs77@googlemail.com jimp@pfsense.org</maintainer>
diff --git a/pkg_config.8.xml.amd64 b/pkg_config.8.xml.amd64
index 0d51754d..88792d6a 100644
--- a/pkg_config.8.xml.amd64
+++ b/pkg_config.8.xml.amd64
@@ -1144,7 +1144,7 @@
<pkginfolink>https://forum.pfsense.org/index.php/topic,48347.0.html</pkginfolink>
<website>http://www.squid-cache.org/</website>
<category>Network</category>
- <version>3.1.20 pkg 2.1.1</version>
+ <version>3.1.20 pkg 2.1.2</version>
<status>beta</status>
<required_version>2.0</required_version>
<maintainer>marcellocoutinho@gmail.com fernando@netfilter.com.br seth.mos@dds.nl mfuchs77@googlemail.com jimp@pfsense.org</maintainer>
@@ -1171,7 +1171,7 @@
<pkginfolink>https://forum.pfsense.org/index.php/topic,48347.0.html</pkginfolink>
<website>http://www.squid-cache.org/</website>
<category>Network</category>
- <version>3.3.10 pkg 2.2.6</version>
+ <version>3.3.10 pkg 2.2.8</version>
<status>beta</status>
<required_version>2.0</required_version>
<maintainer>marcellocoutinho@gmail.com fernando@netfilter.com.br seth.mos@dds.nl mfuchs77@googlemail.com jimp@pfsense.org</maintainer>