No feed for certain RTSP cameras

Forum for questions and support relating to the 1.34.x releases only.
Post Reply
monty617
Posts: 5
Joined: Thu Jul 23, 2020 10:52 pm

No feed for certain RTSP cameras

Post by monty617 »

I have a few cameras listed below. The Amcrest was the first one I setup and it worked fine right off the bat. The other two will not work no matter what and I have tried everything. They work via VLC and I have confirmed with other users that have these working that the settings are correct. The only difference I can see is that the Amcrest is wired and the others are wireless but I have confirmed network looks good (IE - ping, telnet 554 etc). I do get some errors in the logs but none have steered me to any useful solutions. I installed on a Rasp Pi 4 following the Debian Buster instructions here: https://wiki.zoneminder.com/Debian_10_B ... om_ZM_Repo.

- Amcrest POE
- Hikvision DB1 Doorbell Cam
- Wyze Cam 2

Part of error capture:

2020-07-23 18:59:49 zmc_m4 2220 FAT No RTSP sources zm_remote_camera_rtsp.cpp 158
2020-07-23 18:59:49 zmwatch 899 INF Restarting capture daemon for FrontDoor, shared data not valid zmwatch.pl
2020-07-23 18:59:49 zmwatch 899 ERR Memory map file '/dev/shm/zm.mmap.3' should have been 1160 but was instead 0 zmwatch.pl
2020-07-23 18:59:49 zma_m1 977 INF SideYard: 7000 - Analysing at 10.00 fps zm_monitor.cpp 1301
2020-07-23 18:59:47 zmc_m1 767 INF SideYard: images:7000 - Capturing at 10.00 fps, capturing bandwidth 69351bytes/sec zm_monitor.cpp 2544
2020-07-23 18:59:45 zms_m3 2232 ERR Got empty memory map file size 0, is the zmc process for this monitor running? zm_monitor.cpp 578
2020-07-23 18:59:45 zms_m3 2232 ERR Unable to connect to monitor id 3 for streaming zm_stream.cpp 53
2020-07-23 18:59:45 zms_m3 2232 ERR Unable to connect to zmc process for monitor 3 zms.cpp 257
2020-07-23 18:59:44 web_php 2186 ERR Socket /var/run/zm/zms-062517s.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 2177
2020-07-23 18:59:44 web_js 626 ERR getStreamCmdResponse stream error: Socket /var/run/zm/zms-062517s.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
2020-07-23 18:59:42 zms_m3 2228 ERR Unable to connect to zmc process for monitor 3 zms.cpp 257
2020-07-23 18:59:42 zms_m3 2228 ERR Unable to connect to monitor id 3 for streaming zm_stream.cpp 53
2020-07-23 18:59:42 zms_m3 2228 ERR Got empty memory map file size 0, is the zmc process for this monitor running? zm_monitor.cpp 578
2020-07-23 18:59:41 zmc_m4 2222 INF Received new Content-Base in DESCRIBE response header. Updated device Url to: 'rtsp://192.168.0.242/live/' zm_rtsp.cpp 365
2020-07-23 18:59:41 zmc_m4 2222 ERR Response parse failure, 2 bytes follow zm_rtsp.cpp 75
2020-07-23 18:59:41 zmc_m4 2222 ERR 2: 24 01 zm_rtsp.cpp 77
2020-07-23 18:59:41 web_js 626 ERR getStreamCmdResponse stream error: Socket /var/run/zm/zms-842493s.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
2020-07-23 18:59:41 web_php 626 ERR Socket /var/run/zm/zms-842493s.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 2177
bbunge
Posts: 2930
Joined: Mon Mar 26, 2012 11:40 am
Location: Pennsylvania

Re: No feed for certain RTSP cameras

Post by bbunge »

Best thing to do with a Pi install is start off with a low cam resolution, get it to work then go higher. The Pi is not very powerful.
In VLC you need to check the actual resolution: Use VLC (Tools, Media Information, Codec) to check camera Display Resolution. Often this is different from what you expect and this is what you need to use in Zoneminder. If the resolution is too high you can use a value 1/2 or 1/4 of what was reported by VLC.
User avatar
iconnor
Posts: 2881
Joined: Fri Oct 29, 2010 1:43 am
Location: Toronto
Contact:

Re: No feed for certain RTSP cameras

Post by iconnor »

Also don't use the remote monitor type. Use the ffmpeg type. That way it can use the hardware decoder on your pi.
tedfinnegan
Posts: 1
Joined: Tue Jul 28, 2020 4:44 am

Re: No feed for certain RTSP cameras

