Archive for the ‘red5 installation’ Category

Red5 Webapps Online Application Generator

Sunday, August 29th, 2010

The Red5 Webapps Online Application Generator is a very simple but effective utility to generate Red5 application online. This application gives you the power to create red5 applications without having any knowledge of programming. You can generate streamer applications, with live broadcasting, streaming, recording and shared-Object capabilities in a single click. No compiling/editing needed.

The application takes configuration inputs using a simple flash based front end, and generated red5 application for you by injecting those information’s into a application template at runtime.

The generator is located here Red5/Webapps Application Generator.

How to use:

1. Select a Red5 application from the drop down list of available applications. You can read the description of the application in the description box, once you have selected a application.

2. Then enter the name of your rtmp application in the text input box provided below the application list drop down. (no spaces). This will be the context name that you will connect to : rtmp://server/appname

3. Below the description box, you will find the “Stream Directory Path” option. Use this to select between absolute/relative path schemes. This will set the location for recording/playing streams using the application.  In many cases where you may want the streams directory to be on a location other than the default streams folder under red5, you can use absolute path scheme to specify the path to your custom streams directory.

To select a path scheme select one of the radio buttons .

4. Enter appropriate relative/absolute paths in the text input boxes.

For absolute path scheme on linux file systems , use :      /home/……

For absolute path scheme  on windows use :                   c:/…..

* Relative path schemes remain same for linux and windows , though you wont use “../” to traverse backwards in either.

5. Press “Generate & Download” button to generate the specific application from its application template.

6. Press “ok” when your are prompted to download your application.

7. You may also want to read the description text to kn ow more about the selected application before generating your own copy.

Keep checking back for newly added Red5 applications at:

http://flashvisions.com/

How To Install RED5 version 0.8 or 0.9 on CENTOS

Sunday, January 17th, 2010

RED5 is open source flash server written in java supports streaming audio/video, recording client streams, shared objects, live stream publishing etc. In this short steps you can install red5 server on your virtual server or dedicated.

Download and Install Java

RED5 server depends on Java, so lets install it first using yum:

# yum -y install java-1.6.0-openjdk java-1.6.0-openjdk-devel

Download and Install Ant (Apache Project)

Ant will need to compile RED5 server code. Ant comes in binary form, so just download and install it in /usr/local directory. This step may cause problems because they all always updating the apache ant and changing the name of it, so sometimes the binary is called apache-ant-1.8.0RC1-bin.tar.gz sometimes apache-ant-1.8.0-bin.tar.gz so you will have to get the correct link, go to http://opensource.become.com/apache/ant/binaries/ and find what they have, get the one which ends on tar.gz, should be about 9-10 mega file, so edit the link down to the correct one;

# cd /usr/src
# wget http://opensource.become.com/apache/ant/binaries/apache-ant-xxxxx-bin.tar.gz    (replace apache-ant-xxxxx-bin.tar.gz with the correct file)
# tar zxvf apache-ant-xxxxx-bin.tar.gz   (replace apache-ant-xxxxx-bin.tar.gz witht he correct file)
# mv apache-ant-xxxxx/ /usr/local/ant     (pay attention, replace xxxxx with the correct version)

Export 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.zip

Also export these variables in /etc/bashrc to become available for every user login or for any terminal opens.

# echo ‘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/bashrc

Download and Install RED5 Server

Now we come to the main part, which one you want? 0.8, 0.9, 0.7??

you can find the various versions available at:

http://red5.googlecode.com/svn/java/server/tags/

if for example you want version 0.8, then the command would be:

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

if you want the 0.9, then:

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

so lets say we take 0.8 version:

# cd /usr/src
# svn co http://red5.googlecode.com/svn/java/server/tags/0_8_0/ red5
# mv red5 /usr/local/
# cd /usr/local/red5
# ant prepare
# ant dist

you will see lots and lots of lines, but you should get at last

BUILD SUCCESSFUL

that’s mean its install and now copy the conf directory from dist/ and test the red5 installation.

