Install Red5 on Google Compute Engine

Yesterday we have installed basic web server (apache, php, mysql) on Google Compute Engine. Today our target is to install Red5 on Ubuntu server for Google Compute Engine.

First we need to check Java version installed on Google Compute Engine

$ java -version
The program ‘javac’ can be found in the following packages:

* default-jdk
* ecj
* gcj-4.6-jdk
* openjdk-6-jdk
* gcj-4.5-jdk
* openjdk-7-jdk
Ask your administrator to install one of them

Now you have to install java using

$ sudo apt-get update
$ sudo apt-get install java-package
# sudo apt-get install openjdk-6-jdk
$ sudo apt-get install openjdk-6-jre

Install Ant

$ sudo apt-get install ant

Install Subversion

$ sudo apt-get install subversion

You can download latest Red5 from here

$ sudo wget
$ sudo tar xvfz red5-1.0.0.tar.gz
$ sudo mv red5-1.0.0 red5
$ sudo mv red5 /usr/share/

Now try to run Red5 Server

$ cd /usr/share/red5
$ sudo sh

Yeah! Firewall always block you to access red5 port 5080 so please allow port 5080 & 1935 using below commands

$ gcutil addfirewall red5 –description=”Let open port 5080.” –allowed=”tcp:5080″

$ gcutil addfirewall rtmp –description=”Let open 1935 rtmp port.” –allowed=”tcp:1935″

$ sudo sh

Check Red5 is running

$ sudo netstat -ant
Find port 5080 Listening

Now try http://your-server-address:5080 in a web-browser.

Red5 on Google Compute Engine
Red5 on Google Compute Engine

Install oflaDemo from installer http://your-server-address:5080/installer/ then check ūüėČ

Red5 Demo on Google Compute Engine - Port Tester
Red5 Demo on Google Compute Engine – Port Tester

Install Webmin on Google Compute Engine

$ sudo wget
$ sudo gunzip webmin-1.610.tar.gz
$ sudo tar xf webmin-1.610.tar
$ sudo cd webmin-1.610
$ sudo ./ /usr/local/webmin

Open port 10000 using gcutil addfirewall

$ gcutil addfirewall webmin –description=”Let coordinator and snitches chatter.” –allowed=”tcp:10000″

Wowza Live Audio Video Mixing

Wowza doesn’t do transcoding. So, we highly recommend to use FOSS solutions

Where we need Wowza Live Audio Video Mixing?

1) Live event is broadcasting through Wowza
2) We need a multi lingual setup somewhere and comment or transcode that live event with voice.
3) Flash client might receive the stream where
Output Video Stream = Video of live event + Audio transcoder (multi lingual human voice)

Modern IP cameras provide RTP/RTSP/RTMP with MPEG, MPEG4 or h.264 encoded stream for broadcasting through Wowza.

We might need a RTP/RTSP/RTMP client to decoder and manipulate streams then re-encode stream and serve it over standard protocol like RTP/RTSP/RTMP.

Best Solution should use Xuggler to serve streams to Flash. Media Server might be Wowza or Red5.

Xuggler is the easy way to uncompress, modify, and re-compress any media file (or stream) from Java.

Xuggler in Action: A free open-source library for Java developers to uncompress, manipulate, and compress recorded or live video in real time.


Mixing audio and video with ffmpeg

Mixing audio with video file without audio track
# ffmpeg -i audio-file.mp3 -i video-file.avi -acodec copy -vcodec copy output-file.avi

Mixing audio with video file with existing audio track.
# ffmpeg -i audio-file.mp3 -i video-with-audio.avi -acodec copy -vcodec copy output-file.avi -map 0.0 -map 1.0

-map -> the output file would contain two streams audio and video.

Contact us for Live Audio Video Mixing.

Email: svnlabs[at]
Skype: svnlabs
MSN: svnlabs[at]

Wowza MediaSecurity AddOn Package

The MediaSecurity AddOn Package includes options and procedures for securing Wowza Media Server and the media you plan to stream through Wowza Media Server. There are several Wowza Media Server features that are needed to properly secure your content.

