ActiveMQ KahaDB always locking and waiting ActiveMQ KahaDB always locking and waiting multithreading multithreading

ActiveMQ KahaDB always locking and waiting


do following

kill java process for active mq, open task manager -> go to process -> check for java -> and right click and say end process

then go to <activemq_install_directory>/data/kahadb

and delete lock file which gets generated

try starting activemq again

for me this works every time I face this issue


had the same problem.there was no other java services / brokers up and running.the problem was pretty stupid -

make sure that the user you are using has permission to write to the path of the lock file.


The only solution I came across to release this lock is-

  1. Goto services.msc
  2. Stop ActiveMQ forever (let StartUp type be Automatic)
  3. you will see that the lock file disappears
  4. delete the datafolder itself
  5. Restart apache-activemq-5.10.0-bin\apache-activemq-5.10.0\bin\win64\activemq.bat (Not services.msc)
  6. You are good to go