ActiveMQ启动报错,大家帮忙看下

红叔 发布于 2014/07/03 11:30
阅读 8K+
收藏 0

2014-07-03 10:42:38,178 | ERROR | Failed to load: class path resource [activemq.xml], reason: Error creating bean with name 'org.apache.activemq.xbean.XBeanBrokerService#0' defined in class path resource [activemq.xml]: Invocation of init method failed; nested exception is java.lang.OutOfMemoryError: Java heap space | org.apache.activemq.xbean.XBeanBrokerFactory | main

org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.apache.activemq.xbean.XBeanBrokerService#0' defined in class path resource [activemq.xml]: Invocation of init method failed; nested exception is java.lang.OutOfMemoryError: Java heap space

at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1512)

at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:521)

at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:458)

at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:296)

at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:223)

at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:293)

at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:194)

at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:628)

at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:932)

at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:479)

at org.apache.xbean.spring.context.ResourceXmlApplicationContext.<init>(ResourceXmlApplicationContext.java:64)

at org.apache.xbean.spring.context.ResourceXmlApplicationContext.<init>(ResourceXmlApplicationContext.java:52)

at org.apache.activemq.xbean.XBeanBrokerFactory$1.<init>(XBeanBrokerFactory.java:104)

at org.apache.activemq.xbean.XBeanBrokerFactory.createApplicationContext(XBeanBrokerFactory.java:104)

at org.apache.activemq.xbean.XBeanBrokerFactory.createBroker(XBeanBrokerFactory.java:67)

at org.apache.activemq.broker.BrokerFactory.createBroker(BrokerFactory.java:71)

at org.apache.activemq.broker.BrokerFactory.createBroker(BrokerFactory.java:54)

at org.apache.activemq.console.command.StartCommand.runTask(StartCommand.java:87)

at org.apache.activemq.console.command.AbstractCommand.execute(AbstractCommand.java:57)

at org.apache.activemq.console.command.ShellCommand.runTask(ShellCommand.java:150)

at org.apache.activemq.console.command.AbstractCommand.execute(AbstractCommand.java:57)

at org.apache.activemq.console.command.ShellCommand.main(ShellCommand.java:104)

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

at java.lang.reflect.Method.invoke(Method.java:606)

at org.apache.activemq.console.Main.runTaskClass(Main.java:262)

at org.apache.activemq.console.Main.main(Main.java:115)

Caused by: java.lang.OutOfMemoryError: Java heap space

at org.apache.activemq.store.kahadb.disk.journal.DataFileAccessor.readRecord(DataFileAccessor.java:87)

at org.apache.activemq.store.kahadb.disk.journal.Journal.read(Journal.java:604)

at org.apache.activemq.store.kahadb.MessageDatabase.load(MessageDatabase.java:996)

at org.apache.activemq.store.kahadb.MessageDatabase.recoverAckMessageFileMap(MessageDatabase.java:691)

at org.apache.activemq.store.kahadb.MessageDatabase.recover(MessageDatabase.java:582)

at org.apache.activemq.store.kahadb.MessageDatabase.open(MessageDatabase.java:398)

at org.apache.activemq.store.kahadb.MessageDatabase.load(MessageDatabase.java:416)

at org.apache.activemq.store.kahadb.MessageDatabase.doStart(MessageDatabase.java:260)

at org.apache.activemq.store.kahadb.KahaDBStore.doStart(KahaDBStore.java:194)

at org.apache.activemq.util.ServiceSupport.start(ServiceSupport.java:55)

at org.apache.activemq.store.kahadb.KahaDBPersistenceAdapter.doStart(KahaDBPersistenceAdapter.java:215)

at org.apache.activemq.util.ServiceSupport.start(ServiceSupport.java:55)

at org.apache.activemq.broker.BrokerService.doStartPersistenceAdapter(BrokerService.java:640)

at org.apache.activemq.broker.BrokerService.startPersistenceAdapter(BrokerService.java:629)

at org.apache.activemq.broker.BrokerService.start(BrokerService.java:594)

at org.apache.activemq.xbean.XBeanBrokerService.afterPropertiesSet(XBeanBrokerService.java:73)

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

at java.lang.reflect.Method.invoke(Method.java:606)

at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeCustomInitMethod(AbstractAutowireCapableBeanFactory.java:1638)

at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1579)

at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1509)

at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:521)

at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:458)

at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:296)

at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:223)

at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:293)

at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:194)

at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:628)

at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:932)

at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:479)

加载中
0
sdzzboy
sdzzboy
JVM heap溢出?放大heap size试试
0
红叔
红叔
执行java -Xms1024m -Xmx4096m memory 报无法修改... 把ActiveMQ重新部署后启动成功,原因还是没找到,剩余内存不小了。
0
大工牛奶
大工牛奶
是不是 kahadb里面存的 topic、queue 或者持久化的message太多了
0
红叔
红叔
初步判断是因为activemq.xml文件编辑的时候标签弄乱了。
0
kimmking
kimmking
发出来jvm参数看看
0
段壮壮
楼主,请问你这个问题解决了么?当初是什么原因导致又是如何解决的呢?
0
ksMeet
ksMeet
我也遇到了这个问题,最后发现是mysql的驱动的问题,我换了个更高版本的驱动就好了。
0
nibaba2
nibaba2

有可能是配的持久化问题

返回顶部
顶部