Giter Club home page Giter Club logo

Comments (21)

welcome avatar welcome commented on July 1, 2024

Thanks for opening your first issue here! Just a reminder, this forum is for Bug Reports only. Be sure to follow the issue template!

from zoneminder.

ovargasp avatar ovargasp commented on July 1, 2024

schnudd31do3, thanx for the report, I was able to reproduce the behavior, you must see there is in fact a problem reported in your logs about that, it states that a font file is missing... that's why you're not seeing the time stamp. This is what my log shows.

image

A new release will fix the problem, but meanwhile there is a work around you can apply: download the file and place it in the corresponding forder.

The file is located here: https://github.com/ZoneMinder/zoneminder/blob/master/fonts/default.zmfnt

Once you have it, move it to the corresponding folder and restart zoneminder service so it gets recognized, that'll fix it.

from zoneminder.

connortechnology avatar connortechnology commented on July 1, 2024

Why was it missing I wonder? Should have been installed automatically.

from zoneminder.

schnudd31do3 avatar schnudd31do3 commented on July 1, 2024

I tried it twice. I restored my server to the state before updating and it was always the same result.

Now I found the reason:
1.36.33: /usr/share/zoneminder/www/fonts/default.zmfnt
1.37.59: /usr/share/zoneminder/fonts/default.zmfnt

After changing the options to the new path, the text was shown again.

I am wondering why you have changed the folder structure and why the upgrade process does not adapt this path in the options.

from zoneminder.

schnudd31do3 avatar schnudd31do3 commented on July 1, 2024

There is one question left. Why does the camera image only appear with a delay of about a minute after the URL is opened in the browser? https://mycamserver.de/zm/cgi-bin/zms?mode=jpeg&monitor=1&user=MyUser&pass=MyPass

By using mode=single, the image is shown immediately.

from zoneminder.

ovargasp avatar ovargasp commented on July 1, 2024

schnudd31do3, I'm glad you got your first issue fixed, about this second question, to try and figure out the problem is necessary to have some more information, logging, what browsers have you tried, etc.

I tried to replicate what you're saying but it's working fine in my Debian installs...

from zoneminder.

schnudd31do3 avatar schnudd31do3 commented on July 1, 2024

I dont have any errors in the apache2 logs nor in any other logfile. It is the same on Edge, Firefox and Chrome. I don't have any idea how to debug it. I observed it in both ways: Restarting the apache2 service or refreshing the browser by F5 stops streaming and starts the delay of about 1 minute. I know, that in former times the video stream was immediately shown but I am not sure when the behaviour rised.

from zoneminder.

ovargasp avatar ovargasp commented on July 1, 2024

Can you open the monitor view and right click on top of the stream then select "copy the image URL", that will give you a slightly different URL that the one you're using, try and use that one in another browser tab... it's important to leave UI monitor view prior to try and open this URL, because it will use the same randomizer number that the monitor view and it will delay the playback.

from zoneminder.

schnudd31do3 avatar schnudd31do3 commented on July 1, 2024

This URL has the same delay as a result: https://mycamserver.de/zm/index.php?view=watch&mid=1
It makes no difference using a separate tab

from zoneminder.

connortechnology avatar connortechnology commented on July 1, 2024

I think we would need to turn on debug logging and check the zms_m1.log

from zoneminder.

ovargasp avatar ovargasp commented on July 1, 2024

sorry my bad, maybe I didn't make myself clear, open the monitor view, and right click in the stream image directly to get the image URL, this is what it looks like in my browser, sorry is in spanish but you'll get the idea

image

the URL should look like this:

https://server_url/zm/cgi-bin/nph-zms?mode=jpeg&maxfps=&scale=100&state=1&monitor=16&rand=1713796252&connkey=957656

then go back to the console view to leave monitor view and open the image in a new tab. (else the new tab will be very slow to open)

if this is not faster to open, you should do as connortechnology said and turn on debug

from zoneminder.

schnudd31do3 avatar schnudd31do3 commented on July 1, 2024

Thanks. I got you. In my case it is : https://mycamserver.de/zm/cgi-bin/nph-zms?mode=jpeg&maxfps=&scale=100&state=1&monitor=1&auth=1315899ba107d0c2d0625ae643be8b5e&user=admin&rand=1713846240&connkey=308082.

Logging from the console:

