Hi, > in the bin/karaf script, can you confirm that you have something like: > > exec “$JAVA” […]
Yes. > Do you define some env variables like KARAF_BASE/KARAF_HOME/KARAF_ETC, ? I tried both. Same results. > A possible cause is that KARAF_HOME is not well setted or a CLASSPATH system > variable interfere. In bin/karaf, we do: > > for file in "$KARAF_HOME"/lib/karaf*.jar > do > if [ -z "$CLASSPATH" ]; then > CLASSPATH="$file" > else > CLASSPATH="$CLASSPATH:$file" > fi > done > to load the karaf*.jar file from the Karaf lib folder. Yes, I can see this in the bin/karaf file. For the fun of it, I added the line “echo $file” in the for loop. In the output, all I see is “/usr/local/lib/karaf*.jar. Weird. Cheers, =David > On 10/13/2014 01:56 PM, David Leangen wrote: >> >>> Really weird, >> >> :-) >> >> >>> Can you do a java -version and send the result. >> >> java version "1.7.0_67" >> Java(TM) SE Runtime Environment (build 1.7.0_67-b01) >> Java HotSpot(TM) 64-Bit Server VM (build 24.65-b04, mixed mode) >> >>> Can you also send the data/log/karaf.log to me ? >> >> There is no file (assuming that it is in $KARAF_HOME, i.e. the directory >> where Karaf is installed). >> >> Cheers, >> =David >> >> >> >>> On 10/13/2014 01:47 PM, David Leangen wrote: >>>> >>>>> It looks like the lib folder doesn’t contain the karaf-jmx-boot.jar >>>>> file (providing the MBeanServerBuilder). >>>>> Can you check that this jar is in the lib folder ? >>>> >>>> Yes, it is there. >>>> >>>>> Do you have something in bin/setenv ? >>>> >>>> No, using defaults. >>>> >>>>> By the way, can you try with Java7 (instead of Java6) ? >>>> >>>> I installed Java7. Same problem. :-( >>>> >>>> >>>> Cheers, >>>> =David >>>> >>>> >>>> >>>>> On 10/13/2014 10:39 AM, David Leangen wrote: >>>>>> >>>>>> Wow! Impressive response. :-) Thank you! >>>>>> >>>>>>> Can you make a try with 3.0.2 (currently on staging) ? >>>>>> >>>>>> Tried. Same problem. :-( >>>>>> >>>>>>> which version of Java are you using? >>>>>>> Please note with Karaf 3.0.1 it's still recommended to use Java7 >>>>>> >>>>>> Hmmm. I am still a luddite with 1.6 (more precisely >>>>>> 1.6.0_65-b14-462-11M4609). >>>>>> >>>>>>> I’m running 3.0.1 on Mac out of the box. You’ll likely need to >>>>>>> describe more about your circumstances, e.g. the JVM used, what >>>>>>> commands you’ve run (to start Karaf and at it’s own command line), >>>>>>> what bundles you’ve installed (if any), the complete stack trace, etc? >>>>>> >>>>>> I ran “karaf” with the default (i.e. “out-of-the-box”) >>>>>> installation, and >>>>>> before Karaf could start, it died with the following: >>>>>> >>>>>> *$ karaf* >>>>>> javax.management.JMRuntimeException: Failed to load MBeanServerBuilder >>>>>> class org.apache.karaf.management.boot.KarafMBeanServerBuilder: >>>>>> java.lang.ClassNotFoundException: >>>>>> org.apache.karaf.management.boot.KarafMBeanServerBuilder >>>>>> at >>>>>> javax.management.MBeanServerFactory.checkMBeanServerBuilder(MBeanServerFactory.java:481) >>>>>> at >>>>>> javax.management.MBeanServerFactory.getNewMBeanServerBuilder(MBeanServerFactory.java:512) >>>>>> at >>>>>> javax.management.MBeanServerFactory.newMBeanServer(MBeanServerFactory.java:299) >>>>>> at >>>>>> javax.management.MBeanServerFactory.createMBeanServer(MBeanServerFactory.java:214) >>>>>> at >>>>>> javax.management.MBeanServerFactory.createMBeanServer(MBeanServerFactory.java:175) >>>>>> at >>>>>> sun.management.ManagementFactory.createPlatformMBeanServer(ManagementFactory.java:302) >>>>>> at >>>>>> java.lang.management.ManagementFactory.getPlatformMBeanServer(ManagementFactory.java:504) >>>>>> at >>>>>> sun.management.jmxremote.ConnectorBootstrap.startLocalConnectorServer(ConnectorBootstrap.java:458) >>>>>> at sun.management.Agent.startAgent(Agent.java:135) >>>>>> at sun.management.Agent.startAgent(Agent.java:239) >>>>>> Caused by: java.lang.ClassNotFoundException: >>>>>> org.apache.karaf.management.boot.KarafMBeanServerBuilder >>>>>> at java.net.URLClassLoader$1.run(URLClassLoader.java:202) >>>>>> at java.security.AccessController.doPrivileged(Native Method) >>>>>> at java.net.URLClassLoader.findClass(URLClassLoader.java:190) >>>>>> at java.lang.ClassLoader.loadClass(ClassLoader.java:306) >>>>>> at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301) >>>>>> at java.lang.ClassLoader.loadClass(ClassLoader.java:247) >>>>>> at >>>>>> javax.management.MBeanServerFactory.loadBuilderClass(MBeanServerFactory.java:424) >>>>>> at >>>>>> javax.management.MBeanServerFactory.checkMBeanServerBuilder(MBeanServerFactory.java:466) >>>>>> ... 9 more >>>>>> Exception thrown by the agent : javax.management.JMRuntimeException: >>>>>> Failed to load MBeanServerBuilder class >>>>>> org.apache.karaf.management.boot.KarafMBeanServerBuilder: >>>>>> java.lang.ClassNotFoundException: >>>>>> org.apache.karaf.management.boot.KarafMBeanServerBuilder >>>>>> >>>>>> >>>>>> Cheers, >>>>>> =David >>>>>> >>>>>> >>>>>>> On 10/13/2014 10:15 AM, David Leangen wrote: >>>>>>>> >>>>>>>> Hi! >>>>>>>> >>>>>>>> I am new to Karaf. I am trying to set up v3.0.1 on my Mac, but am >>>>>>>> getting a JMRuntimeException: Failed to load MBeanServerBuilder. >>>>>>>> >>>>>>>> I noticed this thread: >>>>>>>> >>>>>>>> http://mail-archives.apache.org/mod_mbox/karaf-user/201404.mbox/%3ccagrrcrxmqe-v65jecwpakmatc6qap+hvyb_abmgxk8zpvko...@mail.gmail.com%3E >>>>>>>> <http://mail-archives.apache.org/mod_mbox/karaf-user/201404.mbox/<cagrrcrxmqe-v65jecwpakmatc6qap+hvyb_abmgxk8zpvko...@mail.gmail.com>> >>>>>>>> >>>>>>>> >>>>>>>> However, it does not seem to be relevant to me, and I did not >>>>>>>> find any >>>>>>>> other reference to this problem. >>>>>>>> >>>>>>>> Assuming that Karaf is intended to run out of the box, is there a >>>>>>>> quick >>>>>>>> recommended fix for this? >>>>>>>> >>>>>>>> >>>>>>>> Cheers, >>>>>>>> =David >>>>>>>> >>>>>> >>>>> >>>>> -- >>>>> Jean-Baptiste Onofré >>>>> [email protected] <mailto:[email protected]> >>>>> <mailto:[email protected]> >>>>> http://blog.nanthrax.net >>>>> Talend - http://www.talend.com >>>> >>> >>> -- >>> Jean-Baptiste Onofré >>> [email protected] <mailto:[email protected]> >>> http://blog.nanthrax.net >>> Talend - http://www.talend.com >> > > -- > Jean-Baptiste Onofré > [email protected] > http://blog.nanthrax.net > Talend - http://www.talend.com
