hjdhjd / homebridge-unifi-protect

:video_camera: Complete HomeKit integration for all UniFi Protect device types with full support for most features including HomeKit Secure Video, and more. https://homebridge.io
Other
1.45k stars 93 forks source link

Possible cause of #1061 (Author's note: nope.). #1066

Closed CMosUK1 closed 5 months ago

CMosUK1 commented 5 months ago

Homebridge UniFi Protect Version

v6.22.0

Homebridge Platform and OS

Linux

Homebridge Version

v4.56.2

Node Version

v20.12.2

UniFi OS Version

v3.2.12

UniFi Protect Controller Version

issue seen with v3.0.26 and v3.0.22 but not v2.11.21

Describe the problem

First of all, thank you for the time and effort you have put into this plugin!

I was having an issue similar to issue #1061 . With my problem the HKSV recordings were still working along with the thumbnail image and the logs reflected that however, if you requested a live stream it failed with ffmpeg errors suggesting it could not access the stream.

This seems to be an issue with v3 of Unifi Protect as to resolve the issue I downgraded to version v2.11.21 from v3.0.26 through v3.0.22. Now I have downgraded to the highest version of 2 I am aware of (v2.11.21) live streaming, HKSV and thumbnails working are working as expected.

Could it be that version 3 of UniFi Protect only allows one stream at a time? I'm using a UCK2+.

I would be interested to know whether downgrading UniFi Protect would fix @nolan2306's problem as well. The instructions I followed to downgrade Unifi Protect can be found in this Community Question but I substituted the version number as above: https://community.ui.com/questions/How-to-downgrade-to-UniFi-Protect-1-15-0-for-Apple-TV-Support/f35f500b-6cba-487f-a09c-d2b7a9806b6e

Temporarily I will stay at version v2.11.21 and have turned off Application Auto-Update.

I hope this report is useful and many thanks once again.

Homebridge HBUP JSON configuration

See issue #1061

Relevant log output

[05:51:47] [homebridge-unifi-protect] [Redacted - Camera Name] [G3 Bullet]: FFmpeg process ended unexpectedly with an exit code of 1.
[05:51:47] [homebridge-unifi-protect] [Redacted - Camera Name] [G3 Bullet]: FFmpeg (6.0-homebridge-alpine-armv7l-static) command that errored out was: /var/lib/homebridge/node_modules/homebridge-unifi-protect/node_modules/ffmpeg-for-homebridge/ffmpeg -hide_banner -nostats -fflags +discardcorrupt -probesize 16384 -max_delay 500000 -r 30 -rtsp_transport tcp -i rtsps://[Redacted - IP address and port]/[Redacted - HASH]?enableSrtp -map 0:v:0 -vcodec copy -payload_type 99 -ssrc 7748388 -f rtp -srtp_out_suite AES_CM_128_HMAC_SHA1_80 -srtp_out_params [Redacted - HASH] srtp://[Redacted - IP address and port]?rtcpport=[Redacted - port]&pkt_size=564 -map 0:a:0? -acodec libfdk_aac -afterburner 1 -eld_sbr 1 -eld_v2 1 -profile:a 38 -flags +global_header -f null -ar 24k -b:a 24k -bufsize 48k -ac 1 -payload_type 110 -ssrc 7626485 -f rtp -srtp_out_suite AES_CM_128_HMAC_SHA1_80 -srtp_out_params [Redacted - HASH] srtp://[Redacted - IP address and port]?rtcpport=[Redacted - port]&pkt_size=188
[05:51:47] [homebridge-unifi-protect] [Redacted - Camera Name] [G3 Bullet]: [tls @ 0xf7c16c90] IO error: End of file
[05:51:47] [homebridge-unifi-protect] [Redacted - Camera Name] [G3 Bullet]: rtsps://[Redacted - IP address and port]/[Redacted - HASH]?enableSrtp: End of file
[05:51:47] [homebridge-unifi-protect] [Redacted - Camera Name] [G3 Bullet]: Stopped video streaming session.

Acknowledgment that you are only running UniFi OS and UniFi Protect releases from the Ubiquiti Official release channel

hjdhjd commented 5 months ago

Thanks for the report and the compliments!

TL;DR: nope - Protect allows multiple streams just fine, that's not the issue. The v3 series of Protect firmwares from Ubiquiti is buggy on occasion - some releases are better than others. If downgrading over the long-term was a solution that worked for you, terrific. It's not a long-term answer I suspect for most.

Thanks for the report and the creative workaround. I'm hoping an upcoming release from Ubiquiti addresses their current bugginess...it's been a bit inconsistent of late.

github-actions[bot] commented 4 months ago

This issue is locked to prevent necroposting on closed issues. Please create a new issue for related support requests, bug reports, or feature suggestions.