Install Red5 on cPanel/WHM (CentOS)
-
Installing Red5 on cPanel / WHM (CentOS) servers
Install Red5 on cPanel -http://bit.ly/Red5cPanelFind an updated version of this description here: http://www.videosoftware.pro/forum/THREAD-Install-Red5-on-cPanel-WHM-CentOS-server
This short description will work on most Linux CentOS servers (most cPanel/WHM, VPS or dedicated). If you have a shared hosting account, please contact your server administrator to install Red5.
*to run the commands below, you will need SSH access and you might need a client to connect (PuTTy or similar).INSTALL JAVA
yum -y install java-1.6.0-openjdk java-1.6.0-openjdk-devel
INSTALL ANT
cd /root/tmp
wget http://mirrors.kahuki.com/apache/ant/binaries/apache-ant-1.8.0-bin.tar.bz2
tar jxvf apache-ant-1.8.0-bin.tar.bz2
mv apache-ant-1.8.0 /usr/local/antEXPORT VARIABLES FOR ANT AND JAVA
export ANT_HOME=/usr/local/ant
export JAVA_HOME=/usr/lib/jvm/java
export PATH=$PATH:/usr/local/ant/bin
export CLASSPATH=.:$JAVA_HOME/lib/classes.zipecho 'export ANT_HOME=/usr/local/ant' >> /etc/bashrc
echo 'export JAVA_HOME=/usr/lib/jvm/java' >> /etc/bashrc
echo 'export PATH=$PATH:/usr/local/ant/bin' >> /etc/bashrc
echo 'export CLASSPATH=.:$JAVA_HOME/lib/classes.zip' >> /etc/bashrcINSTALL SVN
yum install perl-URI
yum install subversion
INSTALL RED5
svn co http://red5.googlecode.com/svn/java/server/tags/0_8_0/ red5
mv red5 /usr/local/
cd /usr/local/red5ant prepare
ant dist
cp -r dist/conf .START RED5
./red5.sh
CREATE INIT FILE
vi /etc/init.d/red5
paste the script below than save and close by pressing ESC than typing :wq
#! /bin/sh # init script for Red5 # /etc/init.d/red5 RED5_USER=root RED5_HOME=/usr/local/red5 RED5_PROG=red5 test -x $RED5_HOME/$RED5_PROG.sh || exit 5 case "$1" in start) echo -n "Starting Red5" echo -n " " cd $RED5_HOME su -s /bin/bash -c "$RED5_HOME/$RED5_PROG.sh &" $RED5_USER ## su -s /bin/bash -c "$RED5_HOME/$RED5_PROG.sh > start.log &" $RED5_USER sleep 2 ;; stop) echo -n "Shutting down Red5" echo -n " " su -s /bin/bash -c "killall -q -u $RED5_USER java" $RED5_USER sleep 2 ;; restart) $0 stop $0 start ;; esac ```Make it executable and execute: > chmod a+x /etc/init.d/red5 > /etc/init.d/red5 restart **RED5 ADMIN** http://YOUR_SERVER_IP:5080/installer/ (install admin) http://YOUR_SERVER_IP:5080/admin/register.html (add user/pass) http://YOUR_SERVER_IP:5080/admin/ **INSTALL JABBERCAM APPLICATION** > cd /root/tmp > wget http://www.chatroulette-clone.com/downloads/java/app/2.8/ChatrouletteApp.zip > unzip ChatrouletteApp.zip > mv ChatrouletteApp /usr/local/red5/webapps > /etc/init.d/red5 restart **TROUBLESHOOTING** http://YOUR_SERVER_IP:5080/demos/port_tester.html * when testing ports, use server IP not localhost Make these ports accept connections: **1935, 1936, 5080, 8088** More info with screenshots here: [http://www.chatroulette-clone.com/questions/faq/installing-red5-cpanel/](http://www.chatroulette-clone.com/questions/faq/installing-red5-cpanel/)
-
hi
i install the red 5 in my server
http://82.165.47.113:5080/but in http://82.165.47.113:5080/installer/ i havn't admin app . so i can't subsscibe :(
and i also i install the ChatrouletteApp in red5, but when i put the link rtmfp://www.villageafro.com/ChatrouletteApp, i can't found it
but in ssh, when i werite "dir" it said the ChatrouletteApp is in usr/local/red5/webapps
what's wrong?
-
Hi,
I did run http://82.165.47.113:5080/demos/port_tester.html and seems that your Red5 install works fine, it is listening on default RTMP ports (change localhost to 82.165.47.113 when testing).
rtmfp://www.villageafro.com/ChatrouletteApp is not accessible by a browser, I did test the rtmp and it doesn't work
I would recommend to install 0.8 until we (or someone else comes with a solution).To install 0.8 (assuming that your red5 directory is /usr/local/red5)
/etc/init.d/red5 stop
rm -rf /usr/local/red5/cd /root/tmp
svn co http://red5.googlecode.com/svn/java/server/tags/0_8_0/ red5
mv red5 /usr/local/
cd /usr/local/red5ant prepare
ant dist
cp -r dist/conf ../red5.sh &
-
@'JabberCam':
Hi,
I did run http://82.165.47.113:5080/demos/port_tester.html and seems that your Red5 install works fine, it is listening on default RTMP ports (change localhost to 82.165.47.113 when testing).
rtmfp://www.villageafro.com/ChatrouletteApp is not accessible by a browser, I did test the rtmp and it doesn't work
I would recommend to install 0.8 until we (or someone else comes with a solution).To install 0.8 (assuming that your red5 directory is /usr/local/red5)
/etc/init.d/red5 stop
rm -rf /usr/local/red5/cd /root/tmp
svn co http://red5.googlecode.com/svn/java/server/tags/0_8_0/ red5
mv red5 /usr/local/
cd /usr/local/red5ant prepare
ant dist
cp -r dist/conf ../red5.sh &
when i was is red5 and i put "ant prepare" i have error: -bash: ant: command not found
-
export ANT_HOME=/usr/local/ant
export JAVA_HOME=/usr/lib/jvm/java
export PATH=$PATH:/usr/local/ant/bin
export CLASSPATH=.:$JAVA_HOME/lib/classes.zip
-
hi
i reinstall red 5
everything is ok, but in admin i dont view the ChatrouletteApp in application,. in ssh, the ChatrouletteApp is localize in the good place (see the file)
whats' wrong?
thanks
-
Make sure, your /usr/local/red5/webapps/ChatrouletteApp folder contains the /WEB-INF folder and all it's contents (you need to deploy the application uncompressed).
-
@'JabberCam':
Make sure, your /usr/local/red5/webapps/ChatrouletteApp folder contains the /WEB-INF folder and all it's contents (you need to deploy the application uncompressed).
i have all files in /webapps/ChatrouletteApp
i dont' understand why it not display in admin
-
Did you restart Red5? Be aware that sometimes Red5 does not stop! Try this:
cd /usr/local/red5
./red5-shutdown.sh
ps aux | grep red5if red5 is not stopped:
killall -q -u root java
ps aux | grep red5than restart Red5:
./red5.sh &
-
yeeeeees. i have the ChatrouletteApp in my admin page. what i do next? i have a dedicace server
-
@'kiamaru':
yeeeeees. i have the ChatrouletteApp in my admin page. what i do next? i have a dedicace server
edit /jabbercam/config.php and point the rtmp to your server, as described in INSTALL.txt that's all.
-
N00b… where do I post to find someone to hire to configure and customize the clone I plan on purchasing?
-
init script for Red5 that will run on cPanel/WHM (CentOS) servers:
#!/bin/sh
Startup script for Red5 flash streaming server on RedHat/CentOS (cPanel)
chkconfig: 2345 95 55
description: Red5 Flash Streaming Server
processname: red5
PROG=red5
RED5_HOME=/usr/local/red5
DAEMON=$RED5_HOME/$PROG.sh
PIDFILE=/var/run/$PROG.pidSource function library
. /etc/rc.d/init.d/functions
[ -r /etc/sysconfig/red5 ] && . /etc/sysconfig/red5
RETVAL=0
case "$1" in
start)
echo -n $"Starting $PROG: "
cd $RED5_HOME
$DAEMON >/dev/null 2>/dev/null &
RETVAL=$?
if [ $RETVAL -eq 0 ]; then
echo $! > $PIDFILE
touch /var/lock/subsys/$PROGfi
[ $RETVAL -eq 0 ] && success $"$PROG startup" || failure $"$PROG startup"
echo
;;
stop)
echo -n $"Shutting down $PROG: "
killproc -p $PIDFILE
RETVAL=$?
echo
[ $RETVAL -eq 0 ] && rm -f /var/lock/subsys/$PROG
;;
restart)
$0 stop
$0 start
;;
status)
status $PROG -p $PIDFILE
RETVAL=$?
;;
*)
echo $"Usage: $0 {start|stop|restart|status}"
RETVAL=1
esacexit $RETVAL
- this script will do the job better. I'll post another modified version later if we find any major issues
-
This may help somebody (most cPanel users) http://www.videosoftware.pro/forum/thread-65.html
-
This will help if Red5 admin is not found when accessing :5080/admin or :5080/admin/register.html
-
the latest version is available for RED5 is 0.7 on site but download from google code using svn as the tarball of 0.7 on site is missing some of the files.
Export Variables for Ant & Java
export ANT_HOME=/usr/local/ant
export JAVA_HOME=/usr/lib/jvm/java
export PATH=$PATH:/usr/local/ant/bin
export CLASSPATH=.:$JAVA_HOME/lib/classes.zip
-
In some cases, doing all the above won't help you. The rtmp works, but "cannot connect to backend services".
Edit my.cnf found at /etc/my.cnf and remove the following line:
skip-networking
vi /etc/my.cnf
*press ESC and :wq to quit and save vi
Restart MySQL and give it a try.:
/etc/init.d/mysql restart
-
Here you find the latest description, all the above in one place: http://www.videosoftware.pro/forum/thread-91.html
-
when i am trying to start red5
getting this errorroot@visichat [~]# /etc/init.d/red5 start
-bash: /etc/init.d/red5: /bin/sh^M: bad interpreter: No such file or directory
-
if you have problem install subversion in cpanel then use this technique
root@server [/usr/local/src]# yum install subversion Loaded plugins: fastestmirror Loading mirror speeds from cached hostfile * base: ftp.nluug.nl * extras: ftp.nluug.nl * updates: ftp.nluug.nl Excluding Packages in global exclude list Finished Setting up Install Process Resolving Dependencies --> Running transaction check ---> Package subversion.i386 0:1.6.11-7.el5_6.3 set to be updated --> Processing Dependency: perl(URI) >= 1.17 for package: subversion --> Processing Dependency: neon >= 0.25.5-6.el5 for package: subversion --> Processing Dependency: libneon.so.25 for package: subversion --> Processing Dependency: libapr-1.so.0 for package: subversion --> Processing Dependency: libaprutil-1.so.0 for package: subversion ---> Package subversion.x86_64 0:1.6.11-7.el5_6.3 set to be updated --> Processing Dependency: perl(URI) >= 1.17 for package: subversion --> Processing Dependency: libaprutil-1.so.0()(64bit) for package: subversion --> Processing Dependency: libapr-1.so.0()(64bit) for package: subversion --> Running transaction check ---> Package apr.i386 0:1.2.7-11.el5_5.3 set to be updated ---> Package apr.x86_64 0:1.2.7-11.el5_5.3 set to be updated ---> Package apr-util.i386 0:1.2.7-11.el5_5.2 set to be updated --> Processing Dependency: libpq.so.4 for package: apr-util ---> Package apr-util.x86_64 0:1.2.7-11.el5_5.2 set to be updated --> Processing Dependency: libpq.so.4()(64bit) for package: apr-util ---> Package neon.i386 0:0.25.5-10.el5_4.1 set to be updated ---> Package neon.x86_64 0:0.25.5-10.el5_4.1 set to be updated ---> Package subversion.i386 0:1.6.11-7.el5_6.3 set to be updated --> Processing Dependency: perl(URI) >= 1.17 for package: subversion ---> Package subversion.x86_64 0:1.6.11-7.el5_6.3 set to be updated --> Processing Dependency: perl(URI) >= 1.17 for package: subversion --> Running transaction check ---> Package postgresql-libs.i386 0:8.1.23-1.el5_6.1 set to be updated ---> Package postgresql-libs.x86_64 0:8.1.23-1.el5_6.1 set to be updated ---> Package subversion.i386 0:1.6.11-7.el5_6.3 set to be updated --> Processing Dependency: perl(URI) >= 1.17 for package: subversion ---> Package subversion.x86_64 0:1.6.11-7.el5_6.3 set to be updated --> Processing Dependency: perl(URI) >= 1.17 for package: subversion --> Finished Dependency Resolution subversion-1.6.11-7.el5_6.3.x86_64 from updates has depsolving problems --> Missing Dependency: perl(URI) >= 1.17 is needed by package subversion-1.6.11-7.el5_6.3.x86_64 (updates) subversion-1.6.11-7.el5_6.3.i386 from updates has depsolving problems --> Missing Dependency: perl(URI) >= 1.17 is needed by package subversion-1.6.11-7.el5_6.3.i386 (updates) Error: Missing Dependency: perl(URI) >= 1.17 is needed by package subversion-1.6.11-7.el5_6.3.i386 (updates) Error: Missing Dependency: perl(URI) >= 1.17 is needed by package subversion-1.6.11-7.el5_6.3.x86_64 (updates) You could try using --skip-broken to work around the problem You could try running: package-cleanup --problems package-cleanup --dupes rpm -Va --nofiles --nodigest The program package-cleanup is found in the yum-utils package.
then You could temporarily remove perl from the /etc/yum.conf exclude line, install subversion, then add perl back to the /etc/yum.conf exclude line after you've gotten subversion installed.