3.04.24, 06:56:13 MESZ web_js 646 ERR eval violated CSP script-src chrome-extension 2
23.04.24, 06:53:11 MESZ web_js 1131 ERR eval violated CSP script-src chrome-extension 2
23.04.24, 06:51:55 MESZ web_js 1147 ERR eval violated CSP script-src chrome-extension 2
23.04.24, 06:51:11 MESZ web_js 645 ERR eval violated CSP script-src chrome-extension 2
23.04.24, 06:50:02 MESZ web_js 645 ERR eval violated CSP script-src chrome-extension 2
23.04.24, 06:49:31 MESZ web_js 1148 ERR eval violated CSP script-src chrome-extension 2
23.04.24, 06:49:29 MESZ web_js 1147 ERR eval violated CSP script-src chrome-extension 2
23.04.24, 06:49:26 MESZ web_js 1147 ERR eval violated CSP script-src chrome-extension 2
23.04.24, 06:37:17 MESZ web_js 11959 ERR eval violated CSP script-src chrome-extension 2
23.04.24, 06:37:14 MESZ web_js 11959 ERR eval violated CSP script-src chrome-extension 2
23.04.24, 06:35:09 MESZ web_php 16322 ERR Timed out waiting for msg /run/zm/zms-278999s.sock after waiting 5000 milliseconds /usr/share/zoneminder/www/ajax/stream.php 124
23.04.24, 06:35:08 MESZ web_js 16347 ERR eval violated CSP script-src chrome-extension 2
23.04.24, 06:35:04 MESZ zms_m1 16791 ERR fopen() for /var/log/zoneminder.log 23, error = Permission denied zm_logger.cpp 390
23.04.24, 06:35:04 MESZ zms 16791 ERR fopen() for /var/log/zoneminder.log 23, error = Permission denied zm_logger.cpp 390
23.04.24, 06:35:04 MESZ web_php 11962 ERR Timed out waiting for msg /run/zm/zms-278999s.sock after waiting 5000 milliseconds /usr/share/zoneminder/www/ajax/stream.php 124
23.04.24, 06:34:59 MESZ zms_m1 16788 ERR fopen() for /var/log/zoneminder.log 23, error = Permission denied zm_logger.cpp 390
23.04.24, 06:34:59 MESZ zms 16788 ERR fopen() for /var/log/zoneminder.log 23, error = Permission denied zm_logger.cpp 390
23.04.24, 06:34:59 MESZ web_php 16346 ERR Timed out waiting for msg /run/zm/zms-278999s.sock after waiting 5000 milliseconds /usr/share/zoneminder/www/ajax/stream.php 124
23.04.24, 06:34:53 MESZ zms_m1 16784 ERR fopen() for /var/log/zoneminder.log 23, error = Permission denied zm_logger.cpp 390
23.04.24, 06:34:53 MESZ zms 16784 ERR fopen() for /var/log/zoneminder.log 23, error = Permission denied zm_logger.cpp 390
23.04.24, 06:34:53 MESZ web_php 11961 ERR Timed out waiting for msg /run/zm/zms-278999s.sock after waiting 5000 milliseconds /usr/share/zoneminder/www/ajax/stream.php 124
23.04.24, 06:34:48 MESZ zms_m1 16779 ERR fopen() for /var/log/zoneminder.log 23, error = Permission denied zm_logger.cpp 390
23.04.24, 06:34:48 MESZ zms 16779 ERR fopen() for /var/log/zoneminder.log 23, error = Permission denied zm_logger.cpp 390
23.04.24, 06:34:48 MESZ web_php 16107 ERR Timed out waiting for msg /run/zm/zms-278999s.sock after waiting 5000 milliseconds /usr/share/zoneminder/www/ajax/stream.php 124
23.04.24, 06:34:42 MESZ zms_m1 16775 ERR fopen() for /var/log/zoneminder.log 23, error = Permission denied zm_logger.cpp 390
23.04.24, 06:34:42 MESZ zms 16775 ERR fopen() for /var/log/zoneminder.log 23, error = Permission denied zm_logger.cpp 390
23.04.24, 06:34:41 MESZ zms_m1 16772 ERR fopen() for /var/log/zoneminder.log 23, error = Permission denied zm_logger.cpp 390
23.04.24, 06:34:41 MESZ zms 16772 ERR fopen() for /var/log/zoneminder.log 23, error = Permission denied zm_logger.cpp 390

zoneminder logfile:

