aboutsummaryrefslogtreecommitdiffstats
path: root/packages
diff options
context:
space:
mode:
authorScott Ullrich <sullrich@pfsense.org>2008-11-07 22:37:16 +0000
committerScott Ullrich <sullrich@pfsense.org>2008-11-07 22:37:16 +0000
commitcc1231e34c4adf8556cdec013935e8b30bc95919 (patch)
tree9d6a6be82c0e1e9ac5ad93d86949bc8398479a42 /packages
parent9b2f9d8e37a96c6fe06a5b33ba5ac1b9d66e8786 (diff)
downloadpfsense-packages-cc1231e34c4adf8556cdec013935e8b30bc95919.tar.gz
pfsense-packages-cc1231e34c4adf8556cdec013935e8b30bc95919.tar.bz2
pfsense-packages-cc1231e34c4adf8556cdec013935e8b30bc95919.zip
Add some debugging log_error() this package is hanging on installation
on 1.2.1 and 2.0.
Diffstat (limited to 'packages')
-rw-r--r--packages/spamd.inc13
1 files changed, 13 insertions, 0 deletions
diff --git a/packages/spamd.inc b/packages/spamd.inc
index 2b1b163d..99809083 100644
--- a/packages/spamd.inc
+++ b/packages/spamd.inc
@@ -54,6 +54,7 @@ function sync_package_spamd() {
fwrite($fd, "\t:msg=\"Sorry, you spammed us before.\":\\\n");
fwrite($fd, "\t:method=file:\\\n");
fwrite($fd, "\t:file=/var/db/blacklist.txt:\n\n");
+ log_error("Looping through each item and write out its configuration");
/* loop through each item and write out its configuration */
if($config['installedpackages']['spamdsources']['config'] != "") {
foreach($config['installedpackages']['spamdsources']['config'] as $spamd) {
@@ -72,6 +73,7 @@ function sync_package_spamd() {
}
}
fclose($fd);
+ log_error("Creating /var/db/whitelist.txt");
$fd = fopen("/var/db/whitelist.txt","w");
if($config['installedpackages']['spamdwhitelist']['config'] != "") {
foreach($config['installedpackages']['spamdwhitelist']['config'] as $spamd) {
@@ -88,6 +90,7 @@ function sync_package_spamd() {
$maxblack = "";
$stuttersecs = "";
$delaysecs = "";
+ log_error("Looping through spamdsettings");
if($config['installedpackages']['spamdsettings']['config']) {
foreach($config['installedpackages']['spamdsettings']['config'] as $ss) {
if($ss['nextmta'] <> "")
@@ -128,21 +131,31 @@ function sync_package_spamd() {
"/usr/bin/killall spamd\n" .
"/usr/bin/killall pflogd\n" .
"sleep 2";
+ log_error("Writing rc_file");
write_rcfile(array(
"file" => "spamd.sh",
"start" => $start,
"stop" => $stop
)
);
+ log_error("Installing CRON");
spamd_install_cron(true);
+ log_error("Mounting RO");
conf_mount_ro();
+ log_error("Unlocking config");
config_unlock();
+ log_error("Restart cron");
mwexec("killall -HUP cron");
+ log_error("Setting up spamd.conf symlink");
mwexec("ln -s /etc/spamd.conf /usr/local/etc/spamd/spamd.conf");
+ log_error("Stopping spamd");
mwexec("/usr/local/etc/rc.d/spamd.sh stop");
sleep(1);
+ log_error("Starting spamd");
mwexec("/usr/local/etc/rc.d/spamd.sh start");
+ log_error("Reconfiguring filter");
filter_configure();
+ log_error("SpamD setup completed");
}
function remove_spaces($string) {