This page describes the steps to configure and deploy your application on Red5 clustering.
In Red5 0.7 the Ant build.xml file contains a build target that creates a 'cluster' folder containing the same setup as described below. Use 'ant dist-cluster' to create the Red5 clustering setup.
As of now, the current trunk only supports the clustering configuration for multiple Edges with one Origin. The Edge server only accepts RTMP connection.
There are several configuration files added to support Edge/Origin configuration.
red5-edge.xml, red5-edge-core.xml - used for edge spring bean configuration. They are under conf/.
red5-origin.xml, red5-origin-core.xml - used for origin spring bean configuration. They are under conf/.
You don't need to deploy your application on Edges.
We strongly recommend you to deploy Edge on a different server from Origin. But it should be OK to deploy the Edge on the same server as Origin.
Update the configuration of bean "mrtmpClient" in red5-edge-core.xml to point to Origin server:
<bean id="mrtmpClient" class="org.red5.server.net.mrtmp.MRTMPClient" init-method="start" > <property name="ioHandler" ref="mrtmpHandler" /> <property name="server" value="${mrtmp.host}" /> <property name="port" value="${mrtmp.port}" /> </bean>
Replace red5.xml with red5-edge.xml. Start the server by
./red5.sh
or
java \-jar red5.jar
Deploy your application to webapps/. Make sure your 9035 port is not blocked by firewall. The port will be used by Edges to connection Origin.
Update red5.xml with red5-origin.xml. Start the server by
./red5.sh
or
java \-jar red5.jar