tags:

views:

435

answers:

3

I am trying to get the Red5 Flash Media Server working on my computer. I have installed it, but when I run the server I get this error

 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:217)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:205)
at java.lang.ClassLoader.loadClass(ClassLoader.java:321)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:294)
at java.lang.ClassLoader.loadClass(ClassLoader.java:266)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:334)
  Could not find the main class: org.red5.server.Bootstrap. Program will exit.

I came across this link where someone had the same issue: http://trac.red5.org/ticket/762

It looks like they ran this command:

export CLASSPATH=3D$RED5_HOME/lib/slf4j-api-1.5.10.jar:$RED5_HOME/lib/logback- core-0.9.18.jar:$RED5_HOME/lib/logback-classic-0.9.18.jar

I have red5 installed in /usr/share/red5, so I ran this:

export CLASSPATH=3D$/usr/share/red5/lib/slf4j-api-1.5.10.jar:$/usr/share/red5/lib/logback-core-0.9.18.jar:$/usr/share/red5/lib/logback-classic-0.9.18.jar

Yet despite all this I am still seeing the same error message.

A: 

This might be incorrect:

export CLASSPATH=3D$/usr/share/red5/lib/slf4j-api-1.5.10.jar:$/usr/share/red5/lib/logback-core-0.9.18.jar:$/usr/share/red5/lib/logback-classic-0.9.18.jar

I think it should be:

export CLASSPATH=/usr/share/red5/lib/slf4j-api-1.5.10.jar:/usr/share/red5/lib/logback-core-0.9.18.jar:/usr/share/red5/lib/logback-classic-0.9.18.jar

If that doesn't work, then the server is ignoring the CLASSPATH environment variable. Java EE app servers don't use it. Which server software are you using as the listener?

duffymo
I didn't have any luck changing that command. The error message remains. I am using sun-java6-jdk according to this tutorial, http://builddocs.com/streaming_media/installing-red5-0-8-on-ubuntu-9-04/.
cath
+1  A: 

The correct class path is:

export CLASSPATH=/usr/share/red5/lib/slf4j-api-1.5.10.jar:/usr/share/red5/lib/logback-core-0.9.18.jar:/usr/share/red5/lib/logback-classic-0.9.18.jar

Notice:

  • No 3D after = sign
  • No $ before /usr anywhere
MasterGaurav
Did you have any luck?
MasterGaurav
A: 

The red5 bootstrap class is in the boot.jar and this is the only jar that needs to be on the classpath when starting red5.

Mondain