no h264 passthrough written, images captured

Forum for questions and support relating to the 1.31.x releases only.
Locked
op3lkjmsdfew
Posts: 1
Joined: Thu Mar 22, 2018 9:12 pm

no h264 passthrough written, images captured

Post by op3lkjmsdfew »

I am running zoneminder 1.31.1~20180 installed by package from iconnor-zoneminder-master installed on ubuntu 16.04.4 in virtual machine on a dell r710 server.

I have 2 hikvision DS-2CD2042WD-I doing modect at 1920x1080 6fps.

I have them sourced as libvlc with rtsp://admin:redacted@redacted:554/Streaming/Channels/101?transportmode=unicast&profile=Profile_1 ( came from onvif live view on a windows box )


Filesystem Size Used Avail Use% Mounted on
udev 46G 0 46G 0% /dev
tmpfs 9.1G 8.7M 9.0G 1% /run
/dev/vda1 46G 6.7G 37G 16% /
tmpfs 46G 5.8G 40G 13% /dev/shm
tmpfs 5.0M 0 5.0M 0% /run/lock
tmpfs 46G 0 46G 0% /sys/fs/cgroup
tmpfs 9.1G 0 9.1G 0% /run/user/1000

total used free shared buff/cache available
Mem: 90G 1.6G 81G 5.8G 6.6G 82G
Swap: 4.0G 0B 4.0G

10 cpu cores
processor : 0
vendor_id : GenuineIntel
cpu family : 6
model : 44
model name : Westmere E56xx/L56xx/X56xx (Nehalem-C)
stepping : 1
microcode : 0x1
cpu MHz : 2660.000
cache size : 4096 KB
physical id : 0
siblings : 1
core id : 0
cpu cores : 1
apicid : 0
initial apicid : 0
fpu : yes
fpu_exception : yes
cpuid level : 11
wp : yes
flags : fpu de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 syscall nx lm constant_tsc rep_good nopl pni pclmulqdq ssse3 cx16 sse4_1 sse4_2 x2apic popcnt aes hypervisor lahf_lm retpoline kaiser
bugs : cpu_meltdown spectre_v1 spectre_v2
bogomips : 5320.00
clflush size : 64
cache_alignment : 64
address sizes : 40 bits physical, 48 bits virtual
power management:


Everything is working pretty well, box load stays around 1.5 with 2 cameras. I would like to however record the h264 passthrough video instead of just the jpg stills for alarmed events so I enabled the h264 storage option

I enabled the option and now whenever I go to any events captured by that camera i'm presented with a black screen that says 'The video could not be loaded, either because the server or noetwork failed or because the format is not supported'

If i click into the frames or stills i can see those are fine
attempting to download mp4 results in a 404

going to my hard disk I look for any mp4/avi files in the events directory, and there are none only jpgs

so it seems the database thinks a file exists, but no file exists, and i cannot see any errors in the log output even with debuglog turned on that pertain.

If i switch to x264 encoding, i get video files but they are horribly broken stuttery and the captured jpg assemblage is far superior.

Is there any way to get this h264 passthrough working? the camera already outputs h264 so it seems stupid to waste cpu cycles re-encoding it.
User avatar
zd59
Posts: 102
Joined: Wed Jan 18, 2017 1:39 pm
Location: EU - Slovenia

Re: no h264 passthrough written, images captured

Post by zd59 »

ZM-1.31.44 GIT 11. july 2018
Slackware64-14.2
Camera source ffmpeg, TCP, 704 X 576 (PAL, 32 color)

Exact the same case.
Camera passthrough recording WORKED somewhere around january - march 2018 later no more.
Save JPEGs: enabled (not disabled) - works: events are saved as NNNNN-capture.jpg sequences, and watchable by web browser.

Save JPEGs: disabled
Video writer: H264 Camera passthrough
Do not work. ZM creates subfolder and records one JPG named snapshot.jpg, no video file on entire hard disk
/var/log/zm/apache-access.log: no warnings & errors recorded

Zoneminder LOG:
2018-07-12 11:00:52.411857 zmc_m1 8799 INF Opening video storage stream format: mp4 zm_videostore.cpp 54
2018-07-12 11:00:52.016235 zmc_m1 8799 ERR Could not open out file '': No such file or directory zm_videostore.cpp 314
2018-07-12 11:00:52.014106 zmc_m1 8799 WAR Could not create video storage stream as no out ctx could be assigned based on filename: Invalid argument zm_videostore.cpp 61
2018-07-12 11:00:52.011633 zmc_m1 8799 INF Opening video storage stream format: mp4 zm_videostore.cpp 54
/var/log/zm/apache-error.log:
[Thu Jul 12 10:59:17.848157 2018] [:error] [pid 8719:tid 140647898019584] [client 127.0.0.1:55260] PHP Warning: filesize(): stat failed for /var/lib/zoneminder/events/1/2018-07-12/6/6-video.mp4 in /var/www/htdocs/zm/views/view_video.php on line 58, referer: http://localhost/?view=event&eid=6&filt ... c=1&page=1
Of above Zoneminder log shows interesting warning in line three (Invalid argument zm_videostore.cpp 61).

Would like to help the developers to debug this, so I need some advice regarding ZM logging settings, as they are default on my system.
Or better, any hints to set up ZM to be able to record video stream directly.
For testing new features on development branch would be very helpful to have some settings hints/manual regarding, instead of searching/asking on the forum.
User avatar
iconnor
Posts: 2900
Joined: Fri Oct 29, 2010 1:43 am
Location: Toronto
Contact:

Re: no h264 passthrough written, images captured

Post by iconnor »

That's pretty weird.

Go to options -> Logging

Make LOG_LEVEL_FILE => Debug
Check LOG_DEBUG
Make LOG_DEBUG_LEVEL => 4
Clear LOG_DEBUG_FILE

After restart there should be a file called /var/log/zm/zmc_m(the monitor id #).log
User avatar
zd59
Posts: 102
Joined: Wed Jan 18, 2017 1:39 pm
Location: EU - Slovenia

Re: no h264 passthrough written, images captured

Post by zd59 »

Hi Issac !

Thank you for a reply.
I've compiled ZM again, GIT source from today, last one 0d75586 from you.
Attached is compressed zmc_m1.log, if you are willing to review it. I can not found a clear pointing to a cause of problem.

And I discovered, as I installed a new package, that GIT source from today interprete data from .../zm.conf differently from GIT two days before:
# Order matters. This alias must come first.
Alias /cache "/var/cache/zoneminder"
Last GIT works with above, but not with "/zm" before "/cache" - "/zm/cache", but opose GIT two days old:
Last GIT, correct web gui with "/zm/cache", otherwise do not work
two days old GIT correct web gui with "/cache", otherwise do not work
Do not know, who is responsible, but please keep one of the versions permanent.

Regards
Attachments
zmc_m1.zip
(45.1 KiB) Downloaded 231 times
Locked