Apache-2.2

activemq apollo 創建代理錯誤

  • May 26, 2013

我一直在嘗試在我的 activemq apache-apollo 1.6 安裝上創建一個代理。當我執行以下命令時:

$APOLLO_HOME/bin/apollo create log1broker

我收到以下錯誤:

Exception in thread "main" java.lang.NoClassDefFoundError: /usr/local/lib64/activemq/apache-apollo-1/6
Caused by: java.lang.ClassNotFoundException: .usr.local.lib64.activemq.apache-apollo-1.6
   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)
Could not find the main class: /usr/local/lib64/activemq/apache-apollo-1.6. Program will exit.

發生這種情況是因為apollo啟動腳本假定您PWD$APOLLO_HOME.

請按以下順序執行:

$ cd $APOLLO_HOME
$ ./bin/apollo create log1broker

引用自:https://serverfault.com/questions/510748