1. SecureToken
2. RTMP authentication
3. RTSP authentication
4. StreamNameAlias
5. secure streaming (RTMPE, RTMPTE and RTMPS).

MediaSecurity AddOn Package for Wowza Media Server 2 or greater:

Some basic steps to setup SecureToken for wowza:

1. Download the MediaSecurity Addon package “” and copy the wms-plugin-security.jar & wms-plugin-security-encryption.jar from the package/lib folder to the [wowza-install]/lib folder, then restart Wowza Server.

2. Edit the new Application.xml. Add the following Module to the bottom of the Modules list, but make sure it is above the closing tag.


3. Add the following Property to the Properties list at the bottom of the Application.xml.


4. Start Wowza Server

Contact us to add SecureToken protection to JWPlayer and FlowPlayer for Wowza, Red5, FMS media files.

Email: svnlabs[at]
Mobile: +919928673578
Skype: svnlabs
MSN: svnlabs[at]


Skype4COM is an ActiveX component that represents the Skype API as objects, properties, commands, events and notifications. Skype4COM is used in ActiveX, Visual Studio, Delphi, PHP or JavaScript.

Download Skype4COM

You might read article on How can we use PHP to access shared library functions?

Useful Links:

Void.Bot is a proof of concept of a Skype bot that sits in Skype Group chats and does useful stuff.

PHP Skype API wrapper class is a PHP class library to access Skype (on Linux) via its API. With PHP DBus, this class library provides easy-to-use interfaces to manipulate Skype on Linux.

// Create a Skype4COM object:
$skype = new COM("Skype4COM.Skype");

// Create a sink object:
$sink =& new _ISkypeEvents ();
$sink->convert = $skype->convert();

// Connect to the sink:
com_event_sink($skype, $sink, "_ISkypeEvents");

// Create a conversion object:
$convert = $skype->convert;
$convert->language = "en";