Post by tedfinnegan »

The Pi is not very powerful. So start with a low cam resolution, get it to work, then go higher.
monty617
Posts: 5
Joined: Thu Jul 23, 2020 10:52 pm

Re: No feed for certain RTSP cameras

Post by monty617 »

Thanks for the suggestions. I've tried both remote and ffmpeg without any luck. I've also confirmed that the settings I'm using have worked for others. Also I previously did check resolutions and tried lowest with a single camera. Haven't had any luck. Thinking I may try a reinstall, though not that excited about starting over
User avatar
iconnor
Posts: 2881
Joined: Fri Oct 29, 2010 1:43 am
Location: Toronto
Contact:

Re: No feed for certain RTSP cameras

Post by iconnor »

How about you switch to ffmpeg, and then turn on debug logging, and post the resulting logs here?

Re-installing isn't going to change anything.
monty617
Posts: 5
Joined: Thu Jul 23, 2020 10:52 pm

Re: No feed for certain RTSP cameras

Post by monty617 »

I did a reinstall of 1.32 to see if the older stable version would work. No go still of course. I did however have some success with the Hikvision by using the lower resolution substream. So it does seem like there may be limitations with the Pi. The Wyze cam doesn't have any lower resolution substreams so not sure what to do there. Even if I specify lower resolutions with the other cameras on the higher resolution stream they fail as well. So is there some way to force the capture to be at a lower resolution and fix the issue with the Wyze cam? Excerpts from the debug log for this camera below:

