Problem installing ActiveMQ 4.1.1 on Fedora 9

View: New views
4 Messages — Rating Filter:   Alert me  

Problem installing ActiveMQ 4.1.1 on Fedora 9

by Aidan :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi guys,

I'm trying to get ActiveMQ 4.1.1 working on my new Fedora 9 box. I am not a linux guru, so I think I've more than likely done something wrong.

I've followed the installation instructions from the Getting Started section of the manual (http://activemq.apache.org/getting-started.html#GettingStarted-StartingActiveMQ) however when I get to the step "Starting ActiveMQ" I get the following exception on the console:

ACTIVEMQ_HOME: /usr/local/apache-activemq-4.1.1
ACTIVEMQ_BASE: /usr/local/apache-activemq-4.1.1
Loading message broker from: xbean:activemq.xml
ERROR: java.lang.RuntimeException: Failed to execute start task. Reason: java.io.IOException: Could load xbean factory:java.io.IOException: Could not find factory class for resource: META-INF/services/org/apache/activemq/broker/xbean
java.lang.RuntimeException: Failed to execute start task. Reason: java.io.IOException: Could load xbean factory:java.io.IOException: Could not find factory class for resource: META-INF/services/org/apache/activemq/broker/xbean
   at org.apache.activemq.console.command.StartCommand.runTask(StartCommand.java:70)
   at org.apache.activemq.console.command.AbstractCommand.execute(AbstractCommand.java:50)
   at org.apache.activemq.console.command.ShellCommand.runTask(ShellCommand.java:82)
   at org.apache.activemq.console.command.AbstractCommand.execute(AbstractCommand.java:50)
   at org.apache.activemq.console.command.ShellCommand.main(ShellCommand.java:46)
   at java.lang.reflect.Method.invoke(libgcj.so.9)
   at org.apache.activemq.console.Main.runTaskClass(Main.java:202)
   at org.apache.activemq.console.Main.main(Main.java:91)
Caused by: java.io.IOException: Could load xbean factory:java.io.IOException: Could not find factory class for resource: META-INF/services/org/apache/activemq/broker/xbean
   at org.apache.activemq.util.IOExceptionSupport.create(IOExceptionSupport.java:25)
   at org.apache.activemq.broker.BrokerFactory.createBrokerFactoryHandler(BrokerFactory.java:43)
   at org.apache.activemq.broker.BrokerFactory.createBroker(BrokerFactory.java:56)
   at org.apache.activemq.console.command.StartCommand.startBroker(StartCommand.java:82)
   at org.apache.activemq.console.command.StartCommand.runTask(StartCommand.java:47)
   ...7 more
Caused by: java.io.IOException: Could not find factory class for resource: META-INF/services/org/apache/activemq/broker/xbean
   at org.apache.activemq.util.FactoryFinder.doFindFactoryProperies(FactoryFinder.java:90)
   at org.apache.activemq.util.FactoryFinder.newInstance(FactoryFinder.java:58)
   at org.apache.activemq.util.FactoryFinder.newInstance(FactoryFinder.java:47)
   at org.apache.activemq.broker.BrokerFactory.createBrokerFactoryHandler(BrokerFactory.java:41)
   ...10 more
ERROR: java.lang.Exception: java.io.IOException: Could load xbean factory:java.io.IOException: Could not find factory class for resource: META-INF/services/org/apache/activemq/broker/xbean
java.lang.Exception: java.io.IOException: Could load xbean factory:java.io.IOException: Could not find factory class for resource: META-INF/services/org/apache/activemq/broker/xbean
   at org.apache.activemq.console.command.StartCommand.runTask(StartCommand.java:71)
   at org.apache.activemq.console.command.AbstractCommand.execute(AbstractCommand.java:50)
   at org.apache.activemq.console.command.ShellCommand.runTask(ShellCommand.java:82)
   at org.apache.activemq.console.command.AbstractCommand.execute(AbstractCommand.java:50)
   at org.apache.activemq.console.command.ShellCommand.main(ShellCommand.java:46)
   at java.lang.reflect.Method.invoke(libgcj.so.9)
   at org.apache.activemq.console.Main.runTaskClass(Main.java:202)
   at org.apache.activemq.console.Main.main(Main.java:91)
