Below is a log before a zoneminder.service restart with events generated and the filter configured to email them:
Code: Select all
2016-06-09 15:01:09.654030 zmfilter 1546 ERR Can't send email: error closing /usr/sbin/sendmail: (exit 256) zmfilter.pl
2016-06-09 15:01:09.114490 zmfilter 1546 INF Sending notification email 'ZoneMinder: Alarm - Garage_View-21 (25 - 15 189)' zmfilter.pl
2016-06-09 15:01:09.097750 zmfilter 1546 INF Creating notification email zmfilter.pl
2016-06-09 15:01:09.086740 zmfilter 1546 ERR Can't send email: error closing /usr/sbin/sendmail: (exit 256) zmfilter.pl
2016-06-09 15:01:08.564580 zmfilter 1546 INF Sending notification email 'ZoneMinder: Alarm - Garage_View-20 (27 - 15 139)' zmfilter.pl
2016-06-09 15:01:08.547980 zmfilter 1546 INF Creating notification email zmfilter.pl
2016-06-09 15:01:08.515430 zmfilter 1546 ERR Can't send email: error closing /usr/sbin/sendmail: (exit 256) zmfilter.pl
2016-06-09 15:01:07.989810 zmfilter 1546 INF Sending notification email 'ZoneMinder: Alarm - Garage_View-19 (7 - 6 11)' zmfilter.pl
2016-06-09 15:01:07.973240 zmfilter 1546 INF Creating notification email zmfilter.pl
2016-06-09 15:01:07.954350 zmfilter 1546 ERR Can't send email: error closing /usr/sbin/sendmail: (exit 256) zmfilter.pl
2016-06-09 15:01:07.415120 zmfilter 1546 INF Sending notification email 'ZoneMinder: Alarm - Garage_View-18 (5 - 5 3)' zmfilter.pl
2016-06-09 15:01:07.390050 zmfilter 1546 INF Creating notification email zmfilter.pl
and this one is after a zoneminder.service restart:
Code: Select all
DATE/TIME
COMPONENT SERVER PID LEVEL MESSAGE FILE LINE
2016-06-09 15:08:48.628660 zmfilter 2621 INF Notification email sent zmfilter.pl
2016-06-09 15:08:46.058810 zmfilter 2621 INF Sending notification email 'ZoneMinder: Alarm - Garage_View-21 (25 - 15 189)' zmfilter.pl
2016-06-09 15:08:46.033650 zmfilter 2621 INF Creating notification email zmfilter.pl
2016-06-09 15:08:45.986260 zmfilter 2621 INF Notification email sent zmfilter.pl
2016-06-09 15:08:43.426690 zmfilter 2621 INF Sending notification email 'ZoneMinder: Alarm - Garage_View-20 (27 - 15 139)' zmfilter.pl
2016-06-09 15:08:43.401640 zmfilter 2621 INF Creating notification email zmfilter.pl
2016-06-09 15:08:43.352900 zmfilter 2621 INF Notification email sent zmfilter.pl
2016-06-09 15:08:40.811210 zmfilter 2621 INF Sending notification email 'ZoneMinder: Alarm - Garage_View-19 (7 - 6 11)' zmfilter.pl
2016-06-09 15:08:40.786160 zmfilter 2621 INF Creating notification email zmfilter.pl
2016-06-09 15:08:40.742140 zmfilter 2621 INF Notification email sent zmfilter.pl
2016-06-09 15:08:38.129190 zmfilter 2621 INF Sending notification email 'ZoneMinder: Alarm - Garage_View-18 (5 - 5 3)' zmfilter.pl
2016-06-09 15:08:38.104160 zmfilter 2621 INF Creating notification email zmfilter.pl
As one might suspect after a restart of zoneminder I get all unsent events at once.
I have got this line changed in /usr/bin/zmfilter.pl:
And a question: why the instructions from the wiki author changed $Config{ZM_EMAIL_HOST} to a different Variable $Config{ZM_EMAIL_ADDRESS} and without a timeout?### Send the Message
#MIME::Lite->send( "smtp", $Config{ZM_EMAIL_HOST}, Timeout=>60 );
#$mail->send();
$mail->send('sendmail','/usr/sbin/ssmtp',$Config{ZM_EMAIL_ADDRESS});
Could that be an issue?