EFA-Config not being read in MailWatchConf.pm??
Posted: 27 Apr 2017 20:04
Did an update on EFA today and now getting the following errors:
Apr 27 15:07:05 relay-4 MailScanner[1993]: Could not use Custom Function code MailScanner::CustomConfig::InitSQLBlacklist, it could not be "eval"ed. Make sure the module is correct with perl -wc (Error: DBI connect('database=mailscanner;host=localhost','mailwatch',...) failed: Access denied for user 'mailwatch'@'localhost' (using password: NO) at /usr/share/MailScanner/perl/custom/SQLSpamSettings.pm line 73
Apr 27 15:07:05 relay-4 MailScanner[1993]: )
Apr 27 15:07:05 relay-4 MailScanner[1993]: Config: calling custom init function MailWatchLogging
Apr 27 15:07:05 relay-4 MailScanner[2041]: Could not use Custom Function code MailScanner::CustomConfig::InitMailWatchLogging, it could not be "eval"ed. Make sure the module is correct with perl -wc (Error: DBI connect('database=mailscanner;host=localhost','mailwatch',...) failed: Access denied for user 'mailwatch'@'localhost' (using password: NO) at /usr/share/MailScanner/perl/custom/SQLSpamSettings.pm line 73
Apr 27 15:07:05 relay-4 MailScanner[2041]: )
Apr 27 15:07:05 relay-4 MailScanner[2041]: Config: calling custom init function SQLWhitelist
Apr 27 15:07:05 relay-4 MailScanner[2041]: MailWatch: Starting up MailWatch SQL Whitelist
Apr 27 15:07:05 relay-4 MailScanner[2041]: Could not use Custom Function code MailScanner::CustomConfig::InitSQLWhitelist, it could not be "eval"ed. Make sure the module is correct with perl -wc (Error: DBI connect('database=mailscanner;host=localhost','mailwatch',...) failed: Access denied for user 'mailwatch'@'localhost' (using password: NO) at /usr/share/MailScanner/perl/custom/SQLSpamSettings.pm line 73
Apr 27 15:07:05 relay-4 MailScanner[2041]:
It seems it is not reading this portion of MailWatchConf.pm:
my ($db_name) = 'mailscanner';
my ($db_host) = 'localhost';
my ($db_user) = 'mailwatch';
my ($fh);
my ($pw_config) = '/etc/EFA-Config';
open($fh, "<", $pw_config);
if(!$fh) {
MailScanner::Log::WarnLog("Unable to open %s to retrieve password", $pw_config);
return;
Apr 27 15:07:05 relay-4 MailScanner[1993]: Could not use Custom Function code MailScanner::CustomConfig::InitSQLBlacklist, it could not be "eval"ed. Make sure the module is correct with perl -wc (Error: DBI connect('database=mailscanner;host=localhost','mailwatch',...) failed: Access denied for user 'mailwatch'@'localhost' (using password: NO) at /usr/share/MailScanner/perl/custom/SQLSpamSettings.pm line 73
Apr 27 15:07:05 relay-4 MailScanner[1993]: )
Apr 27 15:07:05 relay-4 MailScanner[1993]: Config: calling custom init function MailWatchLogging
Apr 27 15:07:05 relay-4 MailScanner[2041]: Could not use Custom Function code MailScanner::CustomConfig::InitMailWatchLogging, it could not be "eval"ed. Make sure the module is correct with perl -wc (Error: DBI connect('database=mailscanner;host=localhost','mailwatch',...) failed: Access denied for user 'mailwatch'@'localhost' (using password: NO) at /usr/share/MailScanner/perl/custom/SQLSpamSettings.pm line 73
Apr 27 15:07:05 relay-4 MailScanner[2041]: )
Apr 27 15:07:05 relay-4 MailScanner[2041]: Config: calling custom init function SQLWhitelist
Apr 27 15:07:05 relay-4 MailScanner[2041]: MailWatch: Starting up MailWatch SQL Whitelist
Apr 27 15:07:05 relay-4 MailScanner[2041]: Could not use Custom Function code MailScanner::CustomConfig::InitSQLWhitelist, it could not be "eval"ed. Make sure the module is correct with perl -wc (Error: DBI connect('database=mailscanner;host=localhost','mailwatch',...) failed: Access denied for user 'mailwatch'@'localhost' (using password: NO) at /usr/share/MailScanner/perl/custom/SQLSpamSettings.pm line 73
Apr 27 15:07:05 relay-4 MailScanner[2041]:
It seems it is not reading this portion of MailWatchConf.pm:
my ($db_name) = 'mailscanner';
my ($db_host) = 'localhost';
my ($db_user) = 'mailwatch';
my ($fh);
my ($pw_config) = '/etc/EFA-Config';
open($fh, "<", $pw_config);
if(!$fh) {
MailScanner::Log::WarnLog("Unable to open %s to retrieve password", $pw_config);
return;