23.04.24, 06:31:45 MESZ.171487 web_php[16107].DBG [10.49.100.2] [CORS: NO origin] at /usr/share/zoneminder/www/includes/functions.php line 89
23.04.24, 06:31:45 MESZ.172951 web_php[16107].DBG [10.49.100.2] [View: options Request: Action: User: admin] at /usr/share/zoneminder/www/index.php line 186
23.04.24, 06:31:45 MESZ.503606 web_php[16107].DBG [10.49.100.2] [Array
(
[__csrf_magic] => key:5d69c2eeb1bcf5284f94a898ec06eb6001abe48d,1713846705
[view] => request
[request] => log
[task] => create
[level] => ERR
[message] => eval%20violated%20CSP%20script-src
[browser] => Array
(
[name] => Chrome
[version] => 124.0.0.0
[platform] => Windows
)

[file] => chrome-extension
[line] => 2

)] at /usr/share/zoneminder/www/index.php line 33

I found this: #3340 . Do I have the same issue?

from zoneminder.

schnudd31do3 avatar schnudd31do3 commented on July 1, 2024

No errors, only waiting for responding.
image

from zoneminder.

schnudd31do3 avatar schnudd31do3 commented on July 1, 2024

I observed, restarting the zoneminder service causes about 4 seconds of delay while the website is kept open. Restarting the apache2 service causes a delay of about 36 seconds, where I have to refresh the website immediately after restarting the apache2 service.

from zoneminder.

ovargasp avatar ovargasp commented on July 1, 2024

Have you tried to access the monitor using the browser in "safe mode", that may give you an idea if is related to some browser extesion... another thing you can check is if the CPU usage spikes when you open the monitor view, that can cause a delay.

from zoneminder.

schnudd31do3 avatar schnudd31do3 commented on July 1, 2024
  1. I dont know how to activate "safe mode". I am not running it in a docker container.
  2. When opening with "mode=single", the picture ist shown immediately and by presing F5 as fast as I want, the video image ist updated without any delay. But using "mode=jpeg", the delay is there. Because cgi-bin/zms is a compiled file, I am not able to dig in, what the delay causes. I guess, that zms is buffering some frames before it shows the video image. An indication for that is that when stopping the zoneminder service, the video image continues for a few seconds.
  3. I am using 4 core with 2 CPU per socket and 4GB RAM. vSphere shows no spike when opening the URL and is running on about 15% of CPU load. So I dont beleve that there is a lack of power.
  4. I have this browser extension errors independend of Edge, Chrome and Forefox

Can you confirm 2. from above? If so, where can I disable this behaviour? I know for a fact that this behavior wasn't the case until some previous versions and I did not change my hardware

from zoneminder.

connortechnology avatar connortechnology commented on July 1, 2024

The answers will be in the zms logs. The CSP stuff is caused by some chrome extension. I don't think it is related. However you may try turning off extensions one by one until that goes away.

A bigger issue is a misconfig on your logging path.. it can't write to /var/log/zoneminder.log. This is a strange value. Logs should be in /var/log/zm/ so something is strange with your config. Please check /etc/zm/conf.d/01-system-paths.conf

from zoneminder.

connortechnology avatar connortechnology commented on July 1, 2024

zms does not buffer frames. It waits for zmc to have captured another image, then sounds that out. There is a weird thing with Chrome where it doesn't display an image until it gets a second one. For this reason we actually sometimes send the same image twice. However I don't think this is relevant.

from zoneminder.

schnudd31do3 avatar schnudd31do3 commented on July 1, 2024

I checked this 01-system-paths.conf. I had the path configured here: ZM_PATH_LOGS=/var/log/zm. Perhaps it was an old error.

I have the chrome extension error on EACH browser (edge, chrome, firefox):
30.04.24, 08:58:24 MESZ | web_js | 76758 | ERR | eval violated CSP script-src | chrome-extension | 2

You said "It waits for zmc to have captured another image". But why can I capture immediately images as fast as I want by using the single mode and pressing F5? Where can check, on what zns is waiting for when using the jpeg mode?"

from zoneminder.

connortechnology avatar connortechnology commented on July 1, 2024

I just saw this problem today on a support call. Despite my best efforts to figure it out, so far I am stumped. They had two identical servers and one did it while the other did not. Independent of browser. zms logs clearly show images being sent, but the browser refuses to display them for around a minute. Also seems to not receive sigpipe when we browse away. Very puzzling. Logs all green.

from zoneminder.

schnudd31do3 avatar schnudd31do3 commented on July 1, 2024

Thanks, that you could confirm my observations. "logs all green." yes they are. I am pretty sure that in former versions of zms, it does not have this issue. But I can not remember since when it comes up.

from zoneminder.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.