Wowza Community

Load Balancer: RTMP redirection not working

I’m trying to use load balancing running on EC2. My setup consists of a monthly license working as a load balancer, plus auto-scaled DevPay instances for supplemental recording capacity. That works fine.

I’m currently setting up the redirect and running into issues and I haven’t been able to figure out what’s wrong. I’m not a Flash or Java developer, so please bear with me.

If I enter http://loadbalancer:1935/loadbalancer?serverInfoXML into my browser, I get a healthy response:

<LoadBalancerServerInfo>
<LoadBalancerServer>
<connectCount>0</connectCount>
<status>RUNNING</status>
<redirectCount>0</redirectCount>
<lastMessage>1 second 767 milliseconds</lastMessage>
<redirect>ec2-198-51-100-1.compute-1.amazonaws.com</redirect>
<serverId>d2b12e5f-f324-42cb-a2fc-c063ce3ae51d</serverId>
</LoadBalancerServer>
</LoadBalancerServerInfo>

http://loadbalancer:1935/loadbalancer similarly returns:

redirect=ec2-198-51-100-1.compute-1.amazonaws.com

This shows the load balancer instance adding itself to the pool. If I start DevPay instances they show up here fine, too. (I copied the EC2 jar from the DevPay AMI to make the load balancer work with EC2 variables.)

I need to get Netconnection redirect working according to our Flash dev.

The Flash tool included in the zip for RTMP redirect fails:

redirect.html, entering: rtmp://loadbalancer:1935/redirect

connect: rtmp://loadbalancer:1935/redirect
ncOnStatus: NetConnection.Connect.Failed

The HTTP redirect is working:

httpgetredirect.html, entering: http://loadbalancer:1935/redirect

get redirect: http://loadbalancer:1935/loadbalancer
redirect: ec2-198-51-100-1.compute-1.amazonaws.com
connect: ec2-198-51-100-1.compute-1.amazonaws.com

I’ve followed the instructions in the README.html. I left the redirectPort and redirectScheme properties commented out. I changed the value of the redirectAppName to the name of our application.

I don’t know what else to do. Could someone please point me in the right direction?

The redirect application should reject the connection, and send 302 status along the edge to actually connect to. Review the setup for the redirect application.

If you can’t get it working, zip up conf and logs of the LB Listener and send to support@wowza.com. Include a link to this thread for reference

Richard

I responded to the ticket also. Check your spam, and here is a copy:

The Load Balancer is setup correctly, as is the redirect application. What’s missing is any attempt to connect to the redirect application from a player. Perhaps Wowza is not reachable from the computer you are running the player.

It is very helpful to run Wowza in stand-alone (/bin/startup.bat) mode at this point so you can see log output in the console. When you try to connect from the player, you should see log output immediately. If not, Wowza is not being reached.

From the computer where the player is running, type this in a browser:

http://[wowza-address]:1935

The Wowza version and build number should be displayed. If not, you may have to allow TCP port 1935 in your firewall, or map that port to the computer running Wowza in your router possibly

Richard

Cool, glad it’s working. Thanks for the update

Richard

The redirect application should reject the connection, and send 302 status along the edge to actually connect to. Review the setup for the redirect application.

If you can’t get it working, zip up conf and logs of the LB Listener and send to support@wowza.com. Include a link to this thread for reference

Richard

Yep, I’ve reviewed it as much as I can. I’ll send a zip shortly.

I sent an email with the files as a zip attachment. Was it received okay? I did get an email with ticket #24952.

I responded to the ticket also. Check your spam, and here is a copy:

Richard

I checked my spam folder and there’s no sign of a reply. I guess there’s a hiccup in the system somewhere.

Starting with ./startup.sh was a big help. Thanks for that tip.

It turned out that I had configured the ELB to redirect HTTP on 1935, not plain TCP on 1935. Changing it to TCP made everything happy.

Thanks again for your help!

-Mark