Replies: 2 comments
-
Hi,
With this docker daemon option host networking is not required, exposing udp ports is sufficient. |
Beta Was this translation helpful? Give feedback.
-
Unfortunately RTSP with UDP requires a direct connection between client and server - i'm working to add support for another protocol (SRT) that doesn't require it. |
Beta Was this translation helpful? Give feedback.
-
Which version are you using?
v0.0.0
Which operating system are you using?
OS
Architecture
Describe the issue
Description
For an application, I want to publish an UDP stream to the server. Once published I want to open it with vlc or ffplay. Using TCP, it works, but with UDP, it won't.
I start the server with
docker run --rm -it -e RTSP_PROTOCOLS=udp -p 8554:8554 aler9/rtsp-simple-server
I publish a stream with ffmpeg
./ffmpeg -i testVideo.mp4 -rtsp_transport udp -f rtsp rtsp://localhost:8554/mystream
I get the following error
2021/02/23 10:23:43 [I] [1/0/0] [client 172.17.0.1:59268] connected (plain) 2021/02/23 10:23:43 [I] [1/1/0] [client 172.17.0.1:59268] is publishing to path 'mystream', 1 track with udp 2021/02/23 10:23:53 [I] [1/1/0] [client 172.17.0.1:59268] ERR: no UDP packets received recently (maybe there's a firewall/NAT in between) 2021/02/23 10:23:53 [I] [0/0/0] [client 172.17.0.1:59268] disconnected
From Wireshark I can see "destination unreachable (port unreachable)" packets
Starting the server with this command line get ffmpeg to block
docker run --rm -it --network=host aler9/rtsp-simple-server
ffmpeg :
./ffmpeg -re -stream_loop -1 -i testVideo.mp4 -f rtsp rtsp://localhost:8554/mystream
errors:
Could not write header for output file #0 (incorrect codec parameters ?): Immediate exit requested Error initializing output stream 0:0 --
Everything works fine using the windows precompiled binaries, so I assume it's a network problem.
Did you attach a network dump?
no
Beta Was this translation helpful? Give feedback.
All reactions