Confluence and the "felix-cache"

While evaluating confluence we faced two errors while starting our JIRA and Confluence test applications:

  1. "Unable to create and acquire lock file for jira.home directory ..jira/atlassian-jira-6.1.5-data"
    Solution:  Removed the file '.jira-home.lock' was owned by root:root.Retarted jira application as admin.
  2. "Unable to clean the cache directory: ..jira/atlassian-jira-6.1.5-data/plugins/.osgi-plugins/felix"
    Solution : Recursively changed the ownership from root to admin:users for "felix-cache" directory in the above path.


This happens some time later after a shutdown of the JIRA live system. We never faced the problem in the past, so it looks to me, this problem could be related to Confluence. 

I have also found this issue: https://jira.atlassian.com/browse/JRA-27438and, to be honest, I am surprised, why the status is "Awaiting Development". It looks more like, nothing has been done.

3 answers

1 accepted

2 votes

This sounds like someone started JIRA as "root" rather than the correct JIRA user, then stopped it, then you restarted it with the correct JIRA user.  It breaks because the first run by root took ownership of a lot of the files and hence the JIRA user can't function properly.  

You've hit on almost the right fix - stop JIRA and recursively change the ownership of everything in the JIRA home directory back to the JIRA user (not just cache, you may have issues with logs and temp files as well)

It's nothing to do with Confluence - basically, you shouldn't start the applications as root.

0 votes

Just as Nic suggested, for Confluence you need to start with the 'confluence' (or any dedicated user for the instance directories), but, also remember to remove the <confluence home>/plugins-osgi-cache/felix before attempting to restart with a new user, so we can avoid any mismatching of permissions in the instance. 


Some additional info through this Confluence KB.

Hey Jose,

As mentioned by Gran Answers Master @Nic Brough [Adaptavist], we are dealing with two separated questions. The current question, which was addressed  by Nic's answer, is not related to the other post. The home lock error is related to a permission over JIRA home directory and I don't see any scenarios were a Confluence would cause problems in there smile.

I would suggest you to edit the question to remove confluence references so it can match to a JIRA problem and then mark it as answered.

In case we are not undestanding correctly your findings please enligh us so we can provide further assistance wink

Thanks and Regards,
David| The Engineer that like Windows for realsies.

Suggest an answer

Log in or Join to answer
Community showcase
Sarah Schuster
Posted Jan 29, 2018 in Jira

What are common themes you've seen across successful & failed Jira Software implementations?

Hey everyone! My name is Sarah Schuster, and I'm a Customer Success Manager in Atlassian specializing in Jira Software Cloud. Over the next few weeks I will be posting discussion topics (8 total) to ...

2,867 views 12 18
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you
Atlassian Team Tour

Join us on the Team Tour

We're bringing product updates and pro tips on teamwork to ten cities around the world.

Save your spot