not streaming video whith OPT_USE_AUTH = true

Forum for questions and support relating to the 1.30.x releases only.
Locked
kimbilio
Posts: 3
Joined: Wed Jul 04, 2018 8:50 am
Location: Tororo - Uganda

not streaming video whith OPT_USE_AUTH = true

Post by kimbilio »

I have a properly working zoneminder installation, with all functions working.
However when I enable "OPT_USE_AUTH" it does mostly as expected like logging on
and most function will still work like capturing and analizing and creating
alarm alerts. I can even view the alarm 'stills', but only video streaming, both
captured and live are no longer working.
The log will create a lot of repeated entries of:
2018-07-05 12:02:09.052775 zma_m5 17657 INF Foscam64: 331 - Closing event 1398, alarm end zm_monitor.cpp 1716
2018-07-05 12:02:08.968441 zma_m5 17657 INF Foscam64: 331 - Left alarm state (1398) - 64(14) images zm_monitor.cpp 1711
2018-07-05 12:02:03.963496 zma_m5 17657 INF Foscam64: 306 - Gone into alert state zm_monitor.cpp 1704
2018-07-05 12:02:01.025225 zma_m5 17657 INF Foscam64: 292 - Opening new event 1398, alarm start zm_monitor.cpp 1660
2018-07-05 12:02:00.694636 zma_m5 17657 INF Foscam64: 292 - Gone into alarm state zm_monitor.cpp 1614
2018-07-05 12:01:53.771184 zms 17664 ERR Unable to authenticate user zms.cpp 225
2018-07-05 12:01:53.620623 web_js 17613 ERR getStreamCmdResponse stream error: Socket /var/run/zm/zms-100359s.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/lat ... window-etc for more information. - checkStreamForErrors() ?view=watch
2018-07-05 12:01:53.421211 web_php 17613 ERR Socket /var/run/zm/zms-100359s.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/lat ... window-etc for more information. /usr/share/zoneminder/www/includes/functions.php 2033
2018-07-05 12:01:49.761134 zma_m6 17569 INF Foscam65: 1102 - Closing event 1397, alarm end zm_monitor.cpp 1716
2018-07-05 12:01:49.682973 zma_m6 17569 INF Foscam65: 1102 - Left alarm state (1397) - 57(7) images zm_monitor.cpp 1711
2018-07-05 12:01:46.809649 zma_m6 17569 INF Foscam65: 1077 - Gone into alert state zm_monitor.cpp 1704
2018-07-05 12:01:44.596241 zma_m6 17569 INF Foscam65: 1070 - Opening new event 1397, alarm start zm_monitor.cpp 1660
2018-07-05 12:01:44.503487 zma_m6 17569 INF Foscam65: 1070 - Gone into alarm state zm_monitor.cpp 1614
2018-07-05 12:01:41.540197 zms 17663 ERR Unable to authenticate user zms.cpp 225
2018-07-05 12:01:41.389228 web_js 32596 ERR getStreamCmdResponse stream error: Socket /var/run/zm/zms-100359s.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/lat ... window-etc for more information. - checkStreamForErrors() ?view=watch
2018-07-05 12:01:41.130520 web_php 32596 ERR Socket /var/run/zm/zms-100359s.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/lat ... window-etc for more information. /usr/share/zoneminder/www/includes/functions.php 2033
-----ends logfile------

However, the moment I disable "OPT_USE_AUTH" on the config page, all goes back to normal.

I am using zm 1.30 on Ubuntu 18.04 server
where I installed first a full LAMP installation, then followed the following guide:
https://wiki.zoneminder.com/Ubuntu_Serv ... e_easy_way

I can see it all starts with 'Unable to authenticate user zms.cpp' but what can I do about it?..
rockedge
Posts: 1173
Joined: Fri Apr 04, 2014 1:46 pm
Location: Connecticut,USA

Re: not streaming video whith OPT_USE_AUTH = true

Post by rockedge »

try and set AUTH_RELAY to "none" when OPT_USE_AUTH is selected and enabled.....does the stream work?
do you have the AUTH_HASH_SECRET set to something? Set it and try setting the AUTH_RELAY back to "hashed"....does this work?
kimbilio
Posts: 3
Joined: Wed Jul 04, 2018 8:50 am
Location: Tororo - Uganda

Re: not streaming video whith OPT_USE_AUTH = true

Post by kimbilio »

Thank you! That was exactly the solution.
I am a very happy person now :-)
Locked