AirenSoft / OvenMediaEngine

OvenMediaEngine (OME) is a Sub-Second Latency Live Streaming Server with Large-Scale and High-Definition. #WebRTC #LLHLS
https://OvenMediaEngine.com/ome
GNU Affero General Public License v3.0
2.53k stars 1.06k forks source link

could not create offer - RTSP Pull mode #1516

Closed getroot closed 6 months ago

getroot commented 7 months ago

Discussed in https://github.com/AirenSoft/OvenMediaEngine/discussions/1498

Originally posted by **AdamDudley** January 13, 2024 Version: Docker 0.16.3 on Windows Host Summary: Attempting to stream from CCTV Cameras via RTSP and recive data in demo.ovenplayer.com, logs suggest RTSP streams all ok, but can never connect, always responds as though I've requested the wrong URL. Possible (Open) Duplicate: https://github.com/AirenSoft/OvenMediaEngine/discussions/1433 Steps I've tried: 1. I've ensured my setup 'works' with WebRTC Input and can play fine using demo.ovenplayer.com (security cert installed etc.) (must admit, wow, WebRTC is fast! on my local only setup, around 10ms latency vs 2-2.2 seconds with llhls) 2. tried both 'edge' and 'origin' config, I only have 1 docker running OME 3. attempted multiple different cameras, and ensured they are streaming as h.264 4. all configurations work in VLC from the same windows host. any assistance appreciated, I can put the nvr online for you to access if you'd like. Many thanks ------------ Server.xml (passwords redacted, but 100% work in VLC) ------------ OvenMediaEngine edge * false true true false 2 ${env:OME_API_PORT:8081} 1 1 1 ${env:OME_RTMP_PROV_PORT:1935} 1 ${env:OME_SRT_PROV_PORT:9999} 1 ${env:OME_WEBRTC_SIGNALLING_PORT:3333} ${env:OME_WEBRTC_SIGNALLING_TLS_PORT:3334} 1 ${env:OME_HOST_IP:*}:${env:OME_WEBRTC_CANDIDATE_PORT:10000-10004/udp} ${env:OME_HOST_IP:*}:${env:OME_WEBRTC_TCP_RELAY_PORT:3478} true 1 ${env:OME_ORIGIN_PORT:9000} 1 ${env:OME_LLHLS_STREAM_PORT:3333} ${env:OME_LLHLS_STREAM_TLS_PORT:3334} 1 ${env:OME_WEBRTC_SIGNALLING_PORT:3333} ${env:OME_WEBRTC_SIGNALLING_TLS_PORT:3334} 1 ${env:OME_WEBRTC_CANDIDATE_IP:*}:${env:OME_WEBRTC_CANDIDATE_PORT:10000-10004/udp} ${env:OME_WEBRTC_CANDIDATE_IP:*}:${env:OME_WEBRTC_TCP_RELAY_PORT:3478} true 1 * cert.crt cert.key username:password * default ovenmediaengine.com * cert.crt cert.key 30000 43200000 /app/camera1_sub rtsp admin:redacted@192.168.2.135:554/Streaming/Channels/102 /app/camera4_sub rtsp admin:redacted@192.168.2.135:554/Streaming/Channels/402 /app/camera1_main rtsp redacted:redacted@192.168.2.135:554/Streaming/Channels/101 /app/camera4_main rtsp redacted:redacted@192.168.2.135:554/Streaming/Channels/401 * app live false false bypass_stream ${OriginStreamName} 30000 * /opt/ovenmediaengine/media /opt/ovenmediaengine/media 1 8 30000 false false false true 0.5 1.5 6 10 * ------------ log file from fresh start, then I try to connect to wss://192.168.2.97:3334/app/camera1_sub ------------ [2024-01-13 11:13:40.518] I [OvenMediaEngine:1] Config | config_manager.cpp:239 | Trying to set logfile in directory... (/var/log/ovenmediaengine) [2024-01-13 11:13:40.521] I [OvenMediaEngine:1] Config | config_manager.cpp:261 | Trying to load configurations... (origin_conf/Server.xml) [2024-01-13 11:13:40.542] W [OvenMediaEngine:1] Config | output_profiles.h:41 | The 'HardwareAcceleration' option is deprecated. Please use the 'HWAccels' option. [2024-01-13 11:13:40.551] I [OvenMediaEngine:1] OvenMediaEngine | banner.cpp:23 | OvenMediaEngine v0.16.3 ((From archive)) is started on [12c1a7410c4e] (Linux x86_64 - 5.10.102.1-microsoft-standard-WSL2, #1 SMP Wed Mar 2 00:30:59 UTC 2022) [2024-01-13 11:13:40.552] I [OvenMediaEngine:1] OvenMediaEngine | banner.cpp:27 | With modules: [2024-01-13 11:13:40.552] I [OvenMediaEngine:1] OvenMediaEngine | banner.cpp:28 | FFmpeg 5.0.1 [2024-01-13 11:13:40.553] I [OvenMediaEngine:1] OvenMediaEngine | banner.cpp:29 | Configuration: --prefix=/opt/ovenmediaengine --extra-cflags='-I/opt/ovenmediaengine/include ' --extra-ldflags='-L/opt/ovenmediaengine/lib -Wl,-rpath,/opt/ovenmediaengine/lib ' --extra-libs=-ldl --disable-everything --disable-programs --disable-avdevice --disable-dwt --disable-lsp --disable-lzo --disable-faan --disable-pixelutils --enable-shared --enable-zlib --enable-libopus --enable-libvpx --enable-libfdk_aac --enable-libopenh264 --enable-openssl --enable-network --enable-libsrt --enable-dct --enable-rdft --disable-nvdec --disable-nvdec --disable-vaapi --disable-vdpau --disable-cuda-llvm --disable-cuvid --disable-ffnvcodec --enable-ffmpeg --enable-encoder='libvpx_vp8,libopus,libfdk_aac,libopenh264,mjpeg,png' --enable-decoder='aac,aac_latm,aac_fixed,mp3float,mp3,h264,hevc,opus,vp8' --enable-parser='aac,aac_latm,aac_fixed,h264,hevc,opus,vp8' --enable-protocol='tcp,udp,rtp,file,rtmp,tls,rtmps,libsrt' --enable-demuxer='rtsp,flv,live_flv,mp4,mp3' --enable-muxer='mp4,webm,mpegts,flv,mpjpeg' --enable-filter='asetnsamples,aresample,aformat,channelmap,channelsplit,scale,transpose,fps,settb,asettb,format' [2024-01-13 11:13:40.553] I [OvenMediaEngine:1] OvenMediaEngine | banner.cpp:30 | libavformat: 59.16.100 [2024-01-13 11:13:40.554] I [OvenMediaEngine:1] OvenMediaEngine | banner.cpp:31 | libavcodec: 59.18.100 [2024-01-13 11:13:40.554] I [OvenMediaEngine:1] OvenMediaEngine | banner.cpp:32 | libavutil: 57.17.100 [2024-01-13 11:13:40.554] I [OvenMediaEngine:1] OvenMediaEngine | banner.cpp:33 | libavfilter: 8.24.100 [2024-01-13 11:13:40.555] I [OvenMediaEngine:1] OvenMediaEngine | banner.cpp:34 | libswresample: 4.3.100 [2024-01-13 11:13:40.555] I [OvenMediaEngine:1] OvenMediaEngine | banner.cpp:35 | libswscale: 6.4.100 [2024-01-13 11:13:40.556] I [OvenMediaEngine:1] OvenMediaEngine | banner.cpp:36 | SRT: 1.5.2 [2024-01-13 11:13:40.556] I [OvenMediaEngine:1] OvenMediaEngine | banner.cpp:37 | SRTP: libsrtp2 2.4.2 [2024-01-13 11:13:40.556] I [OvenMediaEngine:1] OvenMediaEngine | banner.cpp:38 | OpenSSL: OpenSSL 3.0.7 1 Nov 2022 [2024-01-13 11:13:40.557] I [OvenMediaEngine:1] OvenMediaEngine | banner.cpp:39 | Configuration: compiler: gcc -fPIC -pthread -m64 -Wa,--noexecstack -Wall -O3 -DOPENSSL_USE_NODELETE -DL_ENDIAN -DOPENSSL_PIC -DOPENSSL_BUILDING_OPENSSL -DNDEBUG [2024-01-13 11:13:40.557] I [OvenMediaEngine:1] OvenMediaEngine | banner.cpp:40 | JsonCpp: 1.9.3 [2024-01-13 11:13:40.558] I [OvenMediaEngine:1] OvenMediaEngine | banner.cpp:41 | jemalloc: 5.3.0-0-g54eaed1d8b56b1aa528be3bdd1877e59c56fa90c [2024-01-13 11:13:40.558] I [OvenMediaEngine:1] OvenMediaEngine | main.cpp:73 | Server ID : 72095fd3-0bc8-4835-a034-8fd5b7a78521 [2024-01-13 11:13:40.559] W [OvenMediaEngine:1] Socket | socket.cpp:1092 | [#5] [0x7fbf2e4341d0] Could not send data: -1 ([errno] Invalid argument (22)) [2024-01-13 11:13:40.559] W [OvenMediaEngine:1] OvenMediaEngine | main.cpp:98 | Could not resolve public IP address from stun server () [2024-01-13 11:13:40.560] I [OvenMediaEngine:1] OvenMediaEngine | main.cpp:109 | This host supports IPv4 only (reason: v6: Failed to bind(): [errno] Cannot assign requested address (99)[0]) [2024-01-13 11:13:40.566] I [OvenMediaEngine:1] OvenMediaEngine | main.cpp:126 | Trying to create MediaRouter... [2024-01-13 11:13:40.567] I [OvenMediaEngine:1] MediaRouter | mediarouter.cpp:40 | Mediarouter has been started. [2024-01-13 11:13:40.567] I [OvenMediaEngine:1] OvenMediaEngine | main.cpp:129 | Trying to create WebRTC Publisher... [2024-01-13 11:13:40.568] I [OvenMediaEngine:1] Signalling.P2P | rtc_p2p_manager.cpp:27 | P2P is disabled in the configuration [2024-01-13 11:13:40.573] I [OvenMediaEngine:1] HTTP.Server | http_server_manager.cpp:319 | WebRTC Publisher is listening on *:3333 (TLS: *:3334)... [2024-01-13 11:13:40.575] I [OvenMediaEngine:1] ICE | ice_port_manager.cpp:305 | ICE candidate found: 172.17.0.2:10000 [2024-01-13 11:13:40.576] I [OvenMediaEngine:1] ICE | ice_port_manager.cpp:305 | ICE candidate found: 172.17.0.2:10001 [2024-01-13 11:13:40.576] I [OvenMediaEngine:1] ICE | ice_port_manager.cpp:305 | ICE candidate found: 172.17.0.2:10002 [2024-01-13 11:13:40.576] I [OvenMediaEngine:1] ICE | ice_port_manager.cpp:305 | ICE candidate found: 172.17.0.2:10003 [2024-01-13 11:13:40.577] I [OvenMediaEngine:1] ICE | ice_port_manager.cpp:305 | ICE candidate found: 172.17.0.2:10004 [2024-01-13 11:13:40.584] I [OvenMediaEngine:1] ICE | ice_port.cpp:113 | ICE ports are listening on *:10004/UDP (0x7fbf2e538f10), *:10003/UDP (0x7fbf2e539210), *:10002/UDP (0x7fbf2e539510), *:10001/UDP (0x7fbf2e539810), *:10000/UDP (0x7fbf2e539b10) (for WebRTC Publisher) [2024-01-13 11:13:40.586] I [OvenMediaEngine:1] ICE | ice_port_manager.cpp:191 | TURN port is listening on *:3478/TCP (for WebRTC Publisher) [2024-01-13 11:13:40.586] I [OvenMediaEngine:1] Publisher | publisher.cpp:19 | WebRTC Publisher has been started. [2024-01-13 11:13:40.587] I [OvenMediaEngine:1] OvenMediaEngine | main.cpp:130 | Trying to create LLHLS Publisher... [2024-01-13 11:13:40.588] I [OvenMediaEngine:1] HTTP.Server | http_server_manager.cpp:319 | LLHLS Publisher is listening on *:3333 (TLS: *:3334)... [2024-01-13 11:13:40.588] I [OvenMediaEngine:1] Publisher | publisher.cpp:19 | LLHLS Publisher has been started. [2024-01-13 11:13:40.589] I [OvenMediaEngine:1] OvenMediaEngine | main.cpp:131 | Trying to create HLS Publisher... [2024-01-13 11:13:40.589] W [OvenMediaEngine:1] HLS | hls_publisher.cpp:38 | HLS Publisher is disabled by configuration [2024-01-13 11:13:40.590] I [OvenMediaEngine:1] OvenMediaEngine | main.cpp:132 | Trying to create MPEG-DASH Publisher... [2024-01-13 11:13:40.590] W [OvenMediaEngine:1] DASH | dash_publisher.cpp:36 | DASH Publisher is disabled by configuration [2024-01-13 11:13:40.591] I [OvenMediaEngine:1] OvenMediaEngine | main.cpp:133 | Trying to create Low-Latency MPEG-DASH Publisher... [2024-01-13 11:13:40.591] W [OvenMediaEngine:1] LLDASH | cmaf_publisher.cpp:39 | LLDASH Publisher is disabled by configuration [2024-01-13 11:13:40.592] I [OvenMediaEngine:1] OvenMediaEngine | main.cpp:134 | Trying to create OVT Publisher... [2024-01-13 11:13:40.593] I [OvenMediaEngine:1] OVT | ovt_publisher.cpp:90 | OVTPublisher is listening on *:9000/TCP... [2024-01-13 11:13:40.594] I [OvenMediaEngine:1] Publisher | publisher.cpp:19 | OVTPublisher has been started. [2024-01-13 11:13:40.595] I [OvenMediaEngine:1] OvenMediaEngine | main.cpp:135 | Trying to create File Publisher... [2024-01-13 11:13:40.595] I [OvenMediaEngine:1] Publisher | publisher.cpp:19 | FilePublisher has been started. [2024-01-13 11:13:40.596] I [OvenMediaEngine:1] OvenMediaEngine | main.cpp:136 | Trying to create MpegtsPush Publisher... [2024-01-13 11:13:40.596] I [OvenMediaEngine:1] Publisher | publisher.cpp:19 | MPEGTSPushPublisher has been started. [2024-01-13 11:13:40.597] I [OvenMediaEngine:1] OvenMediaEngine | main.cpp:137 | Trying to create RtmpPush Publisher... [2024-01-13 11:13:40.597] I [OvenMediaEngine:1] Publisher | publisher.cpp:19 | RTMPPushPublisher has been started. [2024-01-13 11:13:40.598] I [OvenMediaEngine:1] OvenMediaEngine | main.cpp:138 | Trying to create SrtPush Publisher... [2024-01-13 11:13:40.598] I [OvenMediaEngine:1] Publisher | publisher.cpp:19 | SRTPushPublisher has been started. [2024-01-13 11:13:40.599] I [OvenMediaEngine:1] OvenMediaEngine | main.cpp:139 | Trying to create Thumbnail Publisher... [2024-01-13 11:13:40.599] W [OvenMediaEngine:1] Thumbnail | thumbnail_publisher.cpp:79 | ThumbnailPublisher is disabled by configuration [2024-01-13 11:13:40.600] I [OvenMediaEngine:1] OvenMediaEngine | main.cpp:142 | Trying to create Transcoder... [2024-01-13 11:13:40.600] I [OvenMediaEngine:1] Transcoder | transcoder_gpu.cpp:42 | Trying to check the hardware accelerator [2024-01-13 11:13:40.600] W [OvenMediaEngine:1] Transcoder | transcoder_gpu.cpp:51 | No supported NVIDIA Accelerator [2024-01-13 11:13:40.601] W [OvenMediaEngine:1] Transcoder | transcoder_gpu.cpp:61 | No supported Xilinx Media Accelerator [2024-01-13 11:13:40.601] W [OvenMediaEngine:1] Transcoder | transcoder_gpu.cpp:71 | No supported Intel QuickSync Accelerator [2024-01-13 11:13:40.602] I [OvenMediaEngine:1] OvenMediaEngine | main.cpp:145 | Trying to create WebRTC Provider... [2024-01-13 11:13:40.603] I [OvenMediaEngine:1] Signalling.P2P | rtc_p2p_manager.cpp:27 | P2P is disabled in the configuration [2024-01-13 11:13:40.603] I [OvenMediaEngine:1] HTTP.Server | http_server_manager.cpp:319 | WebRTCProvider is listening on *:3333 (TLS: *:3334)... [2024-01-13 11:13:40.604] I [OvenMediaEngine:1] HTTP.Server | http_server_manager.cpp:319 | WebRTCProvider is listening on *:3333 (TLS: *:3334)... [2024-01-13 11:13:40.604] I [OvenMediaEngine:1] ICE | ice_port_manager.cpp:305 | ICE candidate found: 192.168.2.97:10000 [2024-01-13 11:13:40.604] I [OvenMediaEngine:1] ICE | ice_port_manager.cpp:305 | ICE candidate found: 192.168.2.97:10001 [2024-01-13 11:13:40.605] I [OvenMediaEngine:1] ICE | ice_port_manager.cpp:305 | ICE candidate found: 192.168.2.97:10002 [2024-01-13 11:13:40.605] I [OvenMediaEngine:1] ICE | ice_port_manager.cpp:305 | ICE candidate found: 192.168.2.97:10003 [2024-01-13 11:13:40.606] I [OvenMediaEngine:1] ICE | ice_port_manager.cpp:305 | ICE candidate found: 192.168.2.97:10004 [2024-01-13 11:13:40.606] I [OvenMediaEngine:1] ICE | ice_port.cpp:113 | ICE ports are listening on *:10004/UDP (0x7fbf2e538f10), *:10003/UDP (0x7fbf2e539210), *:10002/UDP (0x7fbf2e539510), *:10001/UDP (0x7fbf2e539810), *:10000/UDP (0x7fbf2e539b10) (for WebRTCProvider) [2024-01-13 11:13:40.606] I [OvenMediaEngine:1] ICE | ice_port_manager.cpp:191 | TURN port is listening on *:3478/TCP (for WebRTCProvider) [2024-01-13 11:13:40.608] I [OvenMediaEngine:1] Provider | provider.cpp:37 | WebRTCProvider has been started. [2024-01-13 11:13:40.609] I [OvenMediaEngine:1] OvenMediaEngine | main.cpp:146 | Trying to create MPEG-TS Provider... [2024-01-13 11:13:40.609] W [OvenMediaEngine:1] MpegtsProvider | mpegts_provider.cpp:147 | MPEGTSProvider is disabled by configuration [2024-01-13 11:13:40.610] I [OvenMediaEngine:1] MpegtsProvider | mpegts_provider.cpp:39 | Terminated Mpegts Provider module. [2024-01-13 11:13:40.610] I [OvenMediaEngine:1] OvenMediaEngine | main.cpp:147 | Trying to create SRT Provider... [2024-01-13 11:13:40.613] I [OvenMediaEngine:1] SrtProvider | srt_provider.cpp:116 | SrtProvider is listening on *:9999/SRT [2024-01-13 11:13:40.614] I [OvenMediaEngine:1] Provider | provider.cpp:37 | SrtProvider has been started. [2024-01-13 11:13:40.614] I [OvenMediaEngine:1] OvenMediaEngine | main.cpp:148 | Trying to create RTMP Provider... [2024-01-13 11:13:40.616] I [OvenMediaEngine:1] RTMPProvider | rtmp_provider.cpp:138 | RTMPProvider is listening on *:1935 [2024-01-13 11:13:40.616] I [OvenMediaEngine:1] Provider | provider.cpp:37 | RTMPProvider has been started. [2024-01-13 11:13:40.617] I [OvenMediaEngine:1] OvenMediaEngine | main.cpp:149 | Trying to create OVT Provider... [2024-01-13 11:13:40.617] I [OvenMediaEngine:1] Provider | provider.cpp:37 | OVTProvider has been started. [2024-01-13 11:13:40.618] I [OvenMediaEngine:1] OvenMediaEngine | main.cpp:150 | Trying to create RTSPC Provider... [2024-01-13 11:13:40.619] I [OvenMediaEngine:1] Provider | provider.cpp:37 | RTSPCProvider has been started. [2024-01-13 11:13:40.619] I [OvenMediaEngine:1] OvenMediaEngine | main.cpp:151 | Trying to create File Provider... [2024-01-13 11:13:40.620] I [OvenMediaEngine:1] Provider | provider.cpp:37 | FileProvider has been started. [2024-01-13 11:13:40.620] I [OvenMediaEngine:1] OvenMediaEngine | main.cpp:152 | Trying to create Scheduled Provider... [2024-01-13 11:13:40.621] I [OvenMediaEngine:1] Provider | provider.cpp:37 | ScheduledProvider has been started. [2024-01-13 11:13:40.621] I [OvenMediaEngine:1] OvenMediaEngine | main.cpp:159 | All modules are initialized successfully [2024-01-13 11:13:40.622] I [OvenMediaEngine:1] Monitor | monitoring.cpp:75 | OvenMediaEngine(72095fd3-0bc8-4835-a034-8fd5b7a78521) ServerMetric has been started for monitoring - 2024-01-13T11:13:40.622+00:00 [2024-01-13 11:13:40.648] I [OvenMediaEngine:1] Certificate | certificate.cpp:35 | A certificate has been loaded for VirtualHost [default]: Cert file path: origin_conf/cert.crt Chain cert file path: origin_conf/ Private key file path: origin_conf/cert.key [2024-01-13 11:13:40.654] I [OvenMediaEngine:1] Monitor | server_metrics.cpp:61 | Create HostMetrics(default/72095fd3-0bc8-4835-a034-8fd5b7a78521/default) for monitoring [2024-01-13 11:13:40.655] I [OvenMediaEngine:1] Orchestrator | orchestrator_internal.cpp:821 | Trying to create an application: [#default#app] [2024-01-13 11:13:40.655] I [OvenMediaEngine:1] Monitor | host_metrics.cpp:58 | Create ApplicationMetrics(#default#app/72095fd3-0bc8-4835-a034-8fd5b7a78521/default/#default#app) for monitoring [2024-01-13 11:13:40.656] I [OvenMediaEngine:1] MediaRouter | mediarouter_application.cpp:51 | [#default#app(0)] Created Mediarouter application. worker(1) [2024-01-13 11:13:40.656] I [OvenMediaEngine:1] MediaRouter | mediarouter.cpp:83 | Created Mediarouter. app(#default#app) [2024-01-13 11:13:40.658] I [OvenMediaEngine:1] Publisher | application.cpp:181 | WebRTC Publisher Application has created [#default#app] application [2024-01-13 11:13:40.658] I [OvenMediaEngine:1] Publisher | application.cpp:181 | LLHLS Publisher Application has created [#default#app] application [2024-01-13 11:13:40.659] I [OvenMediaEngine:1] Publisher | application.cpp:181 | OVTPublisher Application has created [#default#app] application [2024-01-13 11:13:40.659] W [OvenMediaEngine:1] Publisher | publisher.cpp:70 | File publisher is disabled in #default#app application, so it was not created [2024-01-13 11:13:40.659] W [OvenMediaEngine:1] Publisher | publisher.cpp:70 | MPEGTSPush publisher is disabled in #default#app application, so it was not created [2024-01-13 11:13:40.659] W [OvenMediaEngine:1] Publisher | publisher.cpp:70 | RTMPPush publisher is disabled in #default#app application, so it was not created [2024-01-13 11:13:40.660] W [OvenMediaEngine:1] Publisher | publisher.cpp:70 | SRTPush publisher is disabled in #default#app application, so it was not created [2024-01-13 11:13:40.660] I [OvenMediaEngine:1] Transcoder | transcoder_application.cpp:34 | Created transcoder application. [#default#app] [2024-01-13 11:13:40.661] I [OvenMediaEngine:1] Transcoder | transcoder.cpp:94 | Transcoder has created [config][#default#app] application [2024-01-13 11:13:40.661] I [OvenMediaEngine:1] Provider | application.cpp:46 | WebRTCProvider has created [#default#app] application [2024-01-13 11:13:40.662] I [OvenMediaEngine:1] Provider | application.cpp:46 | SrtProvider has created [#default#app] application [2024-01-13 11:13:40.662] I [OvenMediaEngine:1] Provider | application.cpp:46 | RTMPProvider has created [#default#app] application [2024-01-13 11:13:40.663] I [OvenMediaEngine:1] Provider | application.cpp:46 | OVTProvider has created [#default#app] application [2024-01-13 11:13:40.663] I [OvenMediaEngine:1] Provider | application.cpp:46 | RTSPCProvider has created [#default#app] application [2024-01-13 11:13:40.664] I [OvenMediaEngine:1] Provider | application.cpp:46 | ScheduledProvider has created [#default#app] application [2024-01-13 11:13:40.680] I [OvenMediaEngine:1] Certificate | certificate.cpp:35 | A certificate has been loaded for VirtualHost [api_server]: Cert file path: origin_conf/cert.crt Chain cert file path: origin_conf/ Private key file path: origin_conf/cert.key [2024-01-13 11:13:40.682] I [OvenMediaEngine:1] HTTP.Server | http_server_manager.cpp:319 | API Server is listening on TLS: *:8081... [2024-01-13 11:13:48.682] I [SPRtcSig-t3334:12] HTTP.Server | http_server.cpp:149 | Client() is connected on *:3334 [2024-01-13 11:13:48.693] I [SPRtcSig-t3334:12] HTTP.Server | http_connection.cpp:147 | TLS connection accepted : Server Name() Alpn Protocol(http/1.1) Client () [2024-01-13 11:13:48.694] I [SPRtcSig-t3334:12] Signalling | rtc_signalling_server.cpp:316 | New client is connected: [2024-01-13 11:13:48.697] I [SPRtcSig-t3334:12] Publisher | publisher.cpp:187 | Try to pull stream from local origin map: [#default#app/camera1_sub] [2024-01-13 11:13:48.698] I [SPRtcSig-t3334:12] Orchestrator | orchestrator.cpp:810 | Trying to pull stream [#default#app/camera1_sub] from provider using origin map: PullProvider [2024-01-13 11:13:48.701] I [SPRtcSig-t3334:12] RtspcStream | rtspc_stream.cpp:243 | Request Describe : Request: DESCRIBE rtsp://192.168.2.135:554/Streaming/Channels/102 1.0 Accept: application/sdp CSeq: 0 User-Agent: OvenMediaEngine [2024-01-13 11:13:48.706] I [SPRtcSig-t3334:12] RtspcStream | rtspc_stream.cpp:320 | Response Describe : Response: RTSP/1.0 200 OK Content-Length: 572 Content-Type: application/sdp CSeq: 0 Date: Sat, 13 Jan 2024 11:13:48 GMT [2024-01-13 11:13:48.707] W [SPRtcSig-t3334:12] SDP | common_attr.cpp:200 | Unknown attribute type: a=Media_header:MEDIAINFO=494D4B48020100000400000100000000000000000000000000000000000000000000000000000000; [2024-01-13 11:13:48.707] W [SPRtcSig-t3334:12] SDP | common_attr.cpp:200 | Unknown attribute type: a=appversion:1.0 [2024-01-13 11:13:48.708] I [SPRtcSig-t3334:12] RtspcStream | rtspc_stream.cpp:364 | SDP : v=0 o=- 1109162014219182 0 IN IP4 0.0.0.0 s=HIK Media Server V3.4.97 i=HIK Media Server Session Description : standard e=NONE c=IN IP4 0.0.0.0 t=0 0 a=control:* b=AS:5130 a=range:npt=now- m=video 0 RTP/AVP 96 i=Video Media a=rtpmap:96 H264/90000 a=fmtp:96 profile-level-id=4D0014;packetization-mode=0;sprop-parameter-sets=Z01AHppkBQF/y/+AXoBfNwEBAUAAAPoAAB1MOhgGgABnyu8uNDANAADPld5cKA==,aO48gA== a=control:trackID=video b=AS:5120 a=Media_header:MEDIAINFO=494D4B48020100000400000100000000000000000000000000000000000000000000000000000000; a=appversion:1.0 [2024-01-13 11:13:48.708] I [SPRtcSig-t3334:12] RtspcStream | rtspc_stream.cpp:438 | Request SETUP : Request: SETUP rtsp://192.168.2.135:554/Streaming/Channels/102/trackID=video 1.0 Authorization: Digest username="admin", realm="d1ea8e7561c775d53aca4fd2", nonce="015fccd15", uri="rtsp://192.168.2.135:554/Streaming/Channels/102/trackID=video", response="c4ab5b52f07aaf72f83e09cb8e7ad47e" CSeq: 1 Transport: RTP/AVP/TCP;unicast;interleaved=0-1;ssrc=5DB307AE User-Agent: OvenMediaEngine [2024-01-13 11:13:48.710] I [SPRtcSig-t3334:12] RtspcStream | rtspc_stream.cpp:454 | Response SETUP : Response: RTSP/1.0 200 OK Accept-Ranges: NPT CSeq: 1 Date: Sat, 13 Jan 2024 11:13:48 GMT Media-Properties: No-Seeking, Time-Progressing, Time-Duration=0 Session: 1407566111;timeout=60 Transport: RTP/AVP/TCP;unicast;interleaved=0-1;ssrc=53E5C11F [2024-01-13 11:13:48.711] I [SPRtcSig-t3334:12] RtspcStream | rtspc_stream.cpp:640 | Request PLAY : Request: PLAY rtsp://192.168.2.135:554/Streaming/Channels/102 1.0 Authorization: Digest username="admin", realm="d1ea8e7561c775d53aca4fd2", nonce="015fccd15", uri="rtsp://192.168.2.135:554/Streaming/Channels/102", response="fc968ab17ccdebb23b9bea954e3bc5ac" CSeq: 2 Session: 1407566111 User-Agent: OvenMediaEngine [2024-01-13 11:13:48.744] I [SPRtcSig-t3334:12] RtspcStream | rtspc_stream.cpp:657 | Response PLAY : Response: RTSP/1.0 200 OK CSeq: 2 Date: Sat, 13 Jan 2024 11:13:48 GMT Session: 1407566111;timeout=0 [2024-01-13 11:13:48.745] I [SPRtcSig-t3334:12] Provider | stream.cpp:65 | RTSPCProvider Application has started to play [camera1_sub(100)] stream : rtsp://192.168.2.135:554/Streaming/Channels/102 [2024-01-13 11:13:48.745] I [SPRtcSig-t3334:12] Provider | stream.cpp:51 | #default#app/camera1_sub(100) has been started stream [2024-01-13 11:13:48.746] I [SPRtcSig-t3334:12] MediaRouter | mediarouter_application.cpp:340 | [#default#app/camera1_sub(100)] Trying to create a stream [2024-01-13 11:13:48.746] I [SPRtcSig-t3334:12] Monitor | application_metrics.cpp:58 | Create StreamMetrics(camera1_sub/72095fd3-0bc8-4835-a034-8fd5b7a78521/default/#default#app/camera1_sub/i) for monitoring [2024-01-13 11:13:48.747] I [SPRtcSig-t3334:12] MediaRouter | mediarouter_application.cpp:438 | [#default#app/camera1_sub(100)] Stream has been created [2024-01-13 11:13:48.747] I [SPRtcSig-t3334:12] Transcoder | transcoder_stream.cpp:63 | [#default#app/camera1_sub(100)] Transcoder stream has been started [2024-01-13 11:13:48.749] I [SPRtcSig-t3334:12] Provider | application.cpp:198 | #default#app application has created 0 stream motor [2024-01-13 11:13:48.749] I [SPRtcSig-t3334:12] Provider | stream_motor.cpp:137 | #default#app/camera1_sub(100) stream has added to 0 StreamMotor [2024-01-13 11:13:48.749] E [SPRtcSig-t3334:12] WebRTC Publisher | webrtc_publisher.cpp:333 | Cannot find stream (#default#app/camera1_sub) [2024-01-13 11:13:48.750] E [SPRtcSig-t3334:12] Signalling | rtc_signalling_server.cpp:407 | Cannot find stream [#default#app/camera1_sub] [2024-01-13 11:13:48.752] I [SPRtcSig-t3334:12] Signalling | rtc_signalling_server.cpp:450 | Client is disconnected: HttpConnection(0x7fbf29801010) : WebSocket TLS(Enabled) (#default#app / camera1_sub, ufrag: local: (N/A), remote: (N/A)) [2024-01-13 11:13:48.754] I [SPRtcSig-t3334:12] HTTP.Server | http_server.cpp:216 | Client() has been disconnected by *:3334 [2024-01-13 11:13:50.244] E [SPICE-u10001:17] ICE | ice_port.cpp:748 | Could not parse STUN packet from [2024-01-13 11:13:50.763] I [SPRtcSig-t3334:12] HTTP.Server | http_server.cpp:149 | Client() is connected on *:3334 [2024-01-13 11:13:50.768] I [SPRtcSig-t3334:12] HTTP.Server | http_connection.cpp:147 | TLS connection accepted : Server Name() Alpn Protocol(http/1.1) Client () [2024-01-13 11:13:50.771] I [SPRtcSig-t3334:12] Signalling | rtc_signalling_server.cpp:316 | New client is connected: [2024-01-13 11:13:50.781] I [SPRtcSig-t3334:12] Publisher | publisher.cpp:187 | Try to pull stream from local origin map: [#default#app/camera1_sub] [2024-01-13 11:13:50.782] I [SPRtcSig-t3334:12] Orchestrator | orchestrator.cpp:810 | Trying to pull stream [#default#app/camera1_sub] from provider using origin map: PullProvider [2024-01-13 11:13:50.783] I [SPRtcSig-t3334:12] Provider | provider.cpp:144 | The inbound stream already exists: #default#app/camera1_sub [2024-01-13 11:13:50.783] E [SPRtcSig-t3334:12] WebRTC Publisher | webrtc_publisher.cpp:333 | Cannot find stream (#default#app/camera1_sub) [2024-01-13 11:13:50.784] E [SPRtcSig-t3334:12] Signalling | rtc_signalling_server.cpp:407 | Cannot find stream [#default#app/camera1_sub] [2024-01-13 11:13:50.788] I [SPRtcSig-t3334:12] Signalling | rtc_signalling_server.cpp:450 | Client is disconnected: HttpConnection(0x7fbf2e5aa210) : WebSocket TLS(Enabled) (#default#app / camera1_sub, ufrag: local: (N/A), remote: (N/A)) [2024-01-13 11:13:50.789] I [SPRtcSig-t3334:12] HTTP.Server | http_server.cpp:216 | Client() has been disconnected by *:3334 [2024-01-13 11:13:52.795] I [SPRtcSig-t3334:12] HTTP.Server | http_server.cpp:149 | Client() is connected on *:3334 [2024-01-13 11:13:52.798] I [SPRtcSig-t3334:12] HTTP.Server | http_connection.cpp:147 | TLS connection accepted : Server Name() Alpn Protocol(http/1.1) Client () [2024-01-13 11:13:52.799] I [SPRtcSig-t3334:12] Signalling | rtc_signalling_server.cpp:316 | New client is connected: [2024-01-13 11:13:52.803] I [SPRtcSig-t3334:12] Publisher | publisher.cpp:187 | Try to pull stream from local origin map: [#default#app/camera1_sub] [2024-01-13 11:13:52.803] I [SPRtcSig-t3334:12] Orchestrator | orchestrator.cpp:810 | Trying to pull stream [#default#app/camera1_sub] from provider using origin map: PullProvider [2024-01-13 11:13:52.804] I [SPRtcSig-t3334:12] Provider | provider.cpp:144 | The inbound stream already exists: #default#app/camera1_sub [2024-01-13 11:13:52.805] E [SPRtcSig-t3334:12] WebRTC Publisher | webrtc_publisher.cpp:333 | Cannot find stream (#default#app/camera1_sub) [2024-01-13 11:13:52.805] E [SPRtcSig-t3334:12] Signalling | rtc_signalling_server.cpp:407 | Cannot find stream [#default#app/camera1_sub] [2024-01-13 11:13:52.811] I [SPRtcSig-t3334:12] Signalling | rtc_signalling_server.cpp:450 | Client is disconnected: HttpConnection(0x7fbf29802e10) : WebSocket TLS(Enabled) (#default#app / camera1_sub, ufrag: local: (N/A), remote: (N/A)) [2024-01-13 11:13:52.811] I [SPRtcSig-t3334:12] HTTP.Server | http_server.cpp:216 | Client() has been disconnected by *:3334 [2024-01-13 11:13:54.821] I [SPRtcSig-t3334:12] HTTP.Server | http_server.cpp:149 | Client() is connected on *:3334 [2024-01-13 11:13:54.824] I [SPRtcSig-t3334:12] HTTP.Server | http_connection.cpp:147 | TLS connection accepted : Server Name() Alpn Protocol(http/1.1) Client () [2024-01-13 11:13:54.825] I [SPRtcSig-t3334:12] Signalling | rtc_signalling_server.cpp:316 | New client is connected: [2024-01-13 11:13:54.834] I [SPRtcSig-t3334:12] Publisher | publisher.cpp:187 | Try to pull stream from local origin map: [#default#app/camera1_sub] [2024-01-13 11:13:54.835] I [SPRtcSig-t3334:12] Orchestrator | orchestrator.cpp:810 | Trying to pull stream [#default#app/camera1_sub] from provider using origin map: PullProvider [2024-01-13 11:13:54.835] I [SPRtcSig-t3334:12] Provider | provider.cpp:144 | The inbound stream already exists: #default#app/camera1_sub [2024-01-13 11:13:54.836] E [SPRtcSig-t3334:12] WebRTC Publisher | webrtc_publisher.cpp:333 | Cannot find stream (#default#app/camera1_sub) [2024-01-13 11:13:54.836] E [SPRtcSig-t3334:12] Signalling | rtc_signalling_server.cpp:407 | Cannot find stream [#default#app/camera1_sub] [2024-01-13 11:13:54.839] I [SPRtcSig-t3334:12] Signalling | rtc_signalling_server.cpp:450 | Client is disconnected: HttpConnection(0x7fbf29801010) : WebSocket TLS(Enabled) (#default#app / camera1_sub, ufrag: local: (N/A), remote: (N/A)) [2024-01-13 11:13:54.839] I [SPRtcSig-t3334:12] HTTP.Server | http_server.cpp:216 | Client() has been disconnected by *:3334 [2024-01-13 11:14:00.744] E [SPICE-u10001:17] ICE | ice_port.cpp:748 | Could not parse STUN packet from ------------
getroot commented 7 months ago