# cp -r dist/conf .
# ./red5.sh

If it shows Installer service created in the last then everything is fine here, press ctrl+c

Now go to the red5 folder:

# cd /usr/local/red5/dist

command to stop red5:

# sh red5-shutdown.sh
sometimes it is better to use:
# killall -9 java

Command to start red5:

# cd /usr/local/red5/dist

# sh red5.sh &

When Red5 is running you should be able to access http://your-server-domain-or-ip:5080/ .

If it works first thing go to http://your-server:5080/installer/and install admin. Then to http://your-server:5080/admin/register.html and register an username and password. Then you can check application statistics anytime from http://your-server:5080/admin/ with server ip and the registered username, password.

RED 5 RESTART

You need to restart every time you add or update files in the /usr/local/red5/dist/webapps folder – where all applications should be installed.

Could not reserve enough space for object heap

Wednesday, November 18th, 2009

While restarting the red5 service on the server, If you get following error

——————BEGIN SESSION——————
root@server [~]# cd /usr/local/red5
root@server [/usr/local/red5]#sh red5.sh &
Error occurred during initialization of VM
Could not reserve enough space for object heap
Could not create the Java virtual machine.
===============================

Then the best solution is to increase the RAM available to the red5. Locate red5.sh, it is on the red5 folder and replace this line:

Code:
export JAVA_OPTS="$LOGGING_OPTS $SECURITY_OPTS $JAVA_OPTS"

with

Code:
export JAVA_OPTS="-Xms512m -Xmx1024m $LOGGING_OPTS $SECURITY_OPTS $JAVA_OPTS"
And restart red5.sh
On our server s at Hosting Marketers, and Red5 Server we actually give more RAM to red5:
Xms1024m and Xmx2048m
This really depends on the kind of machine you have and the RAM available.

Installing red5, the simple way!

Wednesday, October 21st, 2009

It is not working any more, some files have been changed and our installer is now outdated, soon we will fix the issue. January 2010.

The following steps are intended to automate the installation of Red 5 versions 0.5 , 0.6.3 and 0.7.0 .
I know there is now 0.8 and even 0.9 versions but if your script doesnt need them go for the stable versions, 0.7 is my favorite.
1. Download the red5 installer script ,

Quote:
wget http://ffmpeg-hosting.net/red5_install

Note : Do not download the script to some location where every one can access it as someone may execute it and overwrite an old installation !

2. Make it executable,

Quote:
chmod +x red5_install

3. Execute the script,

Quote:
./red5_install

When the script is executed, it would ask for the red5 version to be installed. There are 3 choices as of now.. 0.7.0 , 0.6.3 and 0.5
Make the choice by entering the digits 1, 2 or 3 . Pressing any other key will select the latest version , 0.70 .

Quote:
# ./red5_install

Hello ,Please choose the RED5 version : (1,2,3 or 4)

1. RED5 0.7.0
2. RED5 0.6.3
3. RED5 0.5
Press Any other key to install 1. RED5 0.7.0

After the version is selected, the process is automated . If everything goes well, you will see something similar to the following as the last line,

Quote:
[DEBUG] 5467 main org.red5.server.Standalone.debug ) Startup done in: 5468 ms

Here the time ’5648 ms’ may vary with different versions and servers. You can exit from this screen by entering the key combination of control and c (^c) as this should shutdown the red5 server normally.

Else if you get any error please leave a word at our help desk and we can install it for you.

If everything goes right, then red5 would be installed in /usr/local/red and it can be started by executing,

Quote:
./red5.sh &

to stop it

Change permissions to 755 of the file red5-shutdown.sh which is inside /usr/local/red

then ./red5-shutdown.sh

You will need to stop red5 after you upload your application to /usr/local/red/webapps

stop red5 and start it again so your application will be activated. after starting the red5 server, and when it arrives to “Startup done in: 5468 ms” log off from the terminal window CTRL  A+D

If you need any help contact support.