diff --git a/lib/disk.pm b/lib/disk.pm
index 97fd727..6c308db 100644
--- a/lib/disk.pm
+++ b/lib/disk.pm
@@ -160,12 +160,12 @@ sub disk_init {
}
# check dependencies
- if(lc($disk->{alerts}->{realloc_enabled}) eq "y") {
+ if(lc($disk->{alerts}->{realloc_enabled} || "") eq "y") {
if(! -x $disk->{alerts}->{realloc_script}) {
logger("$myself: ERROR: script '$disk->{alerts}->{realloc_script}' doesn't exist or don't has execution permissions.");
}
}
- if(lc($disk->{alerts}->{pendsect_enabled}) eq "y") {
+ if(lc($disk->{alerts}->{pendsect_enabled} || "") eq "y") {
if(! -x $disk->{alerts}->{pendsect_script}) {
logger("$myself: ERROR: script '$disk->{alerts}->{pendsect_script}' doesn't exist or don't has execution permissions.");
}
diff --git a/lib/system.pm b/lib/system.pm
index eab0180..28dbed9 100644
--- a/lib/system.pm
+++ b/lib/system.pm
@@ -122,7 +122,7 @@ sub system_init {
}
# check dependencies
- if(lc($system->{alerts}->{loadavg_enabled}) eq "y") {
+ if(lc($system->{alerts}->{loadavg_enabled} | "") eq "y") {
if(! -x $system->{alerts}->{loadavg_script}) {
logger("$myself: ERROR: script '$system->{alerts}->{loadavg_script}' doesn't exist or don't has execution permissions.");
}
diff --git a/monitorix b/monitorix
index 5f219da..9ca09f6 100755
--- a/monitorix
+++ b/monitorix
@@ -147,7 +147,7 @@ sub create_index {
}
# Piwik tracking code
- if(lc($config{piwik_tracking}->{enabled}) eq "y") {
+ if(lc($config{piwik_tracking}->{enabled} || "") eq "y") {
$piwik_url = $config{piwik_tracking}->{url} || "";
$piwik_sid = $config{piwik_tracking}->{sid} || "";
$piwik_img = $config{piwik_tracking}->{img} || "";
@@ -230,7 +230,7 @@ EOF
print(OUT " \n");
print(OUT " \n");
- if(scalar(my @remotehost_list = split(',', $config{multihost}->{remotehost_list})) && lc($config{multihost}->{enabled}) eq "y") {
+ if(scalar(my @remotehost_list = split(',', $config{multihost}->{remotehost_list})) && lc($config{multihost}->{enabled} || "") eq "y") {
print(OUT "