How to set up your own private RTMP server using nginx

All Versions How to set up your own private RTMP server using nginx

MarkKing

New Member
dodgepong said:
Are you sure the IP address you're using for the server is the external IP and not the internal IP?


Yes, I'm using my external IP and I'm able stream using mxplayer on my android phone using the external IP over 4g.
 

Jack0r

The Helping Squad
I would suggest to check your access and error logs of nginx. If necessary, delete the current log files, try watching your own stream again and then check the new log files.
 

MarkKing

New Member
Jack0r said:
I would suggest to check your access and error logs of nginx. If necessary, delete the current log files, try watching your own stream again and then check the new log files.

Jack, I'm able to watch the stream using my android phone over its 4G network and it's working perfectly fine. So the live stream feed is working but the problem seems to be with the JW code somehow.
 

dodgepong

Administrator
Forum Admin
Then perhaps you should consult JWPlayer tech support...I don't use JWPlayer, and that's obviously where things are breaking down, so I don't know how to help you.
 

MarkKing

New Member
dodgepong said:
Then perhaps you should consult JWPlayer tech support...I don't use JWPlayer, and that's obviously where things are breaking down, so I don't know how to help you.

Alright, will do. Do you think it would be a good idea to try flowplayer? Thanks for your help!
 

dodgepong

Administrator
Forum Admin
Feel free to try whatever you'd like. What's the worst that could happen? I've heard flowplayer is pretty good.
 

MarkKing

New Member
tdx3000 said:
MarkKing if you able to get it to work please share.

I will also try flowplayer when i get home today

I definitely will but I probably won't get to set it up until tomorrow or Sunday.
 

tdx3000

New Member
hmmm weird

I check my port forwarding again and jwplayer is working outside of my network

only forward port 80 for nignx and 1935 for rtmp

Code:
<html>
<head>
<script type="text/javascript" src="jwplayer.js"></script>
</head>
<title>RTMP Live Stream Test</title>
<body>      
<div id="myElement">      
    <script type="text/javascript">
        jwplayer("myElement").setup({
		file: "rtmp://my.external.ip.address/live/teststream",		
		height: 480,
		width: 720
		});
    </script>
</div>
</body>
</html>
 

MarkKing

New Member
tdx3000 said:
hmmm weird

I check my port forwarding again and jwplayer is working outside of my network

only forward port 80 for nignx and 1935 for rtmp

tdx, don't you have the two ports forwarded for ubuntu's internal IP? Because that's what I have. Do you have them forwarded on two different internal IPs?
 

MarkKing

New Member
Jack0r said:
I still recommend to check the logs. And use:
rtmp://IP:PORT/APP/flv:streamname
for example "rtmp://192.168.0.2:1935/live3/flv:480"

Jack, thanks for your reply! Would you mind guiding me on how to check the logs? Also, did you mean for us to use the external ip in that rtmp url?(ie: "rtmp://external.ip:1935/live3/flv:480" Thanks again for all your help!
 

Jack0r

The Helping Squad
Yup external IP. I am online on the obs chat if you want to look into the logs. Is probably easier than through here :)
(Follow the red button on the top of this page, on the right of the FaceBook/Twitter button)
 

MarkKing

New Member
Jack0r said:
Yup external IP. I am online on the obs chat if you want to look into the logs. Is probably easier than through here :)
(Follow the red button on the top of this page, on the right of the FaceBook/Twitter button)

Thanks Jack! Sorry I was away from my computer for a while and I'm leaving for work now. I'll try to get a hold of you through chat when I come back from work or tomorrow when you're back online.
 

tdx3000

New Member
i recall now, i forward port 80 to another ubuntu server not the nginx-rtmp server :(, but still weird, how could jwplayer show up if port 80 is not forward to nginx-rtmp server.

Will have to learn how to read the log and see what was going on.
 

MarkKing

New Member
Jack0r said:
Yup external IP. I am online on the obs chat if you want to look into the logs. Is probably easier than through here :)
(Follow the red button on the top of this page, on the right of the FaceBook/Twitter button)

I tired that as well and still not connecting.
 
Top