February 9th, 2012

How to Install Red5 server in Linux/CentOS cPanel server

Before we start the RED5 server installation, let us check and install the required packages.

I) Install JAVA

SSH to the server:

cd /usr/src

wget http://www.java.net/download/jdk6/6u21/promoted/b04/binaries/jdk-6u21-ea-bin-b04-linux-amd64-05_may_2010-rpm.bin

chmod 755 jdk-6u21-ea-bin-b04-linux-amd64-05_may_2010-rpm.bin

./jdk-6u21-ea-bin-b04-linux-amd64-05_may_2010-rpm.bin

II) Install ANT

wget http://archive.apache.org/dist/ant/binaries/apache-ant-1.8.1-bin.tar.gz

tar zxvf apache-ant-1.8.1-bin.tar.gz

mv apache-ant-1.8.1 /usr/local/ant

export ANT_HOME=/usr/local/ant

ln -s /usr/local/ant/bin/ant /usr/local/bin/ant

III) Install SUBVERSION (SVN client)

yum install subversion

Note: If it shows Perl[URI] dependency error, install the perl-URI package.

wget http://mirror.centos.org/centos-5/5/os/x86_64/CentOS/perl-URI-1.35-3.noarch.rpm

rpm –ivh perl-URI-version

We are now ready to install the RED5 server.

RED5 Server Installation

svn co http://red5.googlecode.com/svn/java/server/tags/0_8_0/ red5

If you need the latest version, download it from:

svn co http://red5.googlecode.com/svn/java/server/tags/0_9_1/ red5

cd red5

/usr/local/bin/ant prepare

/usr/local/bin/ant dist

cd ..

mv red5 /opt/red5

Now the installation part is complete and we can start the RED5 server.

cd /opt/red5/dist

./red5.sh > start.log &

Verify the running of the RED5 server:

ps aux | grep red5

To make sure that RED5 server starts on boot, add /opt/red5/dist/red5.sh to /etc/rc.d/rc.local

echo /opt/red5/dist/red5.sh > restart.log & >> /etc/rc.d/rc.local

When Red5 is running you should be able to access http://hostname:5080/ (if your server is running a firewall, open inbound TCP port 5080 before accessing it).

The below configuration is for version 0.8.x

If it works, visit http://hostname:5080/installer/ and install the “admin” module.

Then access URL http://hostname:5080/admin/register.html and register an admin user with  password.

You can check the application statistics anytime via http://hostname:5080/admin/ with server ip/hostname and the registered username, password.

For newer version of RED5 (0.9 and higher), you have to follow these steps to enable admin:

cd /opt/red5/dist/

mkdir plugins

wget http://red5.googlecode.com/files/AdminPlugin-1.0.zip

unzip -d /opt/red5/dist/plugins AdminPlugin-1.0.zip

cd /opt/red5/dist/webapps

mkdir admin

cd admin

wget http://red5.googlecode.com/files/admin.jsp

Restart Red5

sh /opt/red5/dist/red5-shutdown.sh

sh /opt/red5/dist/red5.sh &

http://hostname:5080/admin/admin.jsp

Username: admin
password: the password for admin
New Password: not required as we are creating a new user here.

then access http://hostname:5080/demos/adminPanel.html

Server Address: hostname
and admin and password with which you registered.

 

 

January 20th, 2012

How to reset your Dolphin 7 admin password

Dolphin 7 uses MD5 and salt encryption for storing password. Below is the easiest method to rest the admin password.

Access your D7 database via PHPMyAdmin or via command line and then run the below queries:

UPDATE `Profiles` SET `Salt` = CONV(FLOOR(RAND()*99999999999999), 10, 36) WHERE `ID`=’1′;

UPDATE `Profiles` SET `Password` = SHA1(CONCAT(md5(‘testtest’), `Salt`)) WHERE `ID`=’1′;

Now login to domain.com/administration using the admin user and password as “testtest”.

January 8th, 2012

How to set the time zone for openvz nodes.

The following post describes how to set the time zone for openvz nodes, Make sure that the HW node timezone is correct Else, use this command to update the time zone on the HW node

rdate -p rdate.cpanel.net
rdate -s rdate.cpanel.net

-p Print the time returned by the remote machine. -s Set the system time to the returned time. On the sub node, run

rm -f /etc/localtime
ln -s /usr/share/zoneinfo/{desired-timezone} /etc/localtime
date MMDDHHMiMiYYYY

If you want to set the time in a OpenVZ sub node automatically, execute the following command on the HW node:

vzctl set 501 --capability sys_time:on --save
vzctl restart 501 501 = container id
date (to check the time)

That’s it.

Set the time zone for openvz nodes.