// Start the Skype client, minimized and with no splash screen:
if (!$skype->client()->isRunning()) {
  $skype->client()->start(true, true);

Skype Tracer is a Windows (.exe) console-based application that lets you issue text-based Skype Desktop API commands to a running Skype client.

COM is an acronym for Component Object Model; it is an object orientated layer defines a common calling convention that enables to call and interoperate with code written in any other language. Not only can the code be written in any language, but it need not even be part of the same executable; the code can be loaded from a DLL, be found in another process running on the same machine.

Skype Developer Forum

BigBlueButton API in PHP

BigBlueButton -- Open Source Web Conferencing

BigBlueButton supports sharing of slides (PDF and PPT), video, whiteboard, chat, voice (using Asterisk or FreeSWITCH), and desktops. It’s built using over many open source components, runs on Mac, Unix, and PC computers, and is supported by a community that cares about good design and a streamlined user experience.

BigBlueButton is built using the following open source components:

Ubuntu, Flex SDK, Ghostscript, Grails, ActiveMQ, Asterisk, Image Magick, MySQL, nginx, Red5, swf Tools, Tomcat, Asterisk Java, Xuggler, Open Office…

BBB is available on Google Code

BigBlueButton is an open source web conferencing system that enables universities and colleges to deliver a high-quality learning experience to remote students.

See examples of how you can integrate BigBlueButton into your applications.

Create Your Own Meeting



$Port = 81;  // Server port to BBB i.e. 81




$sha = sha1($string.$salt);








$sha = sha1($string.$salt);








$sha = sha1($string.$salt);








$sha = sha1($string.$salt);




Create Your Own Meeting Link

Checkout other article “BigBlueButton on CentOS”


Install Union Development Platform

Union is a development platform for creating multiuser applications which runs in a central location on the Internet or a LAN. Users need to connect to Union server then users are in constant real-time contact or session. Users can send messages to/from Union Server.

Application may be chat, game, shared document, widget on web page. Developers can user union for web-development skills to create collaborative content cost-effectively and quickly.

Union is a development platform for creating multiuser applications and games in Adobe Flash, JavaScript, .net, Java, and other languages. Union is free for up to 1000 simultaneous users. Union handles low-level networking and data-synchronization responsibilities, and provides a rich, intuitive communications layer that lets developers focus on application logic, not packets and protocols.

Union Quick Start The Union Platform, By USER1

Union is a development platform for creating connected applications. You can use Union to build:

Social interaction: chat, meeting applications, multiuser whiteboards, collaborative editing tools.

Realtime Multiplayer Games: online action games, head-to-head racing, social worlds, online chess, massively multiplayer trivia, turn-based card and word games.

Realtime Datafeeds: live scores, realtime inventory availability, live surveys, realtime charts, graphs, and analytics dashboards.

Publish/subscribe Channels: topic-based news feeds, project notifications, celebrity chat, sports spectation, live real-estate listings, product sales updates.

Union applications run in desktop and mobile web browsers (JavaScript/HTML5), Flash, Java, C#, and dozens of other languages.

Union Quick Start The Union Platform, By USER2

Install Union on Linux Server

To run the Union Server you will need Java 1.6.

# java -version

Union Server on run on port 9100, Make sure port is open on server ūüėČ

Download from here:

# wget

Decompress the Union Server distribution .tar.gz file

# tar -zxvf union_1.1.0.tar.gz

This will create a folder names /union

Add Java to your operating system’s path or edit the start-server script to point to your java binary.

# cd union
# chmod 775 *
# ./

Ouput may be like…

UNION_HOME set to [/Users/yourname/union/.]
Union Server 1.0.2 (build 498) Started….OK

Some JVM have memory issue, so limit the amount of memory used by Union Server, use the java command-line option “-Xmx”.

# java -Xmx512m -Dfile.encoding=UTF-8 -cp lib/union.jar:lib/stax-api-1.0.1.jar:lib/wstx-asl-3.2.6.jar net.user1.union.core.UnionMain start &

Customize Your Configuration

You can change Union Server’s administration password

SIP Web Phone

SIP Phone service which lets you use your SIP account anywhere in the world via their web based SIP service. The good thing is they already have a few popular SIP services pre-configured, so you don’t even have to configure their SIP.

SIP (Session Initiation Protocol) is the most popular Voice over IP (VoIP) standard. SIP enables two or more people to make phone calls to each other using the Internet to carry the call.

A good quality sip provider will allow for pristine call quality and minimal drops.

Using Flex, Java and Red5 Server we can develop Web Sip Application. The main advantage of these phone is no need to install at client side. Simply we can browse application and we can register and make call.

Asterisk. Digium’s open source communications engine powers voice and video communication solutions worldwide. Discover the power of Asterisk, let us help you choose the right Asterisk solution.

Click2Call is a service that provides users of your websites to make calls from your website and leave voicemails for you by simply clicking a button.

Free Call - Free International Calls & Free VoIP Service. Internet phone calls - free VoIP, call PC to phone over Internet telephony

TringMe also provides a complete ecosystem wherein VoIP providers, Service providers, Enterprises, Developers and End-users can play. An ecosystem which can cater to developing innovative applications that integrate Voice and Telephony without worrying about the underlying details of call routing and signalling.

TringMe - Web based Telephony

Twilio Voice
Build applications that use the phone network to interact with people on landlines and cell phones all over the world. In just a few lines of code, you’ll have phones ringing.

Twilio - Build Scalable Voice, VoIP and SMS Applications in the Cloud


Build voice enabled applications directly in PHP.

VoicePHP - PHP For Voice

Doddle Web Phone

Online SIP WebPhone-Click2Call Doddle - VoIP call from webpage public telephone

Make VoIP calls anywhere in the world via Doddle web based SIP phone directly from your webpage.
Public Internet Telephone: With the free, online, no registration Doddle phone service, VoIP is as easy as accessing a webpage: just start using!
It’s a Doddle.

Linphone is an internet phone or Voice Over IP phone (VoIP).

Linphone, open-source voip software - Linphone, an open-source video sip phone

* Linphone can be used for communicating freely with people over the internet, with voice, video, and text instant messaging.
* Linphone makes use of the SIP protocol , an open standard for internet telephony. You can use Linphone with any SIP VoIP operator, including our free SIP audio/video service.
* Linphone is free-software (or open-source), you can download and redistribute it freely.
* Linphone is available for desktop computers: Linux, Windows, MacOSX, and for mobile phones: Android, iPhone, Blackberry.

OpenSIPS (Open SIP Server) is a mature Open Source implementation of a SIP server. OpenSIPS is more than a SIP proxy/router as it includes application-level functionalities. OpenSIPS, as a SIP server, is the core component of any SIP-based VoIP solution. With a very flexible and customizable routing engine, OpenSIPS ‘unifies voice, video, IM and presence services in a highly efficient way, thanks to its scalable (modular) design.

OpenSIPS feature:
* SIP registrar server
* SIP router / proxy (lcr, dynamic routing, dialplan features)
* SIP redirect server
* SIP presence agent
* SIP back-to-back User Agent
* SIP IM server (chat and end-2-end IM)
* SIP to SMS gateway (bidirectional)
* SIP to XMPP gateway for presence and IM (bidirectional)
* SIP load-balancer or dispatcher
* SIP front end for gateways/asterisk
* SIP NAT traversal unit
* SIP application server

Cipango is a SIP Servlets extension to the popular Jetty HTTP Servlet engine. Cipango/Jetty is then a convergent SIP/HTTP Application Server compliant with both SIP Servlets 1.1 and HTTP Servlets 2.5 standards. It also features a Diameter extension to develop IMS applications.


OpenVBX allows developers to build voice and SMS applications for business, such as toll free phone numbers, call forwarding, voicemail, visual voicemail, voicemail transcriptions, and auto-attendants. It’s like Google Voice, but open source and for business.

OpenVBX- the Web-based, Open Source Phone System for Business

OpenVBX- the Web-based, Open Source Phone System for Business1

FreeSWITCH is a scalable open source cross-platform telephony platform designed to route and interconnect popular communication protocols using audio, video, text or any other form of media. FreeSWITCH also provides a stable telephony platform on which many telephony applications can be developed using a wide range of free tools.

Record Audio from Websites

Flex is a platform for developing and deploying Applications that run on Flash player on Web using Red5 Server.

Flex / Red5 applications are compiled to SWF files and are executed at runtime by Adobe Flash Player.


Open source Red5 video flex flash recorder and player project allows you to insert a red5 / flex module to do it directly from your website. Uses Flex and red5. Videos are stored as FLV streams and can be playable and reviewed from this project within flash player. 2 modes are visible: recorder mode and player mode. All other parameters can be defined through simple html script.

Record, Visualize & Save Microphone Input

Record, Visualize & Save Microphone Input - makemachine

MicrophoneCapture, MicrophoneInput, InputRenderer, WavEncoder are some basic classes to record audio from microphone.

Create a Useful Audio Recorder App in ActionScript

Create a Useful Audio Recorder App in ActionScript 3 - Activetuts+

The MicRecorder class is a great addition to ActionScript 3, be sure to bookmark this article. ūüėČ

Barebones Audio Recorder

Client-side audio capture and conversion to MP3.

This recorder captures user audio, converts to MP3 format on the client side, then uploads to the server.

Barebones Audio Recorder

Flash-based interface
Barebones Audio Recorder1

Sample HTML-based interface
Barebones Audio Recorder2

Red5 record audio with the Flash plugin

Other Links:

Install Etherpad on SUSE Linux

Collaborate on documents in really real-time on SUSE Linux

EtherPad is the first web-based word processor that allows people to work together in really real-time.

All editing of the document is instantly visible on the screens of all participating users, enabling new and productive ways to collaborate on text documents. Etherpad is useful for meeting notes, drafting sessions, education, team programming, and more…

1. Online word-processor with formatting options
2. Letter by letter collaboration
3. Color-coded edits
4. Infinite Undo
5. History Playback
6. Import HTML, Word, RTF
7. Export as HTML, Word, PDF
8. Change Zoom
9. Super simple to embed into your own website/CMS with jQuery and PHP examples
10. Support with PHP, jQuery, Elgg, Apple devices, JavaScript, Ruby, Python etc.

Instructions for compiling and running the EtherPad open source release

How we can install Etherpad on Open SUSE Linux?

I just want to help you out… If you want to pay me nothing that is fine too! ūüėČ

Here are some simple steps to install Etherpad on Open SUSE Linux…..

SUSE Linux is different from RedHat, CentOS or Ubuntu. General Package Managers / Setup Tool won’t work on SUSE, It support Zypper or YaST.

First check your server architecture

# uname -a

# cd /usr/local

Java 1.6 (tested with 1.6.0_20)
Scala 2.7 (tested with 2.7.7)
MySQL Server 5.1 (tested with 5.1.59)
mysql-connector-java (tested with 5.1.18)

Create username ‘etherpad’ with password ‘password’

# useradd -r -m etherpad
# passwd etherpad

Install Java

# uname -a
I am using 32-bit here…
# wget
# sh jdk-6u20-linux-i586-rpm.bin

# java -version

Install fastjar

# zypper install fastjar
# yast –install fastjar
# yast2 –install fastjar

Download Scala

# wget
# tar xvzf

Install MySQL

# zypper install mysql-server
# service mysqld start
# chkconfig mysqld on

Download MySQL Java Connector


# zypper install mysql-connector-java


# wget
# tar xvzf mysql-connector-java-5.1.18.tar.gz

Install MER­CU­R­IAL .. OR GIT

# zypper install mercurial

# zypper install git

Make sure port 9000 must be open on IPTABLES / Firewall

# /etc/sysconfig/iptables

-A RH-Firewall-1-INPUT -p tcp -m state –state NEW -m tcp –dport 9000 -j ACCEPT

Various scripts make assumptions about environment variables:

JAVA should be set to the java executable.
JAVA_HOME should be set to the main jdk directory.
SCALA should be set to the scala executable.
SCALA_HOME should be set to the main scala distribution directory.
PATH should contain $JAVA, $SCALA, and mysql
MYSQL_CONNECTOR_JAR should be set to the mysql-connector JAR file included in the mysql-connector download.
For example, this sets up the environment on my machine:

# touch myENV
# vi myENV

export JAVA_HOME=/usr/java/jdk1.6.0_20/
export JAVA=$JAVA_HOME/bin/java
export SCALA_HOME=/usr/local/scala/
export SCALA=$SCALA_HOME/bin/scala
export MYSQL_CONNECTOR_JAR=/usr/local/mysqlconnector/mysql-connector-java-5.1.18-bin.jar

# cat myENV >> /etc/profile

Download EtherPad

# hg clone etherpad

Some Changes in etherpad source for your server…


# cd /usr/local
# cd etherpad/trunk/etherpad
# cp etc/ data/











Database Setup
The scripts assume mysqld is running on localhost. Once mysqld is running, you can set up the etherpad database by running the following command inside ajcode/etherpad/.

# bin/
This will create a database called “etherpad” with the password “password”, and grant privileges to the user “etherpad”.

All the tables will be set up the first time etherpad is run.

EtherPad compiles all its Java and Scala libraries into a single JAR. To build this jar, you can run the following command inside ajcode/etherpad/.

# bin/
If you modify anything in ajcode/infrastructure, you will most likely need to kill the server, rebuild the jar, and re-launch the server before your change takes effect.

Code inside ajcode/etherpad/src can be modified while the server is running, and the changes will automatically get picked up.

To run the etherpad web server, execute the following command inside ajcode/etherpad/.

# bin/
The first time you run this, it should print out lots of messages about database migrations and finally print:

HTTP server listening on http://youdomain:9000/
At this point, you should be able to visit http://youdomain:9000/ in your web browser and create a new pad.

Thanks to Pauleira!

If you have error related to JVM

Error occurred during initialization of VM
Could not reserve enough space for object heap
Could not create the Java virtual machine.

Fix using

# export _JAVA_OPTIONS=’-Xms32m -Xmx56m -Xss128k -XX:PermSize=32m -XX:MaxPermSize=64m’

Other Link: