From 950531bbcac1b3bd273bdcaaf6e26270cf176277 Mon Sep 17 00:00:00 2001 From: Hirofumi Kosaka Date: Thu, 5 Nov 2015 20:17:21 +0900 Subject: [PATCH] Fixed pandora_db.pl had failed to get $conf->{'errorlogfile'} from pandora_server.conf. (because of name unconsistency between conf's entry and $conf's hash key) It had caused following error; 'Use of uninitialized value in concatenation (.) or string at /usr/lib/perl5/PandoraFMS/Tools.pm line 595.' --- pandora_server/util/pandora_db.pl | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/pandora_server/util/pandora_db.pl b/pandora_server/util/pandora_db.pl index 27b19b0e90..8aeaa6d429 100644 --- a/pandora_server/util/pandora_db.pl +++ b/pandora_server/util/pandora_db.pl @@ -638,6 +638,10 @@ sub pandora_load_config ($) { $conf->{'dbport'} = '3306' unless defined ($conf->{'dbport'}); $conf->{'claim_back_snmp_modules'} = '1' unless defined ($conf->{'claim_back_snmp_modules'}); + // workaround for name unconsistency (corresponding entry at pandora_server.conf is 'errorlog_file') + $conf->{'errorlogfile'} = $conf->{'errorlog_file'}; + $conf->{'errorlogfile'} = "/var/log/pandora_server.error" unless defined ($conf->{'errorlogfile'}); + # Read additional tokens from the DB my $dbh = db_connect ($conf->{'dbengine'}, $conf->{'dbname'}, $conf->{'dbhost'}, $conf->{'dbport'}, $conf->{'dbuser'}, $conf->{'dbpass'});