Unable to start the plugin container / OSGi cache corruption in Bitbucket
In some cases after a Bitbucket upgrade or an App upgrade, users may experience cache corruption of Bitbucket.
To resolve this problem you should clear the Bitbucket Server plugin cache, which will cause Bitbucket Server to rebuild plugin cache from scratch next time it starts.
Error (there are other variations)
c.a.plugin.osgi.factory.OsgiPlugin Unable to start the plugin container for plugin
org.springframework.beans.factory.BeanDefinitionStoreException: Unexpected exception parsing XML document from URL bundle://138.0:0/META-INF/spring/atlassian-plugins-component-imports.xml
nested exception is java.lang.IllegalStateException: The bundle is uninstalled.
Solution
- Stop Bitbucket
- Delete the following directories (where
<Bitbucket_Home_Directory>
refers to the Bitbucket home directory, for instance /var/atlassian/application-data/bitbucket:<Bitbucket_Home_Directory>/plugins/.bundled-plugins
<Bitbucket_Home_Directory>/plugins/.osgi-cache
- Restart Bitbucket
Related articles
SONAR™, SONARQUBE™ and SONARCLOUD™ are independent and trademarked products and services of SonarSource SA: see sonarsource.com, sonarqube.org, sonarcloud.io.