PHP Fatal error / Postfix crash

Bugs in eFa 4
Post Reply
pingu
Posts: 12
Joined: 10 Dec 2020 08:07

PHP Fatal error / Postfix crash

Post by pingu »

Hello,

I've been running into a strange issue in the last couple of weeks.
one of my Efa boxes seems to be crashing at random times, below is a snippet of the logs at the moment of services crashing:
Jan 25 10:16:08 sc01 rsyslogd[3077938]: imjournal: 4565 messages lost due to rate-limiting (20000 allowed within 600 seconds)
Jan 25 10:16:53 sc01 php[2762007]: PHP Fatal error: Uncaught mysqli_sql_exception: Truncated incorrect DECIMAL value: '' in /var/www/html/mailscanner/functions.php:1054#012Stack trace:#012#0 /var/www/html/mailscanner/functions.php(1054): mysqli->query('REPLACE INTO mt...')#012#1 /var/www/html/mailscanner/mtalogprocessor.inc.php(135): dbquery('REPLACE INTO mt...')#012#2 /var/www/html/mailscanner/mtalogprocessor.inc.php(179): MtaLogProcessor->processLine('Jan 23 13:12:05...')#012#3 /usr/bin/mailwatch/tools/Postfix_relay/mailwatch_postfix_relay.php(97): MtaLogProcessor->doit('cat /var/log/ma...')#012#4 {main}#012 thrown in /var/www/html/mailscanner/functions.php on line 1054
Jan 25 10:16:53 sc01 php[2762007]: Fatal error: Uncaught mysqli_sql_exception: Truncated incorrect DECIMAL value: '' in /var/www/html/mailscanner/functions.php:1054
Jan 25 10:16:53 sc01 php[2762007]: Stack trace:
Jan 25 10:16:53 sc01 php[2762007]: #0 /var/www/html/mailscanner/functions.php(1054): mysqli->query('REPLACE INTO mt...')
Jan 25 10:16:53 sc01 php[2762007]: #1 /var/www/html/mailscanner/mtalogprocessor.inc.php(135): dbquery('REPLACE INTO mt...')
Jan 25 10:16:53 sc01 php[2762007]: #2 /var/www/html/mailscanner/mtalogprocessor.inc.php(179): MtaLogProcessor->processLine('Jan 23 13:12:05...')
Jan 25 10:16:53 sc01 php[2762007]: #3 /usr/bin/mailwatch/tools/Postfix_relay/mailwatch_postfix_relay.php(97): MtaLogProcessor->doit('cat /var/log/ma...')
Jan 25 10:16:53 sc01 php[2762007]: #4 {main}
Jan 25 10:16:53 sc01 php[2762007]: thrown in /var/www/html/mailscanner/functions.php on line 1054
Jan 25 10:16:53 sc01 php[2762007]: cat: write error: Broken pipe
Jan 25 10:16:53 sc01 systemd[1]: postfix_relay.service: Main process exited, code=exited, status=255/n/a
Jan 25 10:16:53 sc01 systemd[1]: postfix_relay.service: Failed with result 'exit-code'.
Jan 25 10:16:53 sc01 systemd[1]: postfix_relay.service: Service RestartSec=100ms expired, scheduling restart.
Jan 25 10:16:53 sc01 systemd[1]: postfix_relay.service: Scheduled restart job, restart counter is at 63957.
Jan 25 10:16:53 sc01 systemd[1]: Stopped Postfix relay service for MailWatch.
Jan 25 10:16:53 sc01 systemd[1]: Started Postfix relay service for MailWatch.
Jan 25 10:18:47 sc01 php[2764394]: PHP Fatal error: Uncaught mysqli_sql_exception: Truncated incorrect DECIMAL value: '' in /var/www/html/mailscanner/functions.php:1054#012Stack trace:#012#0 /var/www/html/mailscanner/functions.php(1054): mysqli->query('REPLACE INTO mt...')#012#1 /var/www/html/mailscanner/mtalogprocessor.inc.php(135): dbquery('REPLACE INTO mt...')#012#2 /var/www/html/mailscanner/mtalogprocessor.inc.php(179): MtaLogProcessor->processLine('Jan 23 13:12:05...')#012#3 /usr/bin/mailwatch/tools/Postfix_relay/mailwatch_postfix_relay.php(97): MtaLogProcessor->doit('cat /var/log/ma...')#012#4 {main}#012 thrown in /var/www/html/mailscanner/functions.php on line 1054
Jan 25 10:18:47 sc01 php[2764394]: Fatal error: Uncaught mysqli_sql_exception: Truncated incorrect DECIMAL value: '' in /var/www/html/mailscanner/functions.php:1054
Jan 25 10:18:47 sc01 php[2764394]: Stack trace:
Jan 25 10:18:47 sc01 php[2764394]: #0 /var/www/html/mailscanner/functions.php(1054): mysqli->query('REPLACE INTO mt...')
Jan 25 10:18:47 sc01 php[2764394]: #1 /var/www/html/mailscanner/mtalogprocessor.inc.php(135): dbquery('REPLACE INTO mt...')
Jan 25 10:18:47 sc01 php[2764394]: #2 /var/www/html/mailscanner/mtalogprocessor.inc.php(179): MtaLogProcessor->processLine('Jan 23 13:12:05...')
Jan 25 10:18:47 sc01 php[2764394]: #3 /usr/bin/mailwatch/tools/Postfix_relay/mailwatch_postfix_relay.php(97): MtaLogProcessor->doit('cat /var/log/ma...')
Jan 25 10:18:47 sc01 php[2764394]: #4 {main}
Jan 25 10:18:47 sc01 php[2764394]: thrown in /var/www/html/mailscanner/functions.php on line 1054
Jan 25 10:18:47 sc01 php[2764394]: cat: write error: Broken pipe
Jan 25 10:18:47 sc01 systemd[1]: postfix_relay.service: Main process exited, code=exited, status=255/n/a
Jan 25 10:18:47 sc01 systemd[1]: postfix_relay.service: Failed with result 'exit-code'.
Jan 25 10:18:47 sc01 systemd[1]: postfix_relay.service: Service RestartSec=100ms expired, scheduling restart.
Jan 25 10:18:47 sc01 systemd[1]: postfix_relay.service: Scheduled restart job, restart counter is at 63958.
Jan 25 10:18:47 sc01 systemd[1]: Stopped Postfix relay service for MailWatch.
Jan 25 10:18:47 sc01 systemd[1]: Started Postfix relay service for MailWatch.
I'm running:
MailScanner v1.2.18 running on eFa-4.0.4

I don't see this issue with my other efa-project server that handles the same type of traffic. Any ideas?
pingu
Posts: 12
Joined: 10 Dec 2020 08:07

Re: PHP Fatal error / Postfix crash

Post by pingu »

bump
User avatar
shawniverson
Posts: 3644
Joined: 13 Jan 2014 23:30
Location: Indianapolis, Indiana USA
Contact:

Re: PHP Fatal error / Postfix crash

Post by shawniverson »

There's something not quite right in your maillog. Try rotating /var/log/maillog and see if that helps.
Post Reply