Caused by: java.io.IOException: Could load xbean factory:java.io.IOException: Could not find factory class for resource: META-INF/services/org/apache/activemq/broker/xbean
   at org.apache.activemq.util.IOExceptionSupport.create(IOExceptionSupport.java:25)
   at org.apache.activemq.broker.BrokerFactory.createBrokerFactoryHandler(BrokerFactory.java:43)
   at org.apache.activemq.broker.BrokerFactory.createBroker(BrokerFactory.java:56)
   at org.apache.activemq.console.command.StartCommand.startBroker(StartCommand.java:82)
   at org.apache.activemq.console.command.StartCommand.runTask(StartCommand.java:47)
   ...7 more
Caused by: java.io.IOException: Could not find factory class for resource: META-INF/services/org/apache/activemq/broker/xbean
   at org.apache.activemq.util.FactoryFinder.doFindFactoryProperies(FactoryFinder.java:90)
   at org.apache.activemq.util.FactoryFinder.newInstance(FactoryFinder.java:58)
   at org.apache.activemq.util.FactoryFinder.newInstance(FactoryFinder.java:47)
   at org.apache.activemq.broker.BrokerFactory.createBrokerFactoryHandler(BrokerFactory.java:41)
   ...10 more

If I start the binary in the bin/linux folder in console mode I get a seperate exception:

jvm 1    | Caused by: java.lang.RuntimeException: error instantiating default server socket factory: java.security.KeyManagementException: java.security.KeyStoreException: gnu.javax.crypto.keyring.MalformedKeyringException: incorrect magic
jvm 1    |    at javax.net.ssl.SSLServerSocketFactory.getDefault(libgcj.so.9)
jvm 1    |    at org.apache.activemq.transport.tcp.SslTransportFactory.createServerSocketFactory(SslTransportFactory.java:174)
jvm 1    |    at org.apache.activemq.transport.tcp.SslTransportFactory.doBind(SslTransportFactory.java:81)
jvm 1    |    ...34 more
jvm 1    | Caused by: java.security.KeyManagementException: java.security.KeyStoreException: gnu.javax.crypto.keyring.MalformedKeyringException: incorrect magic
jvm 1    |    at gnu.javax.net.ssl.provider.SSLContextImpl.defaultTrustManager(libgcj.so.9)
jvm 1    |    at gnu.javax.net.ssl.provider.SSLContextImpl.engineInit(libgcj.so.9)
jvm 1    |    at javax.net.ssl.SSLContext.init(libgcj.so.9)
jvm 1    |    at javax.net.ssl.SSLServerSocketFactory.getDefault(libgcj.so.9)
jvm 1    |    ...36 more
jvm 1    | Caused by: java.security.KeyStoreException: gnu.javax.crypto.keyring.MalformedKeyringException: incorrect magic
jvm 1    |    at gnu.javax.net.ssl.provider.X509TrustManagerFactory.engineInit(libgcj.so.9)
jvm 1    |    at javax.net.ssl.TrustManagerFactory.init(libgcj.so.9)
jvm 1    |    at gnu.javax.net.ssl.provider.SSLContextImpl.defaultTrustManager(libgcj.so.9)
jvm 1    |    ...39 more
jvm 1    | Caused by: gnu.javax.crypto.keyring.MalformedKeyringException: incorrect magic
jvm 1    |    at gnu.javax.crypto.jce.keyring.GnuKeyring.loadPrivateKeyring(libgcj.so.9)
jvm 1    |    at gnu.javax.crypto.jce.keyring.GnuKeyring.engineLoad(libgcj.so.9)
jvm 1    |    at java.security.KeyStore.load(libgcj.so.9)
jvm 1    |    at gnu.javax.net.ssl.provider.X509TrustManagerFactory.engineInit(libgcj.so.9)
jvm 1    |    ...41 more

I have tried the windows version of the 4.1.1 release and the bat files start activemq just fine. The exceptions are generated if I try both as either my usual profile or if I run them as root.

