This weekend I installed Red5 on my DreamhostPS account. Note: You do need Dreamhost PS to run Red5 because it is a persistent process. Non-PS accounts don’t allow persistent processes and it will be killed. Here is what I did:
- I made a new user – just to keep all of the red5 stuff quarantined from the rest of my stuff.
- SSH in as that user: ssh your-user@yourdomain.com
- Add the following lines to the .bash_profile for that user:
export JAVA_HOME=/usr/local/dh/java
export ANT_HOME=$HOME
export PATH=$PATH:$ANT_HOME/bin
- Make a directory called ‘source’ and enter it..
mkdir source && cd source - You need ant to build Red5, so download it into your source folder:
wget http://www.bizdirusa.com/mirrors/apache/ant/binaries/apache-ant-1.8.0-bin.tar.gz - Unzip it
tar -xvf apache-ant-1.8.0-bin.tar.gz - Move the ‘bin’, ‘etc’ and ‘lib’ folders to $HOME
svn checkout http://red5.googlecode.com/svn/java/server/trunk/ red5-read-only
- cd source/red5-read-only/
- ant ivyclear dist
- cd dist/
- chmod 755 red5.sh
- screen
- ./red5.sh
- Now you should be able to access a test page at http://yourdomain.com:5080/ and the endpoint for your services will be rtmp://yourdomain.com:1935/yourAppName (the ‘:1935′ might be redundant, but just to be safe)
I am still working on making a simple recording tool, but this will at least get the server running. Comments/complaints welcome!
4 Comments
I tried to follow these steps (exactly) but I got two errors:
The first when I ran
ant ivyclear dist
No dist folder is created and I get bash: ant: command not found
The second after I run ./red5.sh:
Exception in thread “main” java.lang.NoClassDefFoundError: org/red5/server/Bootstrap
Caused by: java.lang.ClassNotFoundException: org.red5.server.Bootstrap
at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
Could not find the main class: org.red5.server.Bootstrap. Program will exit.
Any idea what is causing these errors?
This works great! Thanks for taking the time to write these instructions…
I would add a step after step 3 to properly load the variables in the session. I don’t remember the command for that, so I just logged out and ssh in again.
Hey! Getting similar issues to #1 – admittedly NOT commend-line savvy. Build errors happen after ‘ant ivyclear dist.’
Any help you could offer would be great.
Is it possible at all to do live streaming on a dreamhost ps? I just was told by tech support they only allow http stremaing…? Is it working for anyone?
Thanks