Hello Damien,

> Could you please compare exact command line of working vs not-working
> ActiveMQ configuration ?

I have done more testing in this, here is my result.

I have done all stuff with an clean Debian 64bit sid on virtualbox.

cp /etc/default/activemq /etc/default/activemq-mcollective

cp -R  /etc/activemq/main /etc/activemq/mcollective

rm -rf /etc/activemq/mcollective/activemq.xml

wget
https://raw.github.com/gist/1115895/b208b21ac8b76f78210a07c453b9b16d3786f228/gistfile1.txt
-O /etc/activemq/mcollective/activemq.xml 

ln -s /etc/init.d/activemq /etc/init.d/activemq-mcollective

invoke-rc.d activemq-mcollective start

I found that in the log file:

2011-07-30 21:35:04,587 | INFO  | Database
activemq-data/localhost/KahaDB/lock is locked... waiting 10 seconds for
the database to be unlocked. Reason: java.io.IOException: Failed to
create directory 'activemq-data/localhost/KahaDB' |
org.apache.activemq.store.kahadb.MessageDatabase | main


So the activeMQ tries to write to 
        
        /var/lib/activemq/activemq-data/localhost/KahaDB/

but does this with an relative path.

If I patch the init-script to chdir first to /var/lib/activemq, it
works:

diff -u /etc/init.d/activemq.orig /etc/init.d/activemq
--- /etc/init.d/activemq.orig   2011-07-30 21:43:32.710743516 +0200
+++ /etc/init.d/activemq        2011-07-30 21:43:19.606744213 +0200
@@ -132,6 +132,7 @@
         chown $ACTIVEMQ_USER /var/run/activemq/
         start-stop-daemon --start --quiet --pidfile $ACTIVEMQ_PIDFILE \
                     --chuid $ACTIVEMQ_USER --background \
+                    -d /var/lib/activemq \
                     --name java --startas $DAEMON -- $ACTIVEMQ_ARGS
         errcode=$?
         return $errcode

After that patch activeMQ starts and opens the TCP port.


But I found an other problem, when I try to start the ActiveMQ Instance
onboot:

root@sid:~# update-rc.d activemq-mcollective defaults
update-rc.d activemq-mcollective defaults
update-rc.d: using dependency based boot sequencing
insserv: script activemq-mcollective: service activemq already provided!
insserv: exiting now!
update-rc.d: error: insserv rejected the script header

Thanks for your work,

                Jonas

Attachment: signature.asc
Description: PGP signature

__
This is the maintainer address of Debian's Java team
<http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-java-maintainers>. 
Please use
debian-j...@lists.debian.org for discussions and questions.

Reply via email to