ActiveMQ启动报错:java.lang.IllegalStateException: LifecycleProcessor not initialized - call 'refresh' be

末蓝、 2022-06-01 14:07 645阅读 0赞

一、问题描述

一启动ActiveMQ就报错:

  1. ERROR: java.lang.RuntimeException: Failed to execute start task. Reason: java.lang.IllegalStateException: BeanFactory not initialized or already closed - call 'refresh' before accessing beans via the ApplicationContext
  2. jvm 1 | java.lang.RuntimeException: Failed to execute start task. Reason: java.lang.IllegalStateException: BeanFactory not initialized or already closed - call 'refresh' before accessing beans via the ApplicationContext
  3. jvm 1 | at org.apache.activemq.console.command.StartCommand.runTask(StartCommand.java:91)
  4. jvm 1 | at org.apache.activemq.console.command.AbstractCommand.execute(AbstractCommand.java:63)
  5. jvm 1 | at org.apache.activemq.console.command.ShellCommand.runTask(ShellCommand.java:154)
  6. jvm 1 | at org.apache.activemq.console.command.AbstractCommand.execute(AbstractCommand.java:63)
  7. jvm 1 | at org.apache.activemq.console.command.ShellCommand.main(ShellCommand.java:104)
  8. jvm 1 | at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
  9. jvm 1 | at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
  10. jvm 1 | at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
  11. jvm 1 | at java.lang.reflect.Method.invoke(Method.java:498)
  12. jvm 1 | at org.apache.activemq.console.Main.runTaskClass(Main.java:262)
  13. jvm 1 | at org.apache.activemq.console.Main.main(Main.java:115)
  14. jvm 1 | at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
  15. jvm 1 | at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
  16. jvm 1 | at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
  17. jvm 1 | at java.lang.reflect.Method.invoke(Method.java:498)
  18. jvm 1 | at org.tanukisoftware.wrapper.WrapperSimpleApp.run(WrapperSimpleApp.java:240)
  19. jvm 1 | at java.lang.Thread.run(Thread.java:748)
  20. jvm 1 | Caused by: java.lang.IllegalStateException: BeanFactory not initialized or already closed - call 'refresh' before accessing beans via the ApplicationContext
  21. jvm 1 | at org.springframework.context.support.AbstractRefreshableApplicationContext.getBeanFactory(AbstractRefreshableApplicationContext.java:170)
  22. jvm 1 | at org.springframework.context.support.AbstractApplicationContext.destroyBeans(AbstractApplicationContext.java:1030)
  23. jvm 1 | at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:556)
  24. jvm 1 | at org.apache.xbean.spring.context.ResourceXmlApplicationContext.<init>(ResourceXmlApplicationContext.java:64)
  25. jvm 1 | at org.apache.xbean.spring.context.ResourceXmlApplicationContext.<init>(ResourceXmlApplicationContext.java:52)
  26. jvm 1 | at org.apache.activemq.xbean.XBeanBrokerFactory$1.<init>(XBeanBrokerFactory.java:104)
  27. jvm 1 | at org.apache.activemq.xbean.XBeanBrokerFactory.createApplicationContext(XBeanBrokerFactory.java:104)
  28. jvm 1 | at org.apache.activemq.xbean.XBeanBrokerFactory.createBroker(XBeanBrokerFactory.java:67)
  29. jvm 1 | at org.apache.activemq.broker.BrokerFactory.createBroker(BrokerFactory.java:71)
  30. jvm 1 | at org.apache.activemq.broker.BrokerFactory.createBroker(BrokerFactory.java:54)
  31. jvm 1 | at org.apache.activemq.console.command.StartCommand.runTask(StartCommand.java:87)
  32. jvm 1 | ... 16 more
  33. jvm 1 | ERROR: java.lang.IllegalStateException: BeanFactory not initialized or already closed - call 'refresh' before accessing beans via the ApplicationContext
  34. jvm 1 | java.lang.IllegalStateException: BeanFactory not initialized or already closed - call 'refresh' before accessing beans via the ApplicationContext
  35. jvm 1 | at org.springframework.context.support.AbstractRefreshableApplicationContext.getBeanFactory(AbstractRefreshableApplicationContext.java:170)
  36. jvm 1 | at org.springframework.context.support.AbstractApplicationContext.destroyBeans(AbstractApplicationContext.java:1030)
  37. jvm 1 | at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:556)
  38. jvm 1 | at org.apache.xbean.spring.context.ResourceXmlApplicationContext.<init>(ResourceXmlApplicationContext.java:64)
  39. jvm 1 | at org.apache.xbean.spring.context.ResourceXmlApplicationContext.<init>(ResourceXmlApplicationContext.java:52)
  40. jvm 1 | at org.apache.activemq.xbean.XBeanBrokerFactory$1.<init>(XBeanBrokerFactory.java:104)
  41. jvm 1 | at org.apache.activemq.xbean.XBeanBrokerFactory.createApplicationContext(XBeanBrokerFactory.java:104)
  42. jvm 1 | at org.apache.activemq.xbean.XBeanBrokerFactory.createBroker(XBeanBrokerFactory.java:67)
  43. jvm 1 | at org.apache.activemq.broker.BrokerFactory.createBroker(BrokerFactory.java:71)
  44. jvm 1 | at org.apache.activemq.broker.BrokerFactory.createBroker(BrokerFactory.java:54)
  45. jvm 1 | at org.apache.activemq.console.command.StartCommand.runTask(StartCommand.java:87)
  46. jvm 1 | at org.apache.activemq.console.command.AbstractCommand.execute(AbstractCommand.java:63)
  47. jvm 1 | at org.apache.activemq.console.command.ShellCommand.runTask(ShellCommand.java:154)
  48. jvm 1 | at org.apache.activemq.console.command.AbstractCommand.execute(AbstractCommand.java:63)
  49. jvm 1 | at org.apache.activemq.console.command.ShellCommand.main(ShellCommand.java:104)
  50. jvm 1 | at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
  51. jvm 1 | at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
  52. jvm 1 | at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
  53. jvm 1 | at java.lang.reflect.Method.invoke(Method.java:498)
  54. jvm 1 | at org.apache.activemq.console.Main.runTaskClass(Main.java:262)
  55. jvm 1 | at org.apache.activemq.console.Main.main(Main.java:115)
  56. jvm 1 | at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
  57. jvm 1 | at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
  58. jvm 1 | at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
  59. jvm 1 | at java.lang.reflect.Method.invoke(Method.java:498)
  60. jvm 1 | at org.tanukisoftware.wrapper.WrapperSimpleApp.run(WrapperSimpleApp.java:240)
  61. jvm 1 | at java.lang.Thread.run(Thread.java:748)
  62. wrapper | <-- Wrapper Stopped

二、解决方法

查看data目录下的日志

SouthEast

发现一个关键字: JVM_Bind

  1. java.io.IOException: Transport Connector could not be registered in JMX: java.io.IOException: Failed to bind to server socket: amqp://0.0.0.0:5672?maximumConnections=1000&wireFormat.maxFrameSize=104857600 due to: java.net.BindException: Address already in use: JVM_Bind

端口冲突。。然后通过TCPVIEW关闭该进程就行了。

发表评论

表情:
评论列表 (有 0 条评论,645人围观)

还没有评论,来说两句吧...

相关阅读