obs-rtspserver icon indicating copy to clipboard operation
obs-rtspserver copied to clipboard

no connection to rtsp other then from localhost.

Open XxTWMLxX opened this issue 2 years ago • 5 comments

i cant connect over my network to the rtsp stream other then from localhost.

Tried: with/without user auth (both work on localhost) changing port turning off windows firewall. no AV installed (firewall). fresh os on new test bench. eliminated router went ethernet cable from pc to pc, and manually assigned ip addresses.

still rtsp stream only visible on localhost of obs pc.

OBS 27.2.3 RTSP-Server 2.2.1

doing a port forward and a port test online. shows: Success: I can see your service on 123.456.789.0 on port (554)

so the server is running and is visible on the port. from outside localhost.

XxTWMLxX avatar Mar 07 '22 20:03 XxTWMLxX

I might be having the same issue. It's hard to tell whether or not it's some fiddly firewall/router setting.

VLC Testing

On a Windows PC:

  1. I started the RTSP server in OBS
  2. In VLC, I opened successfully rtsp://<winpc ip address>:554/live
  3. I set Windows Firewall to allow port 554, TCP.

On a Linux PC:

  1. I opened the firewall with sudo ufw allow 554/tcp
  2. I tried the same URL in VLC, but the connection failed. Here is the error message:
Connection failed:
VLC could not connect to "192.168.1.8:554".
Your input can't be opened:
VLC is unable to open the MRL 'rtsp://192.168.1.8:554/live'. Check the log for details.

And the log message:

main error: connection failed: Network is unreachable
satip error: Failed to connect to RTSP server 192.168.1.8:554
main error: connection failed: Network is unreachable
access_realrtsp error: cannot connect to 192.168.1.8:554

The "network is unreachable" part makes me think that it is one of two firewalls or a router, and that we could use a tutorial on which ports to enable where.

Port testing

Next, I tested whether it was the hostnames or something else.

Windows PC:

  1. I started Wireshark and observed incoming on the LAN connection with a 'port 554' filter.

Linux PC:

  1. I opened a telnet session
    telnet 192.168.1.8 554
    
  2. I typed some garbage and hit "enter"

Windows PC:

  1. The telnet message was received and a TCP ack was sent.

From this, it looks to me like ports are open and something else is going on.

b-adkins avatar Apr 02 '23 09:04 b-adkins

I opened port 80 on the server. And this worked:

mpv --no-cache rtsp://192.168.1.8:554/live --rtsp-transport=tcp

But VLC still doesn't. It fails with:

Connection failed:
VLC could not connect to "170.37.168.178:554".
Your input can't be opened:
VLC is unable to open the MRL 'rtsp://170.37.168.178:554/live'. Check the log for details.
Connection failed:
VLC could not connect to "170.39.168.178:554".

And the log message:

satip error: read error: Resource temporarily unavailable
satip error: Failed to setup RTSP session```

Wireshark says that VLC sent this message:

Real Time Streaming Protocol
    Request: SETUP rtsp://192.168.1.8:554/live RTSP/1.0\r\n
    CSeq: 0\r\n
    Transport: RTP/AVP;unicast;client_port=9002-9003
    \r\n

And an RTSP reply was never received.

b-adkins avatar Apr 02 '23 10:04 b-adkins

It also worked with a computer vision library I'm playing with. So there's something about VLC?

b-adkins avatar Apr 02 '23 10:04 b-adkins

turn off multicast

That solved it for me for both vlc and ffmpeg accessing the rtsp stream from other devices

71T0 avatar Dec 22 '23 06:12 71T0

I had same issue on VLC with no connect on local win10 PC.but the stream works perfectly in android streaming device and iPad . Has to be something with firewalls OBS version 30. On Win10. RTSP server 3.1

pshen01 avatar Feb 24 '24 17:02 pshen01