@AdamDudley I fixed this issue and pushed it to the master branch. Thank you for reporting this issue. Please check if your issue has been resolved.

df503 commented 7 months ago

I was excited to see this was resolved yesterday as I also wanted to use RTSP pull from 2 separate NVR systems. One uses basic authentication (Swann NVR) and the second does not (Unifi Protect). Unfortunately when I pulled it down after your fix, built and installed it last night, I'm getting an RTSP error stating connection cannot be opened for both RTSP. I can confirm both RTSP urls in the same subnet (no routing or firewalls in between OME and the RTSP source) as the camera and can be accessed from VLC on the same machine. Also tested using ffprobe and ffplay from the same OME install on Ubuntu 22.04 from the host OME server.

Here is my Server.xml config for origin's section:

3000 60000 /app/camera1 rtsp [REDACTED_USER_INFO]@[REDACTED_IP]:554/ch1/1 /app/camera2 rtsp [REDACTED_IP]:7447/[REDACTED_PATH]

Here are the logs for the first stream with basic auth, hostname and IP(s) redacted:

[2024-02-01 17:01:25.453] I [SPRtcSig-t3334:178873] HTTP.Server | http_server.cpp:149 | Client(<ClientSocket: 0xffffa899c210, #4, Connected, TCP, Nonblocking, [REDACTED_IP]:59108>) is connected on *:3334

[2024-02-01 17:01:25.489] I [SPRtcSig-t3334:178873] Publisher | publisher.cpp:187 | Try to pull stream from local origin map: [#default#app/camera1] [2024-02-01 17:01:25.489] I [SPRtcSig-t3334:178873] Orchestrator | orchestrator.cpp:818 | Trying to pull stream [#default#app/camera1] from provider using origin map: PullProvider [2024-02-01 17:01:25.496] I [SPRtcSig-t3334:178873] RtspcStream | rtspc_stream.cpp:243 | Request Describe : Request: DESCRIBE rtsp://[REDACTED_IP]:554/ch1/1 1.0 Accept: application/sdp CSeq: 0 User-Agent: OvenMediaEngine

[2024-02-01 17:01:25.505] E [SPRtcSig-t3334:178873] RtspcStream | rtspc_stream.cpp:866 | [#default#app/camera1] An error occurred while receiving packet: [Socket] Remote is disconnected

[2024-02-01 17:01:25.508] I [SPRtcSig-t3334:178873] RtspcStream | rtspc_stream.cpp:243 | Request Describe : Request: DESCRIBE rtsp://[REDACTED_IP]:554/ch1/1 1.0 Accept: application/sdp CSeq: 1 User-Agent: OvenMediaEngine

[2024-02-01 17:01:25.518] E [SPRtcSig-t3334:178873] RtspcStream | rtspc_stream.cpp:866 | [#default#app/camera1] An error occurred while receiving packet: [Socket] Remote is disconnected

[2024-02-01 17:01:25.529] I [SPRtcSig-t3334:178873] RtspcStream | rtspc_stream.cpp:243 | Request Describe : Request: DESCRIBE rtsp://[REDACTED_IP]:554/ch1/1 1.0 Accept: application/sdp CSeq: 2 User-Agent: OvenMediaEngine

Here are the logs from the second RTSP stream without basic authentication which seems to make it further than the first RTSP stream:

[2024-02-01 17:01:59.710] I [SPRtcSig-t3334:178873] HTTP.Server | http_server.cpp:149 | Client(<ClientSocket: 0xffffa3c01a10, #4, Connected, TCP, Nonblocking, [REDACTED_IP]:59115>) is connected on *:3334

[2024-02-01 17:01:59.736] I [SPRtcSig-t3334:178873] Publisher | publisher.cpp:187 | Try to pull stream from local origin map: [#default#app/camera2] [2024-02-01 17:01:59.736] I [SPRtcSig-t3334:178873] Orchestrator | orchestrator.cpp:818 | Trying to pull stream [#default#app/camera2] from provider using origin map: PullProvider [2024-02-01 17:01:59.740] I [SPRtcSig-t3334:178873] RtspcStream | rtspc_stream.cpp:243 | Request Describe : Request: DESCRIBE rtsp://[REDACTED_IP]:7447/[REDACTED_PATH] 1.0 Accept: application/sdp CSeq: 0 User-Agent: OvenMediaEngine

[2024-02-01 17:01:59.755] I [SPRtcSig-t3334:178873] RtspcStream | rtspc_stream.cpp:320 | Response Describe : Response: RTSP/1.0 200 OK Cache-Control: no-store Content-Base: rtsp://[REDACTED_IP]:7447/[REDACTED_PATH]/ Content-Length: 663 Content-Type: application/sdp CSeq: 0 Date: Fri, 02 Feb 2024 01:01:59 UTC Expires: Fri, 02 Feb 2024 01:01:59 UTC Pragma: no-cache Server: Unifi Protect ([REDACTED_URL])

[2024-02-01 17:01:59.756] W [SPRtcSig-t3334:178873] SDP | common_attr.cpp:200 | Unknown attribute type: a=recvonly [2024-02-01 17:01:59.756] W [SPRtcSig-t3334:178873] SDP | media_description.cpp:708 | Sdp parsing error : a=fmtp:96 [2024-02-01 17:01:59.756] I [SPRtcSig-t3334:178873] RtspcStream | rtspc_stream.cpp:364 | SDP : v=0 o=- 294 0 IN IP4 [REDACTED_IP] s=F4E2C60C36A9_1 u=[REDACTED_URL] e=[REDACTED_EMAIL] c=IN IP4 [REDACTED_IP] t=0 0 a=recvonly a=control:* a=range:npt=now- m=audio 0 RTP/AVP 96 a=recvonly a=rtpmap:96 mpeg4-generic/16000/1 a=control:trackID=0 a=fmtp:96 streamtype=5; profile-level-id=15; mode=AAC-hbr; config=1408; SizeLength=13; IndexLength=3; IndexDeltaLength=3; m=audio 0 RTP/AVP 96 a=recvonly a=rtpmap:96 opus/48000/2 a=control:trackID=1 a=fmtp:96 m=video 0 RTP/AVP 97 a=recvonly a=control:trackID=2 a=rtpmap:97 H264/90000 a=fmtp:97 profile-level-id=4d401f; packetization-mode=1; sprop-parameter-sets=Z01AH6aAUAW6bgICAoAAAfSAAHVOTtBEI1A=,aOqPIA==

[2024-02-01 17:01:59.757] I [SPRtcSig-t3334:178873] RtspcStream | rtspc_stream.cpp:438 | Request SETUP : Request: SETUP rtsp://[REDACTED_IP]:7447/[REDACTED_PATH]/trackID=0 1.0 CSeq: 1 Transport: RTP/AVP/TCP;unicast;interleaved=0-1;ssrc=10DC1713 User-Agent: OvenMediaEngine

[2024-02-01 17:01:59.762] I [SPRtcSig-t3334:178873] RtspcStream | rtspc_stream.cpp:454 | Response SETUP : Response: RTSP/1.0 200 OK Cache-Control: no-store CSeq: 1 Date: Fri, 02 Feb 2024 01:01:59 UTC Expires: Fri, 02 Feb 2024 01:01:59 UTC Pragma: no-cache Server: Unifi Protect ([REDACTED_URL]) Session: lxlGOZB1;timeout=0 Transport: RTP/AVP/TCP;unicast;interleaved=0-1;ssrc=0

[2024-02-01 17:01:59.762] I [SPRtcSig-t3334:178873] RtspcStream | rtspc_stream.cpp:438 | Request SETUP : Request: SETUP rtsp://[REDACTED_IP]:7447/[REDACTED_PATH]/trackID=1 1.0 CSeq: 2 Session: lxlGOZB1 Transport: RTP/AVP/TCP;unicast;interleaved=2-3;ssrc=7D49F2D3 User-Agent: OvenMediaEngine

[2024-02-01 17:01:59.766] I [SPRtcSig-t3334:178873] RtspcStream | rtspc_stream.cpp:454 | Response SETUP : Response: RTSP/1.0 200 OK Cache-Control: no-store CSeq: 2 Date: Fri, 02 Feb 2024 01:01:59 UTC Expires: Fri, 02 Feb 2024 01:01:59 UTC Pragma: no-cache Server: Unifi Protect ([REDACTED_URL]) Session: lxlGOZB1;timeout=0 Transport: RTP/AVP/TCP;unicast;interleaved=2-3;ssrc=0

[2024-02-01 17:01:59.766] I [SPRtcSig-t3334:178873] RtspcStream | rtspc_stream.cpp:438 | Request SETUP : Request: SETUP rtsp://[REDACTED_IP]:7447/[REDACTED_PATH]/trackID=2 1.0 CSeq: 3 Session: lxlGOZB1 Transport: RTP/AVP/TCP;unicast;interleaved=4-5;ssrc=393DF6FA User-Agent: OvenMediaEngine

[2024-02-01 17:01:59.770] I [SPRtcSig-t3334:178873] RtspcStream | rtspc_stream.cpp:454 | Response SETUP : Response: RTSP/1.0 200 OK Cache-Control: no-store CSeq: 3 Date: Fri, 02 Feb 2024 01:01:59 UTC Expires: Fri, 02 Feb 2024 01:01:59 UTC Pragma: no-cache Server: Unifi Protect ([REDACTED_URL]) Session: lxlGOZB1;timeout=0 Transport: RTP/AVP/TCP;unicast;interleaved=4-5;ssrc=0

[2024-02-01 17:01:59.770] I [SPRtcSig-t3334:178873] RtspcStream | rtspc_stream.cpp:640 | Request PLAY : Request: PLAY rtsp://[REDACTED_IP]:7447/[REDACTED_PATH] 1.0 CSeq: 4 Session: lxlGOZB1 User-Agent: OvenMediaEngine

[2024-02-01 17:01:59.774] I [SPRtcSig-t3334:178873] RtspcStream | rtspc_stream.cpp:657 | Response PLAY : Response: RTSP/1.0 200 OK Cache-Control: no-store CSeq: 4 Date: Fri, 02 Feb 2024 01:01:59 UTC Expires: Fri, 02 Feb 2024 01:01:59 UTC Pragma: no-cache Range: npt=now- RTP-Info: url=rtsp://[REDACTED_IP]:7447/[REDACTED_PATH]/trackID=1;seq=31757;rtptime=0,url=rtsp://[REDACTED_IP]:7447/[REDACTED_PATH]/trackID=2;seq=27250;rtptime=0 Server: Unifi Protect ([REDACTED_URL]) Session: lxlGOZB1;timeout=0

[2024-02-01 17:01:59.774] I [SPRtcSig-t3334:178873] Provider | stream.cpp:51 | #default#app/camera2(106) has been started stream [2024-02-01 17:01:59.774] I [SPRtcSig-t3334:178873] MediaRouter | mediarouter_application.cpp:340 | [#default#app/camera2(106)] Trying to create a stream [2024-02-01 17:01:59.774] I [SPRtcSig-t3334:178873] Monitor | application_metrics.cpp:58 | Create StreamMetrics(camera2/1702e2e2-850b-41a6-af95-f2c202250a99/default/#default#app/camera2/i) for monitoring [2024-02-01 17:01:59.774] I [SPRtcSig-t3334:178873] MediaRouter | mediarouter_application.cpp:440 | [#default#app/camera2(106)] Stream has been created [2024-02-01 17:01:59.775] I [SPRtcSig-t3334:178873] Transcoder | transcoder_stream.cpp:63 | [#default#app/camera2(106)] Transcoder stream has been started [2024-02-01 17:01:59.775] I [SPRtcSig-t3334:178873] Provider | application.cpp:198 | #default#app application has created 6 stream motor [2024-02-01 17:01:59.775] I [SPRtcSig-t3334:178873] Provider | stream_motor.cpp:137 | #default#app/camera2(106) stream has added to 6 StreamMotor [2024-02-01 17:01:59.775] E [SPRtcSig-t3334:178873] WebRTC Publisher | webrtc_publisher.cpp:333 | Cannot find stream (#default#app/camera2) [2024-02-01 17:01:59.775] E [SPRtcSig-t3334:178873] Signalling | rtc_signalling_server.cpp:407 | Cannot find stream [#default#app/camera2] [2024-02-01 17:01:59.783] I [SPRtcSig-t3334:178873] Signalling | rtc_signalling_server.cpp:450 | Client is disconnected: HttpConnection(0xffffa3c01410) : WebSocket <ClientSocket: 0xffffa3c01a10, #4, Connected, TCP, Nonblocking, [REDACTED_IP]:59115> TLS(Enabled) (#default#app / camera2, ufrag: local: (N

getroot commented 7 months ago

@df503 Is it correct that you pulled the master branch? If so, please send your rtsp url to support@airensoft.com.

df503 commented 7 months ago

Yes, I can confirm its the master branch I tested. Unfortunately for testing, my rtsp urls are private and double natted so I'd have to get creative, setup some acls and punch a few holes through 2 firewalls and setup a few things to allow you to test against my rtsp urls. I will have to try it later after-hours but I appreciate your prompt response. I am new to this project, but I'm loving everything that I've seen so far.

t123yh commented 7 months ago

I have encountered the same issue using docker 0.16.4, and I can confirm that the master branch works fine for me.

@df503 If you are trying to build a docker image yourself, it would be better if you use Dockerfile.local which guarentees that the sources are pulled from local git repo.

df503 commented 7 months ago

I made some progress just a short while ago. I am using a dedicated VM on my machine as a test for this project, so I installed Ubuntu 22.04, cloned the project from master (there were some commits to master earlier today that affected the rtsp related files), compiled and installed locally so I could also run gnome and verify with VLC and ffplay the RTSP streams were good from the exact same source that will be accessing the rtsp streams.

Here's what I found. I was able to get a working rtsp stream, but, I had to use another transcoder in the middle basically. Both direct connections to my Swann and Unifi Protect RTSP sources just don't want to play nice. I am currently using "scrypted" to take my RTSP streams from my Swann NVR and my Unifi Protect and transcoding them into HomeKit compatible format. Scrypted has this transcoding feature with custom ports and RTSP URLs it generates for each camera.

I revamped my network today and eliminated a temporary double nat so I can share my rtsp streams with support@airensoft.com because it would be really nice to eliminate the need for a second transcoder when I would think OME's transcoder should be able to handle it. Both scrypted and OME appear to be using ffmepg for transcoding (like nearly every other product out there that handles transcoding is what I'm finding).

getroot commented 7 months ago

@df503 Your RTSP Server transmits AAC, OPUS, and H264. And it sends RTCP SR for AAC and H264, but not for OPUS. RTCP SR is required for A/V sync. Your OME is unable to start the stream because it is waiting for OPUS's RTCP SR from your RTSP server.

The fundamental solution is for your RTSP server to send an RTCP SR for OPUS. Alternatively, you can tell OME to ignore RTCP SRs with the settings below: This option can be enabled in the latest master branch.

<Origins>
    <Properties>
        <NoInputFailoverTimeout>3000</NoInputFailoverTimeout>
        <UnusedStreamDeletionTimeout>60000</UnusedStreamDeletionTimeout>
    </Properties>
    <Origin>
        <Location>/app/stream</Location>
        <Pass>
            <Scheme>rtsp</Scheme>
            <Urls>
                <Url>xxx.xxx.xxx.xxx:0000/yyyyyyyy</Url>
            </Urls>
        </Pass>
        <IgnoreRtcpSRTimestamp>true</IgnoreRtcpSRTimestamp>
    </Origin>
</Origins>
df503 commented 7 months ago

@df503 Your RTSP Server transmits AAC, OPUS, and H264. And it sends RTCP SR for AAC and H264, but not for OPUS. RTCP SR is required for A/V sync. Your OME is unable to start the stream because it is waiting for OPUS's RTCP SR from your RTSP server.

The fundamental solution is for your RTSP server to send an RTCP SR for OPUS. Alternatively, you can tell OME to ignore RTCP SRs with the settings below: This option can be enabled in the latest master branch.

<Origins>
  <Properties>
      <NoInputFailoverTimeout>3000</NoInputFailoverTimeout>
      <UnusedStreamDeletionTimeout>60000</UnusedStreamDeletionTimeout>
  </Properties>
  <Origin>
      <Location>/app/stream</Location>
      <Pass>
          <Scheme>rtsp</Scheme>
          <Urls>
              <Url>xxx.xxx.xxx.xxx:0000/yyyyyyyy</Url>
          </Urls>
      </Pass>
      <IgnoreRtcpSRTimestamp>true</IgnoreRtcpSRTimestamp>
  </Origin>
</Origins>

This works awesome for the Unifi Protect RTSP stream! Thank you for addressing it so quickly! You are awesome!

getroot commented 6 months ago

This patch made it into the 0.16.5 release. If the issue reproduces, please reopen the issue. Thank you.

AdamDudley commented 4 months ago

Just got round to checking this out in 16.5, working great, thank you.