zoneminder crashes frequently

Forum for questions and support relating to the 1.30.x releases only.
Post Reply
rdorsch
Posts: 9
Joined: Sat Jun 03, 2017 7:26 am

zoneminder crashes frequently

Post by rdorsch » Sat Nov 17, 2018 9:35 pm

Hi,

since a few days, zoneminder crashes frequently (2-3 times/hour). The output of

systemctrl status zoneminder is

Code: Select all

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 Sat 2018-11-17 20:44:38 CET; 23s ago
     Docs: http://zoneminder.readthedocs.org/en/latest/
  Process: 22745 ExecStop=/usr/bin/zmpkg.pl stop (code=exited, status=1/FAILURE)
  Process: 8772 ExecStart=/usr/bin/zmpkg.pl start (code=exited, status=0/SUCCESS)
 Main PID: 9347 (code=exited, status=4)

Nov 17 20:44:32 home zma_m4[10459]: INF [Got signal 15 (Terminated), exiting]
Nov 17 20:44:32 home zma_m2[10141]: INF [Got signal 15 (Terminated), exiting]
Nov 17 20:44:32 home zmc_m3[10265]: INF [Got signal 15 (Terminated), exiting]
Nov 17 20:44:32 home zma_m1[28494]: INF [Got signal 15 (Terminated), exiting]
Nov 17 20:44:32 home zmc_m4[10408]: INF [Got signal 15 (Terminated), exiting]
Nov 17 20:44:32 home zma_m3[19097]: INF [Got signal 15 (Terminated), exiting]
Nov 17 20:44:32 home zmc_m2[17319]: INF [Got signal 15 (Terminated), exiting]
Nov 17 20:44:35 home zma_m1[28494]: INF [Cam0: 608 - Closing event 88214, shutting down]
Nov 17 20:44:38 home systemd[1]: zoneminder.service: Unit entered failed state.
Nov 17 20:44:38 home systemd[1]: zoneminder.service: Failed with result 'exit-code'.
Does status=4 tell something?

When I grep for ERR in syslog, I get

Code: Select all

