ZoneMinder 1.30.2 stops working over time

Forum for questions and support relating to the 1.30.x releases only.
Locked
raymonvdm
Posts: 23
Joined: Thu Jan 16, 2014 3:01 pm

ZoneMinder 1.30.2 stops working over time

Post by raymonvdm »

I have updated my Ubuntu 16.0.4 LTS 32bit ZoneMinder server using

Code: Select all

apt-get update
apt-get upgrade
apt-get dist-upgrade
After this ZoneMinder is updated from 1.30 to 1.30.2 but now Zoneminder stops working over time. I think this is related to a logrotate or something simular but i cannot find the exact cause.

This is how i find the service when it is not working

Code: Select all


root@zm:~# service zoneminder status
● zoneminder.service - ZoneMinder CCTV recording and surveillance system
   Loaded: loaded (/lib/systemd/system/zoneminder.service; enabled; vendor preset: enabled)
   Active: failed (Result: exit-code) since Tue 2017-04-25 02:01:43 CEST; 8h ago
  Process: 32553 ExecStop=/usr/bin/zmpkg.pl stop (code=exited, status=1/FAILURE)
  Process: 13354 ExecStart=/usr/bin/zmpkg.pl start (code=exited, status=0/SUCCESS)
 Main PID: 13371 (code=exited, status=255)

Warning: Journal has been rotated since unit was started. Log output is incomplete or unavailable.
root@zm:~# 

Nagios is telling me the "exact" time of the issue

Last State Change: 04-25-2017 02:06:30


When i look at syslog i found out this

Code: Select all


Apr 25 02:01:19 zm zmdc[13371]: FAT [Can't execute log entry 'insert into Logs ( TimeKey, Component, Pid, Level, Code, Message, File, Line ) values ( ?, ?, ?, ?, ?, ?, ?, NULL )': Lost connection to MySQL server during query]
Apr 25 02:01:21 zm systemd[1]: zoneminder.service: Main process exited, code=exited, status=255/n/a
Apr 25 02:01:24 zm systemd[1]: zoneminder.service: Control process exited, code=exited status=1
Apr 25 02:01:28 zm zmc_m15[13453]: ERR [Select error: Interrupted system call]
Apr 25 02:01:28 zm zmc_m15[13453]: ERR [Unable to read header]
Apr 25 02:01:29 zm zmc_m15[13453]: ERR [Unable to get response, disconnecting]
Apr 25 02:01:43 zm systemd[1]: zoneminder.service: Unit entered failed state.
Apr 25 02:01:43 zm systemd[1]: zoneminder.service: Failed with result 'exit-code'.

raymonvdm
Posts: 23
Joined: Thu Jan 16, 2014 3:01 pm

Re: ZoneMinder 1.30.2 stops working over time

Post by raymonvdm »

I have moved my MySQL backup to another time (02:00 to 14:00) and now the issues occurs when the backup runs. So i gues i just proved the MySQL dump is the issue :shock:

Code: Select all


root@zm:~# service zoneminder status
● zoneminder.service - ZoneMinder CCTV recording and surveillance system
   Loaded: loaded (/lib/systemd/system/zoneminder.service; enabled; vendor preset: enabled)
   Active: failed (Result: exit-code) since Tue 2017-04-25 14:02:49 CEST; 1h 9min ago
  Process: 23914 ExecStop=/usr/bin/zmpkg.pl stop (code=exited, status=1/FAILURE)
  Process: 18639 ExecStart=/usr/bin/zmpkg.pl start (code=exited, status=0/SUCCESS)
 Main PID: 18656 (code=exited, status=9)

Apr 25 14:02:46 zm sudo[23924]: pam_unix(sudo:session): session closed for user www-data
Apr 25 14:02:46 zm sudo[23926]:     root : TTY=unknown ; PWD=/usr/share/zoneminder/www ; USER=www-data ; COMMAND=/usr/bin/zmdc.pl check
Apr 25 14:02:46 zm sudo[23926]: pam_unix(sudo:session): session opened for user www-data by (uid=0)
Apr 25 14:02:48 zm sudo[23926]: pam_unix(sudo:session): session closed for user www-data
Apr 25 14:02:48 zm systemd[1]: zoneminder.service: Control process exited, code=exited status=1
Apr 25 14:02:49 zm zmc_m13[18708]: ERR [Select error: Interrupted system call]
Apr 25 14:02:49 zm zmc_m13[18708]: ERR [Unable to read header]
Apr 25 14:02:49 zm zmc_m13[18708]: ERR [Unable to get response, disconnecting]
Apr 25 14:02:49 zm systemd[1]: zoneminder.service: Unit entered failed state.
Apr 25 14:02:49 zm systemd[1]: zoneminder.service: Failed with result 'exit-code'.
root@zm:~# 

Locked