[Red5] red5 on a shared server with IIS behind a firewall
walter at waltertak.com
Thu Nov 8 14:47:43 PST 2007
> To recap, we are trying to run red5 from a shared server (shared with
> an IIS server) through a firewall which allows only ports 80 and 443.
> We have added another IP - lets call it "red5.server.com" and call
> the web server "iis.server.com"
> My flash video player is pointing to
> nc.connect("rtmp://red5.server.com/oflaDemo") ...
> ... ns.play("myVideo.flv");
> which works great as long as I have port 1935 selected.
> I am having a lot of trouble setting things in a manner where the
> red5 server will actually start up instead of giving me various log
> errors. The most common error is:
> " java.net.BindException: Address already in use: bind"
> which I assume means my port or host choices are conflicting in some
> The IIS server listens on 443 and 80, but I would think those ports
> should be free to use by the host "red5.server.com". (the name
> definitely points to a separate IP address).
> I think I need help setting the hosts and ports in the
> red5.properties correctly, since I don't really understand when to
> use the full host name or when to set them to 0.0.0.0 or 127.0.0.1.
> The only settings I have yet been able to get to work for rtmp are
> below. They will not work through the firewall, of course.
> Note that I can't get rtmpt working. Please assist!! Thanks very much!
Default for rtmpt is:
rtmpt.host = 0.0.0.0
rtmpt.port = 8088
in your case you'd want to let it listen on the 2nd IP on your IIS/Red5 box
which you named 'red5.server.com'.
It's not 100% clear if you are behind a fysical firewall or that the
firewall is an application on your server.
Furthermore the firewall can be a NAT router or just a firewall, protecting
other real-world IP's of the servers behind it.
If your IIS server has IP's like 192.168.x.x or 172.x.x.x or 10.x.x.x then
your IIS box doesn't have a real-world IP ; the firewall is probably
forwarding traffic to it.
Ask your admin if that's the case or else you can be fiddling around for
days while this 'problem' is actually 5 mins work.
If the box has private ips then do not assing the FQDN (official hostname)
to the box but because the FQDN name has the public-real-world-ip bound to
you don't want your IIS or Red5 box to listen on a real-world-ip if the box
itself has private IP's.
Just enter the new IP in the Red5 configs where 0.0.0.0 is mentioned. Don't
change the ports. 0.0.0.0 means "listen on all IP's bound to this server"
it's like an alias for 'all'.
Basically in the new situation IIS will listen on IP A port 80 and Red5 on
IP B port 80 and RTMPT on IP B port 8088 ; but rtmpt will NEVER work if you
open the firewall to let traffic for 8088 come through.
127.0.0.1 is short for localhost ; it's a dummy, a loopback IP in case your
server would not have ANY ip or ANY network-card (can you imagine that in
2007 :) ).
If servers would not have 127.0.0.1 assigned to it and the network-driver
would not work properly at startup the tcp-stack could not initialize giving
very strange low-level
problems. You don't want that. Fyi never ever assign IP 127.0.0.1 to a
Edit the IIS-configs and let IIS listen on the FIRST IP .. Not on 0.0.0.0 or
else IIS will listen on all new ips you'd add to the box.
Don't use hostsnames since those might screw things up. Start with IP's and
only change the IP's to hostnames when things work with IP's.
Let someone with IP-knowledge help you with this. It will only make sense
when its working :)
I am using the free version of SPAMfighter for private users.
It has removed 13729 spam emails to date.
Paying users do not have this message in their emails.
Get the free SPAMfighter here: http://www.spamfighter.com/len
More information about the Red5