Nov 17 19:46:21 home zmwatch[31532]: ERR [Error getting last capture time for  Cam2]
Nov 17 19:47:14 home zmwatch[31532]: ERR [Error getting last capture time for  Cam2]
Nov 17 19:47:33 home zma_m3[15329]: ERR [Can't insert log entry: sql(insert into Logs ( TimeKey, Component, ServerId, Pid, Level, Code, Message, File, Line ) values ( 1542480449.876458, 'zma_m3', 0, 15329, 0, 'INF', 'Analysis fps (2.00) is lower than capturing fps (31.42), disabling adaptive 
skip feature', 'zm_monitor.cpp', 889 )) error(Lost connection to MySQL server during query)]
Nov 17 19:47:43 home zmwatch[31532]: ERR [Error getting last capture time for  Cam2]
Nov 17 19:51:37 home zmc_m2[2483]: ERR [Can't insert log entry: sql(insert into Logs ( TimeKey, Component, ServerId, Pid, Level, Code, Message, File, Line ) values ( 1542480691.540434, 'zmc_m2', 0, 2483, 0, 'INF', 'Priming capture from rtsp://admin:Inei5wuu@cam1/Streaming/Channels/2', 'zm_ffm
peg_camera.cpp', 104 )) error(Lost connection to MySQL server during query)]
Nov 17 19:55:25 home zmdc[22232]: ERR ['zmc -m 1' exited abnormally, exit status 255]
Nov 17 19:55:27 home zmdc[22232]: ERR ['zmc -m 2' exited abnormally, exit status 255]
Nov 17 19:55:29 home zma_m2[23206]: ERR [Shared data not initialised by capture daemon for monitor Cam1]
Nov 17 19:55:29 home zmdc[22232]: ERR ['zma -m 2' exited abnormally, exit status 255]
Nov 17 19:55:30 home zmdc[22232]: ERR ['zmc -m 3' exited abnormally, exit status 255]
Nov 17 19:55:32 home zmdc[22232]: ERR ['zmc -m 4' exited abnormally, exit status 255]
Nov 17 20:12:02 home zma_m2[23267]: ERR [Can't insert log entry: sql(insert into Logs ( TimeKey, Component, ServerId, Pid, Level, Code, Message, File, Line ) values ( 1542481917.237972, 'zma_m2', 0, 23267, 0, 'INF', 'ExtendAlarm count: 13, ExtendAlarm frames: 15', 'zm_zone.cpp', 184 )) error(
Lost connection to MySQL server during query)]
Nov 17 20:12:54 home zmwatch[23776]: ERR [Error getting last capture time for  Cam1]
Nov 17 20:13:21 home zmwatch[23776]: ERR [Error getting last capture time for  Cam1]
Nov 17 20:13:57 home zma_m3[23357]: ERR [Can't insert log entry: sql(insert into Logs ( TimeKey, Component, ServerId, Pid, Level, Code, Message, File, Line ) values ( 1542482033.334940, 'zma_m3', 0, 23357, 0, 'INF', 'ExtendAlarm count: 0, ExtendAlarm frames: 2', 'zm_zone.cpp', 184 )) error(Lo
st connection to MySQL server during query)]
Nov 17 20:16:26 home zmdc[20503]: ERR ['zmc -m 1' exited abnormally, exit status 255]
Nov 17 20:16:54 home zmdc[20503]: ERR ['zmc -m 2' exited abnormally, exit status 255]
Nov 17 20:20:14 home zmdc[9347]: ERR ['zmc -m 1' exited abnormally, exit status 255]
Nov 17 20:20:16 home zmdc[9347]: ERR ['zmc -m 2' exited abnormally, exit status 255]
Nov 17 20:20:18 home zmdc[9347]: ERR ['zmc -m 3' exited abnormally, exit status 255]
Nov 17 20:20:20 home zmdc[9347]: ERR ['zmc -m 4' exited abnormally, exit status 255]
Nov 17 20:35:37 home zmwatch[10678]: ERR [Error getting last capture time for  Cam0]
Nov 17 20:36:12 home zmwatch[10678]: ERR [Error getting last capture time for  Cam0]
Nov 17 20:36:49 home zmwatch[10678]: ERR [Error getting last capture time for  Cam0]
Nov 17 20:37:55 home zmwatch[10678]: ERR [Error getting last capture time for  Cam0]
Nov 17 20:38:30 home zmwatch[10678]: ERR [Error getting last capture time for  Cam0]
Nov 17 20:44:29 home zmwatch[10678]: ERR [Memory map file '/dev/shm/zm.mmap.1' does not exist.  zmc might not be running.]
Nov 17 20:46:25 home zmdc[30908]: ERR ['zmc -m 1' exited abnormally, exit status 255]
Nov 17 20:46:30 home zmdc[30908]: ERR ['zmc -m 2' exited abnormally, exit status 255]
Nov 17 20:46:44 home zmdc[30908]: ERR ['zmc -m 3' exited abnormally, exit status 255]
Nov 17 20:46:53 home zmdc[30908]: ERR ['zmc -m 4' exited abnormally, exit status 255]
Nov 17 20:47:00 home zma_m4[3636]: ERR [Shared data not initialised by capture daemon for monitor Cam3]
Nov 17 20:47:00 home zmdc[30908]: ERR ['zma -m 4' exited abnormally, exit status 255]
Nov 17 20:50:15 home zmdc[19780]: ERR ['zmc -m 1' exited abnormally, exit status 255]
Nov 17 20:50:17 home zmdc[19780]: ERR ['zmc -m 2' exited abnormally, exit status 255]
Nov 17 20:50:20 home zmdc[19780]: ERR ['zmc -m 3' exited abnormally, exit status 255]
Nov 17 20:50:22 home zmdc[19780]: ERR ['zmc -m 4' exited abnormally, exit status 255]
Nov 17 21:02:35 home zmc_m1[20284]: ERR [Can't insert log entry: sql(insert into Logs ( TimeKey, Component, ServerId, Pid, Level, Code, Message, File, Line ) values ( 1542484952.701707, 'zmc_m1', 0, 20284, -1, 'WAR', 'Buffer overrun at index 14, image 10964, slow down capture, speed up analysis or increase ring buffer size', 'zm_monitor.cpp', 3094 )) error(Lost connection to MySQL server during query)]
Nov 17 21:02:36 home zmdc[19780]: ERR ['zmc -m 1' exited abnormally, exit status 255]
Nov 17 21:02:56 home zmwatch[21146]: ERR [Error getting last capture time for  Cam0]
Nov 17 21:09:56 home zmdc[19780]: ERR ['zmc -m 2' exited abnormally, exit status 255]
Nov 17 21:10:17 home zmc_m2[12481]: ERR [Can't insert log entry: sql(insert into Logs ( TimeKey, Component, ServerId, Pid, Level, Code, Message, File, Line ) values ( 1542485412.329454, 'zmc_m2', 0, 12481, 0, 'INF', 'Priming capture from rtsp://admin:Inei5wuu@cam1/Streaming/Channels/2', 'zm_ffmpeg_camera.cpp', 104 )) error(Lost connection to MySQL server during query)]
Nov 17 21:10:34 home zmwatch[21146]: ERR [Memory map file '/dev/shm/zm.mmap.2' does not exist.  zmc might not be running.]
Nov 17 21:11:10 home zmdc[19780]: ERR ['zmc -m 2' exited abnormally, exit status 255]
Nov 17 21:12:29 home zma_m1[12791]: ERR [Can't insert log entry: sql(insert into Logs ( TimeKey, Component, ServerId, Pid, Level, Code, Message, File, Line ) values ( 1542485545.447368, 'zma_m1', 0, 12791, 0, 'INF', 'Cam0: 1098 - Gone into prealarm state', 'zm_monitor.cpp', 1689 )) error(Lost connection to MySQL server during query)]
Nov 17 21:12:32 home zmwatch[21146]: ERR [Error getting last capture time for  Cam1]
Nov 17 21:19:24 home zmwatch[21146]: ERR [Error getting last capture time for  Cam2]
Nov 17 21:19:48 home zmwatch[21146]: ERR [Error getting last capture time for  Cam2]
Nov 17 21:20:29 home zmwatch[21146]: ERR [Error getting last capture time for  Cam2]
Nov 17 21:20:49 home zmwatch[21146]: ERR [Error getting last capture time for  Cam2]
Nov 17 21:23:38 home zmwatch[21146]: ERR [Error getting last capture time for  Cam1]
Nov 17 21:24:06 home zmwatch[21146]: ERR [Error getting last capture time for  Cam1]
Nov 17 21:25:30 home zmwatch[21146]: ERR [Memory map file '/dev/shm/zm.mmap.2' does not exist.  zmc might not be running.]
Nov 17 21:25:36 home zmdc[19780]: ERR ['zmc -m 2' exited abnormally, exit status 255]
Nov 17 21:25:49 home zmwatch[21146]: ERR [Error getting last capture time for  Cam1]
Nov 17 21:26:16 home zmwatch[21146]: ERR [Error getting last capture time for  Cam1]
Nov 17 21:27:58 home zmdc[19780]: ERR ['zmc -m 3' exited abnormally, exit status 255]
Nov 17 21:28:54 home zmwatch[21146]: ERR [Error getting last capture time for  Cam2]
Nov 17 21:29:33 home zma_m2[24032]: ERR [Can't insert log entry: sql(insert into Logs ( TimeKey, Component, ServerId, Pid, Level, Code, Message, File, Line ) values ( 1542486566.976145, 'zma_m2', 0, 24032, 0, 'INF', 'ExtendAlarm count: 14, ExtendAlarm frames: 15', 'zm_zone.cpp', 184 )) error(Lost connection to MySQL server during query)]
Nov 17 21:31:06 home zmdc[12701]: ERR ['zmc -m 1' exited abnormally, exit status 255]
Nov 17 21:35:18 home zmdc[2564]: ERR ['zmc -m 1' exited abnormally, exit status 255]
Nov 17 21:35:19 home zmdc[2564]: ERR ['zmc -m 2' exited abnormally, exit status 255]
Nov 17 21:35:21 home zmdc[2564]: ERR ['zmc -m 3' exited abnormally, exit status 255]
Nov 17 21:35:25 home zma_m3[3417]: ERR [Shared data not initialised by capture daemon for monitor Cam2]
Nov 17 21:35:25 home zmdc[2564]: ERR ['zma -m 3' exited abnormally, exit status 255]
Nov 17 21:35:26 home zmdc[2564]: ERR ['zmc -m 4' exited abnormally, exit status 255]
Nov 17 21:54:24 home zmdc[2564]: ERR ['zmc -m 2' exited abnormally, exit status 255]
Nov 17 21:54:43 home zmwatch[3808]: ERR [Error getting last capture time for  Cam1]
Nov 17 21:58:15 home zmdc[2564]: ERR ['zmc -m 3' exited abnormally, exit status 255]
Any hint or advice is welcome....

Thanks
Rainer

SkippyDo
Posts: 36
Joined: Mon Nov 20, 2017 6:49 pm

Re: zoneminder crashes frequently

Post by SkippyDo » Wed Dec 05, 2018 10:03 pm

Stating what hardware and OS you're running would help...

Seems that the source of the problem might be with MySQL. I'd look for logs associate with it (since I have no idea what system I cannot point you where to look). This is about the limit of my "knowledge."

User avatar
iconnor
Posts: 613
Joined: Fri Oct 29, 2010 1:43 am
Location: Toronto
Contact:

Re: zoneminder crashes frequently

Post by iconnor » Sat Dec 08, 2018 3:53 pm

You might be running out of connections to mysql. Or mysql might be going away for other reasons. Check mysql logs

Post Reply

Who is online

Users browsing this forum: roller24, suknil and 2 guests