08/03/20 14:46:36.576873 zmc_m2[1359].DB1-zm_monitor.cpp/551 [Unable to map file /dev/shm/zm.mmap.2 (18437504 bytes) to locked memory, trying unlocked]
08/03/20 14:46:36.577350 zmc_m2[1359].DB1-zm_monitor.cpp/555 [Mapped file /dev/shm/zm.mmap.2 (18437504 bytes) to unlocked memory]
08/03/20 14:46:36.645859 zmc_m2[1359].DB1-zm_monitor.cpp/486 [Monitor BackYard has function 3]
08/03/20 14:46:36.646400 zmc_m2[1359].DB1-zm_monitor.cpp/487 [Monitor BackYard LBF = '%N - %Y-%m-%d %H:%M:%S %z', LBX = 0, LBY = 0, LBS = 1]
08/03/20 14:46:36.646795 zmc_m2[1359].DB1-zm_monitor.cpp/488 [Monitor BackYard IBC = 20, WUC = 0, pEC = 0, PEC = 5, EAF = 1, FRI = 100, RBP = 6, ARBP = 6, FM = 0]
08/03/20 14:46:36.647380 zmc_m2[1359].DB1-zm_zone.cpp/862 [Got 1 zones for monitor BackYard]
08/03/20 14:46:36.654631 zmc_m2[1359].INF-zmc.cpp/223 [Starting Capture version 1.32.3]
08/03/20 14:46:36.659933 zmc_m2[1359].INF-zm_ffmpeg_camera.cpp/163 [Priming capture from rtsp://user:pass@192.168.0.242/live]
08/03/20 14:46:36.664843 zmc_m2[1359].DB1-zm_ffmpeg_camera.cpp/344 [Calling avformat_open_input for rtsp://user:pass@192.168.0.242/live]
08/03/20 14:46:36.749331 zmc_m2[1359].DB1-zm_ffmpeg_camera.cpp/376 [Opened input]
08/03/20 14:46:36.749979 zmc_m2[1359].INF-zm_ffmpeg_camera.cpp/378 [Stream open rtsp://user:pass@192.168.0.242/live, parsing streams...]
08/03/20 14:46:38.608818 zmc_m2[1359].DB1-zm_ffmpeg_camera.cpp/505 [Success finding decoder (h264_mmal)]
08/03/20 14:46:38.611206 zmc_m2[1359].DB1-zm_ffmpeg_camera.cpp/514 [Video Found decoder h264_mmal]
08/03/20 14:46:38.612074 zmc_m2[1359].DB1-zm_ffmpeg.cpp/267 [Dumping stream index i(0) index(0)]
08/03/20 14:46:38.612861 zmc_m2[1359].DB1-zm_ffmpeg.cpp/272 [ Stream #0:0]
08/03/20 14:46:38.613677 zmc_m2[1359].DB1-zm_ffmpeg.cpp/280 [, frames:28, timebase: 1/90000]
08/03/20 14:46:38.614490 zmc_m2[1359].DB1-zm_ffmpeg.cpp/282 [: Video: h264 (Main), yuv420p(progressive), 1920x1080]
08/03/20 14:46:38.615401 zmc_m2[1359].DB1-zm_ffmpeg.cpp/227 [10 fps, ]
08/03/20 14:46:38.616209 zmc_m2[1359].DB1-zm_ffmpeg.cpp/229 [90k stream tb numerator , ]
08/03/20 14:46:38.617005 zmc_m2[1359].DB1-zm_ffmpeg.cpp/227 [20 codec time base:]
08/03/20 14:46:38.617859 zmc_m2[1359].DB1-zm_ffmpeg.cpp/337 []
08/03/20 14:46:38.618656 zmc_m2[1359].DB1-zm_ffmpeg_camera.cpp/521 [Calling avcodec_open2]
08/03/20 14:46:38.784619 zmc_m2[1359].DB1-zm_ffmpeg_camera.cpp/544 [HWACCEL not in use]
08/03/20 14:46:38.785807 zmc_m2[1359].DB1-zm_ffmpeg_camera.cpp/556 [Audio Found decoder]
08/03/20 14:46:38.786704 zmc_m2[1359].DB1-zm_ffmpeg.cpp/267 [Dumping stream index i(1) index(0)]
08/03/20 14:46:38.787458 zmc_m2[1359].DB1-zm_ffmpeg.cpp/272 [ Stream #0:1]
08/03/20 14:46:38.787582 zmc_m2[1359].DB1-zm_ffmpeg.cpp/280 [, frames:12, timebase: 1/8000]
08/03/20 14:46:38.787705 zmc_m2[1359].DB1-zm_ffmpeg.cpp/282 [: Audio: pcm_alaw, 8000 Hz, 1 channels, s16, 64 kb/s]
08/03/20 14:46:38.787796 zmc_m2[1359].DB1-zm_ffmpeg.cpp/337 []
08/03/20 14:46:38.787880 zmc_m2[1359].DB1-zm_ffmpeg_camera.cpp/563 [Calling avcodec_open2]
08/03/20 14:46:38.788038 zmc_m2[1359].DB1-zm_ffmpeg_camera.cpp/600 [Calling sws_isSupportedInput]
08/03/20 14:46:38.808893 zmc_m2[1359].WAR-zm_ffmpeg_camera.cpp/627 [Monitor dimensions are 640x360 but camera is sending 1920x1080]
08/03/20 14:46:38.815258 zmc_m2[1359].WAR-zm_ffmpeg_camera.cpp/900 [Unable to receive frame 0: Resource temporarily unavailable, continuing]
08/03/20 14:46:39.117910 zmc_m2[1359].ERR-zm_ffmpeg_camera.cpp/875 [Unable to send packet at frame 0: Unknown error occurred, continuing]
SteveGilvarry
Posts: 494
Joined: Sun Jun 29, 2014 1:12 pm
Location: Melbourne, AU

Re: No feed for certain RTSP cameras

Post by SteveGilvarry »

[Monitor dimensions are 640x360 but camera is sending 1920x1080]
Check your setup on Source tab of the monitor for Capture Resolution 1920 1080
Production Zoneminder 1.37.x (Living dangerously)
Random Selection of Cameras (Dahua and Hikvision)
monty617
Posts: 5
Joined: Thu Jul 23, 2020 10:52 pm

Re: No feed for certain RTSP cameras

Post by monty617 »

Yes, that was my point in the previous response. If I put the resolution that high it doesn't work, likely due to the limitations of the raspberry pi. Not sure if I'm out of luck without a reduced resolution stream being available, though I'm not hitting any of the resource limits on the rpi.
dougmccrary
Posts: 1172
Joined: Sat Aug 31, 2019 7:35 am
Location: San Diego

Re: No feed for certain RTSP cameras

Post by dougmccrary »

If the 1920x1080 is the amcrest, did you try /h264Preview_01_sub ?

I don't have an amcrest, but almost all of mine have two streams...
monty617
Posts: 5
Joined: Thu Jul 23, 2020 10:52 pm

Re: No feed for certain RTSP cameras

Post by monty617 »

No it's the Wyze I'm having trouble with
dougmccrary
Posts: 1172
Joined: Sat Aug 31, 2019 7:35 am
Location: San Diego

Re: No feed for certain RTSP cameras

Post by dougmccrary »

From what I can see, you're far from alone. Looks like the best option is to forget it.

I'm not sure how it impacts processing time, but I have a couple that put out 1920x1080, but I run 'em all at 640x352, for montage aesthetics. Gives those errors, but doesn't seem to cause actual problems.
Post Reply