The version of Java I am using on my Fedora box is :

java version "1.5.0"
gij (GNU libgcj) version 4.3.0 20080428 (Red Hat 4.3.0-8)

Sorry if I'm missing something, but I've followed the install instructions and I've tried fiddling with path's and chmod-ing directories but I can't get ActiveMQ started.

Thanks,

Aidan

Re: Problem installing ActiveMQ 4.1.1 on Fedora 9

by Aidan :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I just thought I'd throw some more information on what I've been doing to try and debug this, sorry if it's too much information, but somebody might be able to see what I am doing wrong...


I have tried running the run.jar in the bin folder, and that appears to start activemq just fine.

If I run a netstat -al | grep 61616 I find that there is a TCP socket listening:

tcp        0      0 *:61616                     *:*                         LISTEN

On a seperate client (Windows XP) I can ping the Fedora server and see it:

Pinging 192.168.0.100 with 32 bytes of data:

Reply from 192.168.0.100: bytes=32 time=2ms TTL=64
Reply from 192.168.0.100: bytes=32 time=2ms TTL=64
Reply from 192.168.0.100: bytes=32 time=2ms TTL=64
Reply from 192.168.0.100: bytes=32 time=2ms TTL=64

Ping statistics for 192.168.0.100:
    Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
    Minimum = 2ms, Maximum = 2ms, Average = 2ms

However when I try to start my ActiveMQ client it throws a java.net.NoRouteToHostException and won't continue running.

Re: Problem installing ActiveMQ 4.1.1 on Fedora 9

by Dejan Bosanac :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi,

This seems to me like GIJ related issues. Can you try using Sun JRE and see
what happens?

Regards
--
Dejan Bosanac
www.scriptinginjava.net

On Sat, Jul 19, 2008 at 11:21 AM, Aidan <aidan.morgan@...>
wrote:

>
> I just thought I'd throw some more information on what I've been doing to
> try
> and debug this, sorry if it's too much information, but somebody might be
> able to see what I am doing wrong...
>
>
> I have tried running the run.jar in the bin folder, and that appears to
> start activemq just fine.
>
> If I run a netstat -al | grep 61616 I find that there is a TCP socket
> listening:
>
> tcp        0      0 *:61616                     *:*
> LISTEN
>
> On a seperate client (Windows XP) I can ping the Fedora server and see it:
>
> Pinging 192.168.0.100 with 32 bytes of data:
>
> Reply from 192.168.0.100: bytes=32 time=2ms TTL=64
> Reply from 192.168.0.100: bytes=32 time=2ms TTL=64
> Reply from 192.168.0.100: bytes=32 time=2ms TTL=64
> Reply from 192.168.0.100: bytes=32 time=2ms TTL=64
>
> Ping statistics for 192.168.0.100:
>    Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
> Approximate round trip times in milli-seconds:
>    Minimum = 2ms, Maximum = 2ms, Average = 2ms
>
> However when I try to start my ActiveMQ client it throws a
> java.net.NoRouteToHostException and won't continue running.
> --
> View this message in context:
> http://www.nabble.com/Problem-installing-ActiveMQ-4.1.1-on-Fedora-9-tp18542730p18542766.html
>  Sent from the ActiveMQ - User mailing list archive at Nabble.com.
>
>
Dejan Bosanac


http://www.ttmsolutions.com - get a free ActiveMQ user guide

ActiveMQ in Action - http://www.manning.com/snyder/
Scripting in Java - http://www.scriptinginjava.net

Re: Problem installing ActiveMQ 4.1.1 on Fedora 9

by Aidan :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Thanks for the reply Dejan,

I switched to the Sun JDK and it works fine now. I should have noticed when I ran a yum install java that it was going to grab the GIJ version and not the Sun version.

Cheers,

Aidan

Dejan Bosanac wrote:
Hi,

This seems to me like GIJ related issues. Can you try using Sun JRE and see
what happens?

Regards
--
Dejan Bosanac
www.scriptinginjava.net
LightInTheBox - Buy quality products at wholesale price