ActiveMQ 啟動異常

來源:互聯網
上載者:User

   在按照 《ActiveMQ in Action》的操作步驟進行操作的時候,ActiveMQ異常終止後,總是不能啟動,總是在報錯誤。

2012-03-14 14:45:13,552 | ERROR | Failed to start ActiveMQ JMS Message Broker. Reason: java.io.EOFException: Chunk stream does not exist at page: 0 | org.apache.activemq.broker.BrokerService | main
java.io.EOFException: Chunk stream does not exist at page: 0
    at org.apache.kahadb.page.Transaction$2.readPage(Transaction.java:454)
    at org.apache.kahadb.page.Transaction$2.<init>(Transaction.java:431)
    at org.apache.kahadb.page.Transaction.openInputStream(Transaction.java:428)
    at org.apache.kahadb.page.Transaction.load(Transaction.java:404)
    at org.apache.kahadb.page.Transaction.load(Transaction.java:361)
    at org.apache.activemq.broker.scheduler.JobSchedulerStore$3.execute(JobSchedulerStore.java:250)
    at org.apache.kahadb.page.Transaction.execute(Transaction.java:728)
    at org.apache.activemq.broker.scheduler.JobSchedulerStore.doStart(JobSchedulerStore.java:239)
    at org.apache.activemq.util.ServiceSupport.start(ServiceSupport.java:53)
    at org.apache.activemq.broker.scheduler.SchedulerBroker.getStore(SchedulerBroker.java:198)
    at org.apache.activemq.broker.scheduler.SchedulerBroker.getInternalScheduler(SchedulerBroker.java:185)
    at org.apache.activemq.broker.scheduler.SchedulerBroker.start(SchedulerBroker.java:85)


經過搜尋了之後,悲催的發現這個是ActiveMQ5.4.1的一個bug。在5.5裡面給解決了。

its a known bug and fixed in current trunk (5.5-SNAPSHOT).

https://issues.apache.org/jira/browse/AMQ-2935

    但是為了避免在學習的過程中,因為版本不匹配等原因產生問題,於是繼續搜尋,終於找到瞭解決辦法。主要是由於 5.4.1 這個版本引入延遲發送的功能引起的, 解決辦法是在<broker>中添加 schedulerSupport="false" 屬性,禁掉scheduler功能。

參照文章http://blog.csdn.net/technofantasy/article/details/6037295

 

代碼

 

<broker xmlns="http://activemq.apache.org/schema/core " brokerName="SIBBusModule-TestDeCharge-td0sib01s" useJmx="true" persistent="false" useShutdownHook="false" schedulerSupport="false" >

 

還有就是刪除activemq目錄下的data/xxxx/scheduler 下的所有內容,不過這種我沒有嘗試

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.