I'm trying to do streaming from a source (tv box transmitting in multicast in this source rtp://@X.X.X.X:Y) to Internet (to my mobile phone as example or another device inside of my LAN) but I can not achieve it. The command I'm using is something like this

ffmpeg -i rtp://@X.X.X.X:Y -vcodec copy -f mpegts udp://

But it does not work as I expected, I mean, I'm able to open vlc and play the streaming in the same machine I'm running ffmpeg but not in another machine in the same LAN. Somebody can help me?

Thank you!

EDIT: Finally I solved installing a software called "udpxy" that forwards multicast content to the clients. I installed in a raspberry and it works perfect for this purpose.

Thank you for all your explanations. It helped me to understand what I want to do and the limitations I have using a transcoder. I guess I can do the same with udpxy with ffmpeg but I can publish directly the TV Box IPs.

  • Lets narrow down your question, some. The TV box is running linux AND the program ffmpeg? Is it okay to narrow down to your local LAN only?
    – jc__
    Apr 23, 2018 at 17:01
  • I'm going to upvote this question, because I am interested in the answer.
    – jc__
    Apr 23, 2018 at 17:02
  • Can you expand a little of what you want to achieve over all with the stream and re-stream?
    – jc__
    Apr 23, 2018 at 17:07
  • Is the client in this setup running VLC?
    – jc__
    Apr 23, 2018 at 17:28

2 Answers 2


With the command as given, is localhost, the computer this command runs on. So of course you'll only be able to open vlc and play the stream on the same machine.

To forward to another machine on the same LAN, you'll need at least the IP address of this machine on your LAN.

You can't stream "to the internet", because neither the computer this command runs on, nor the mobile phone will have a fixed public IP. Both will be behind NAT (Network Address Translation), too. So you won't be able to do this.

If you are in the LAN, what prevents you from using the multicast stream directly from the "other machine" (after all, it's multicast, and that's exactly what multicast is made for...)? Converting a good RTP multicast stream into error-prone single-address UDP packets doesn't seem like the ideal solution to me...


I will use this answer spot to help in trouble shooting.

TV box (multicast) --> ffmpeg (multicast into MPEG transport stream) --> client VLC? (rx mpegts)


The Video stream will not exit the local LAN.

The client that receives the MPEG transport stream cannot join or receive a multicast stream.

The TV box cannot transmit a MPEG transport stream.

Like @dirkt said. "Converting a good RTP multicast stream into error-prone single-address UDP packets doesn't seem like the ideal solution to me..."

Would changing UDP to TCP work, and changing from localhost to the client address?

ffmpeg -i rtp://@X.X.X.X:Y -vcodec copy -f mpegts tcp://

tcp:// -- The client PC receiving the mpegts stream

rtp://@X.X.X.X:Y -- The broadcast stream ( - Transmitted by the TV box.

Ideally one would want to change the TV box transmit to mpegts, OR change the client receive from mpegts to broadcast removing the middle ffmpeg translation.


mpegts -- MPEG transport stream. Wraps an Audio, Video, other in an error correction and synchronization pattern...

IP multicast -- One source PC and multiple destination PCs. IPv4 Address range of: - Some of that is excluded for routing, gateway, etc. A "client" will join a multicast "stream". One to many. messages may be lost or delivered out of order...

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .