Restarting every 10 minutes

Forum for questions and support relating to the 1.31.x releases only.
Locked
juanmoura
Posts: 91
Joined: Fri Nov 24, 2017 11:46 am

Restarting every 10 minutes

Post by juanmoura »

I updated to version 1.31.44 MASTER and every 10 minutes the system restarts.

Image
mathijss
Posts: 10
Joined: Thu May 03, 2018 9:38 am

Re: Restarting every 10 minutes

Post by mathijss »

I'm experiencing the same problem, described in the following thread.
viewtopic.php?f=37&t=27216
simonmanchester
Posts: 2
Joined: Thu Jun 07, 2018 4:19 pm

Re: Restarting every 10 minutes

Post by simonmanchester »

I'm getting the same - Ubuntu 16.04 - tried both master and storagearea builds of 1.31.44.

I get the following when trying to start the service from command line...

Code: Select all

Job for zoneminder.service failed because a timeout was exceeded. See "systemctl status zoneminder.service" and "journalctl -xe" for details.
zoneminder.service couldn't restart.
Here is the output via syslog of when it restarts...

Code: Select all

Jun  7 16:46:07 LINUXSVR systemd[1]: zoneminder.service: Start operation timed out. Terminating.
Jun  7 16:46:07 LINUXSVR zmaudit[1851]: INF [Received TERM, exiting]
Jun  7 16:46:07 LINUXSVR zmdc[1802]: INF [Server exiting at 18/06/07 16:46:07]
Jun  7 16:46:07 LINUXSVR zmdc[1802]: INF ['zmtelemetry.pl' sending stop to pid 1872 at 18/06/07 16:46:07]
Jun  7 16:46:07 LINUXSVR zmdc[1802]: INF ['zmstats.pl' sending stop to pid 1878 at 18/06/07 16:46:07]
Jun  7 16:46:07 LINUXSVR zmdc[1802]: INF ['zmwatch.pl' sending stop to pid 1858 at 18/06/07 16:46:07]
Jun  7 16:46:07 LINUXSVR zmdc[1802]: INF ['zmc -m 1' sending stop to pid 1830 at 18/06/07 16:46:07]
Jun  7 16:46:07 LINUXSVR zmdc[1802]: INF ['zmaudit.pl -c' sending stop to pid 1851 at 18/06/07 16:46:07]
Jun  7 16:46:07 LINUXSVR zmdc[1802]: INF ['zmupdate.pl -c' sending stop to pid 1865 at 18/06/07 16:46:07]
Jun  7 16:46:07 LINUXSVR zmdc[1802]: INF ['zma -m 1' sending stop to pid 1834 at 18/06/07 16:46:07]
Jun  7 16:46:07 LINUXSVR zmc_m1[1830]: ERR [zmc_m1] [Can't insert log entry: sql(06/07/18 16:46:07.457402 zmc_m1[1880].INF-zm_signal.cpp/40 [Got signal 15 (Terminated), exiting) error(db is locked)]
Jun  7 16:46:07 LINUXSVR zmc_m1[1830]: WAR [zmc_m1] [Calling zmDbConnect when already connected]
Jun  7 16:46:07 LINUXSVR zmc_m1[1830]: INF [zmc_m1] [Got signal 15 (Terminated), exiting]
Jun  7 16:46:07 LINUXSVR zmdc[1802]: INF ['zmupdate.pl -c' exited, signal 14]
Jun  7 16:46:07 LINUXSVR zmdc[1802]: INF ['zmtelemetry.pl' exited, signal 14]
Jun  7 16:46:07 LINUXSVR zmdc[1802]: INF ['zmwatch.pl' exited, signal 14]
Jun  7 16:46:07 LINUXSVR zmdc[1802]: INF ['zmstats.pl' exited, signal 14]
Jun  7 16:46:07 LINUXSVR zmc_m1[1830]: INF [zmc_m1] [Got signal 15 (Terminated), exiting]
Jun  7 16:46:07 LINUXSVR zma_m1[1834]: INF [zma_m1] [Got signal 15 (Terminated), exiting]
Jun  7 16:46:07 LINUXSVR zmaudit[1851]: INF [Received TERM, exiting]
Jun  7 16:46:07 LINUXSVR zmdc[1802]: INF ['zmaudit.pl -c' exited normally]
Jun  7 16:46:07 LINUXSVR zma_m1[1834]: INF [zma_m1] [Office: image_count:10827 - Closing event 3, shutting down]
Jun  7 16:46:07 LINUXSVR zmdc[1802]: INF ['zma -m 1' exited normally]
Jun  7 16:46:07 LINUXSVR zmdc[1802]: INF ['zmc -m 1' exited normally]
Jun  7 16:46:07 LINUXSVR zmdc[1802]: INF [Server shutdown at 18/06/07 16:46:07]
Jun  7 16:46:07 LINUXSVR systemd[1]: Failed to start ZoneMinder CCTV recording and surveillance system.
Jun  7 16:46:07 LINUXSVR systemd[1]: zoneminder.service: Unit entered failed state.
Jun  7 16:46:07 LINUXSVR systemd[1]: zoneminder.service: Failed with result 'timeout'.
Jun  7 16:46:08 LINUXSVR web_php[1492]: ERR [Socket /var/run/zm/zms-300617s.sock does not exist.  This file is created by zms, and since it does not exist, either zms did not run, or zms exited early.  Please check your zms logs and ensure that CGI is enabled in apache and check that the PATH_ZMS is set correctly.  Make sure that ZM is actually recording.  If you are trying to view a live stream and the capture process (zmc) is not running then zms will exit. Please go to http://zoneminder.readthedocs.io/en/latest/faq.html#why-can-t-i-see-streamed-images-when-i-can-see-stills-in-the-zone-window-etc for more information.]
Jun  7 16:46:08 LINUXSVR web_php[1492]: ERR [getStreamCmdResponse stream error: Socket /var/run/zm/zms-300617s.sock does not exist.  This file is created by zms, and since it does not exist, either zms did not run, or zms exited early.  Please check your zms logs and ensure that CGI is enabled in apache and check that the PATH_ZMS is set correctly.  Make sure that ZM is actually recording.  If you are trying to view a live stream and the capture process (zmc) is not running then zms will exit. Please go to http://zoneminder.readthedocs.io/en/latest/faq.html#why-can-t-i-see-streamed-images-when-i-can-see-stills-in-the-zone-window-etc for more information. - checkStreamForErrors()]
Jun  7 16:46:08 LINUXSVR zms_m1[1973]: ERR [zms_m1] [Got empty memory map file size 0, is the zmc process for this monitor running?]
Jun  7 16:46:08 LINUXSVR zms_m1[1973]: ERR [zms_m1] [Unable to connect to monitor id 1 for streaming]
Jun  7 16:46:08 LINUXSVR zms_m1[1973]: ERR [zms_m1] [Unable to connect to zmc process for monitor 1]
Jun  7 16:46:10 LINUXSVR web_php[1492]: ERR [Socket /var/run/zm/zms-300617s.sock does not exist.  This file is created by zms, and since it does not exist, either zms did not run, or zms exited early.  Please check your zms logs and ensure that CGI is enabled in apache and check that the PATH_ZMS is set correctly.  Make sure that ZM is actually recording.  If you are trying to view a live stream and the capture process (zmc) is not running then zms will exit. Please go to http://zoneminder.readthedocs.io/en/latest/faq.html#why-can-t-i-see-streamed-images-when-i-can-see-stills-in-the-zone-window-etc for more information.]
Jun  7 16:46:10 LINUXSVR web_php[1492]: ERR [getStreamCmdResponse stream error: Socket /var/run/zm/zms-300617s.sock does not exist.  This file is created by zms, and since it does not exist, either zms did not run, or zms exited early.  Please check your zms logs and ensure that CGI is enabled in apache and check that the PATH_ZMS is set correctly.  Make sure that ZM is actually recording.  If you are trying to view a live stream and the capture process (zmc) is not running then zms will exit. Please go to http://zoneminder.readthedocs.io/en/latest/faq.html#why-can-t-i-see-streamed-images-when-i-can-see-stills-in-the-zone-window-etc for more information. - checkStreamForErrors()]
Jun  7 16:46:10 LINUXSVR zms_m1[1974]: ERR [zms_m1] [Got empty memory map file size 0, is the zmc process for this monitor running?]
Jun  7 16:46:10 LINUXSVR zms_m1[1974]: ERR [zms_m1] [Unable to connect to monitor id 1 for streaming]
Jun  7 16:46:10 LINUXSVR zms_m1[1974]: ERR [zms_m1] [Unable to connect to zmc process for monitor 1]
Jun  7 16:46:12 LINUXSVR web_php[1492]: ERR [Socket /var/run/zm/zms-300617s.sock does not exist.  This file is created by zms, and since it does not exist, either zms did not run, or zms exited early.  Please check your zms logs and ensure that CGI is enabled in apache and check that the PATH_ZMS is set correctly.  Make sure that ZM is actually recording.  If you are trying to view a live stream and the capture process (zmc) is not running then zms will exit. Please go to http://zoneminder.readthedocs.io/en/latest/faq.html#why-can-t-i-see-streamed-images-when-i-can-see-stills-in-the-zone-window-etc for more information.]
Jun  7 16:46:12 LINUXSVR web_php[1492]: ERR [getStreamCmdResponse stream error: Socket /var/run/zm/zms-300617s.sock does not exist.  This file is created by zms, and since it does not exist, either zms did not run, or zms exited early.  Please check your zms logs and ensure that CGI is enabled in apache and check that the PATH_ZMS is set correctly.  Make sure that ZM is actually recording.  If you are trying to view a live stream and the capture process (zmc) is not running then zms will exit. Please go to http://zoneminder.readthedocs.io/en/latest/faq.html#why-can-t-i-see-streamed-images-when-i-can-see-stills-in-the-zone-window-etc for more information. - checkStreamForErrors()]
Jun  7 16:46:12 LINUXSVR zms_m1[1975]: ERR [zms_m1] [Got empty memory map file size 0, is the zmc process for this monitor running?]
Jun  7 16:46:12 LINUXSVR zms_m1[1975]: ERR [zms_m1] [Unable to connect to monitor id 1 for streaming]
Jun  7 16:46:12 LINUXSVR zms_m1[1975]: ERR [zms_m1] [Unable to connect to zmc process for monitor 1]
Jun  7 16:46:14 LINUXSVR web_php[1183]: ERR [Socket /var/run/zm/zms-300617s.sock does not exist.  This file is created by zms, and since it does not exist, either zms did not run, or zms exited early.  Please check your zms logs and ensure that CGI is enabled in apache and check that the PATH_ZMS is set correctly.  Make sure that ZM is actually recording.  If you are trying to view a live stream and the capture process (zmc) is not running then zms will exit. Please go to http://zoneminder.readthedocs.io/en/latest/faq.html#why-can-t-i-see-streamed-images-when-i-can-see-stills-in-the-zone-window-etc for more information.]
Jun  7 16:46:14 LINUXSVR web_php[1183]: ERR [getStreamCmdResponse stream error: Socket /var/run/zm/zms-300617s.sock does not exist.  This file is created by zms, and since it does not exist, either zms did not run, or zms exited early.  Please check your zms logs and ensure that CGI is enabled in apache and check that the PATH_ZMS is set correctly.  Make sure that ZM is actually recording.  If you are trying to view a live stream and the capture process (zmc) is not running then zms will exit. Please go to http://zoneminder.readthedocs.io/en/latest/faq.html#why-can-t-i-see-streamed-images-when-i-can-see-stills-in-the-zone-window-etc for more information. - checkStreamForErrors()]
Jun  7 16:46:14 LINUXSVR zms_m1[1976]: ERR [zms_m1] [Got empty memory map file size 0, is the zmc process for this monitor running?]
Jun  7 16:46:14 LINUXSVR zms_m1[1976]: ERR [zms_m1] [Unable to connect to monitor id 1 for streaming]
Jun  7 16:46:14 LINUXSVR zms_m1[1976]: ERR [zms_m1] [Unable to connect to zmc process for monitor 1]
Jun  7 16:46:16 LINUXSVR web_php[1183]: ERR [Socket /var/run/zm/zms-300617s.sock does not exist.  This file is created by zms, and since it does not exist, either zms did not run, or zms exited early.  Please check your zms logs and ensure that CGI is enabled in apache and check that the PATH_ZMS is set correctly.  Make sure that ZM is actually recording.  If you are trying to view a live stream and the capture process (zmc) is not running then zms will exit. Please go to http://zoneminder.readthedocs.io/en/latest/faq.html#why-can-t-i-see-streamed-images-when-i-can-see-stills-in-the-zone-window-etc for more information.]
Jun  7 16:46:16 LINUXSVR web_php[1183]: ERR [getStreamCmdResponse stream error: Socket /var/run/zm/zms-300617s.sock does not exist.  This file is created by zms, and since it does not exist, either zms did not run, or zms exited early.  Please check your zms logs and ensure that CGI is enabled in apache and check that the PATH_ZMS is set correctly.  Make sure that ZM is actually recording.  If you are trying to view a live stream and the capture process (zmc) is not running then zms will exit. Please go to http://zoneminder.readthedocs.io/en/latest/faq.html#why-can-t-i-see-streamed-images-when-i-can-see-stills-in-the-zone-window-etc for more information. - checkStreamForErrors()]
Jun  7 16:46:16 LINUXSVR zms_m1[1977]: ERR [zms_m1] [Got empty memory map file size 0, is the zmc process for this monitor running?]
Jun  7 16:46:16 LINUXSVR zms_m1[1977]: ERR [zms_m1] [Unable to connect to monitor id 1 for streaming]
Jun  7 16:46:16 LINUXSVR zms_m1[1977]: ERR [zms_m1] [Unable to connect to zmc process for monitor 1]
Jun  7 16:46:17 LINUXSVR systemd[1]: zoneminder.service: Service hold-off time over, scheduling restart.
Jun  7 16:46:17 LINUXSVR systemd[1]: Stopped ZoneMinder CCTV recording and surveillance system.
Jun  7 16:46:17 LINUXSVR systemd[1]: Starting ZoneMinder CCTV recording and surveillance system...
simonmanchester
Posts: 2
Joined: Thu Jun 07, 2018 4:19 pm

Re: Restarting every 10 minutes

Post by simonmanchester »

I've just read on GitHub that they identified a race condition with the pidfile check in zoneminder.service file. Commenting out the pidfile line in zoneminder.service should resolve the restart issue for now until the next update. I'm just trying that now and so far it seems ok. :)
Locked