Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Unable to start bitbucket

Ajay_Pratap August 20, 2019

I am using bit bucket server 4.9.1

It was running smoothly. it suddenly showed unable to connect to database.

I restarted the dabatabse service and  bitbucket service.  and getting  the following error:

2019-08-21 09:56:01,466 ERROR [spring-startup] c.a.j.s.w.s.JohnsonDispatcherServlet SpringMVC dispatcher [springMvc] could not be started
org.springframework.context.ApplicationContextException: Failed to start bean 'pluginSystemLifecycle'; nested ex
ception is java.lang.IllegalArgumentException: The plugin key '${atlassian.plugin.key}' must either match the OSGi bundle symbolic name (Bundle-SymbolicName) or be specified in the Atlassian-Plugin-Key manifest header
at org.springframework.context.support.DefaultLifecycleProcessor.doStart(DefaultLifecycleProcessor.java:176) ~[spring-context-4.3.0.RELEASE.jar:4.3.0.RELEASE]
at org.springframework.context.support.DefaultLifecycleProcessor.access$200(DefaultLifecycleProcessor.java:51) ~[spring-context-4.3.0.RELEASE.jar:4.3.0.RELEASE]
at org.springframework.context.support.DefaultLifecycleProcessor$LifecycleGroup.start(DefaultLifecycleProcessor.java:346) ~[spring-context-4.3.0.RELEASE.jar:4.3.0.RELEASE]
at org.springframework.context.support.DefaultLifecycleProcessor.startBeans(DefaultLifecycleProcessor.java:149) ~[spring-context-4.3.0.RELEASE.jar:4.3.0.RELEASE]
at org.springframework.context.support.DefaultLifecycleProcessor.onRefresh(DefaultLifecycleProcessor.java:112) ~[spring-context-4.3.0.RELEASE.jar:4.3.0.RELEASE]
at org.springframework.context.support.AbstractApplicationContext.finishRefresh(AbstractApplicationContext.java:874) ~[spring-context-4.3.0.RELEASE.jar:4.3.0.RELEASE]
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:544) ~[spring-context-4.3.0.RELEASE.jar:4.3.0.RELEASE]
at javax.servlet.GenericServlet.init(GenericServlet.java:158) [servlet-api.jar:3.1.FR]
at java.lang.Thread.run(Thread.java:745) [na:1.8.0_25]
... 8 frames trimmed
Caused by: java.lang.IllegalArgumentException: The plugin key '${atlassian.plugin.key}' must either match the OSGi bundle symbolic name (Bundle-SymbolicName) or be specified in the Atlassian-Plugin-Key manifest header
at com.atlassian.plugin.osgi.factory.OsgiPluginUninstalledHelper.install(OsgiPluginUninstalledHelper.java:47) ~[atlassian-plugins-osgi-4.2.4.jar:na]
at com.atlassian.plugin.impl.AbstractPlugin.install(AbstractPlugin.java:424) ~[atlassian-plugins-core-4.2.4.jar:na]
at com.atlassian.plugin.manager.DefaultPluginManager.addPlugins(DefaultPluginManager.java:1167) ~[atlassian-plugins-core-4.2.4.jar:na]
at com.atlassian.stash.internal.plugin.StashPluginManager.addPlugins(StashPluginManager.java:137) ~[bitbucket-platform-4.9.1.jar:na]
at com.atlassian.plugin.manager.DefaultPluginManager.earlyStartup(DefaultPluginManager.java:586) ~[atlassian-plugins-core-4.2.4.jar:na]
at com.atlassian.stash.internal.plugin.StashPluginManager.lambda$earlyStartup$0(StashPluginManager.java:102) ~[bitbucket-platform-4.9.1.jar:na]
at com.atlassian.stash.internal.plugin.StashPluginManager$$Lambda$83/8671446.run(Unknown Source) ~[na:na]
at com.atlassian.stash.internal.plugin.PluginUpgradeHelper.withUpgrade(PluginUpgradeHelper.java:86) ~[bitbucket-platform-4.9.1.jar:na]
at com.atlassian.stash.internal.plugin.StashPluginManager.earlyStartup(StashPluginManager.java:102) ~[bitbucket-platform-4.9.1.jar:na]
at com.atlassian.plugin.manager.DefaultPluginManager.init(DefaultPluginManager.java:516) ~[atlassian-plugins-core-4.2.4.jar:na]
at com.atlassian.stash.internal.plugin.SpringPluginSystemLifecycle.start(SpringPluginSystemLifecycle.java:35) ~[bitbucket-platform-4.9.1.jar:na]
at org.springframework.context.support.DefaultLifecycleProcessor.doStart(DefaultLifecycleProcessor.java:173) ~[spring-context-4.3.0.RELEASE.jar:4.3.0.RELEASE]
... 9 common frames omitted
:

 

 

Please help.. This is causing critical downtime.

1 answer

0 votes
Caterina Curti
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
November 21, 2019

Hi Ajay,

Similar issues are usually caused by a problem with a plugin.

 

This is the key message from the logs:

The plugin key '${atlassian.plugin.key}' must either match the OSGi bundle symbolic name (Bundle-SymbolicName) or be specified in the Atlassian-Plugin-Key manifest header

 

To identify which plugin is causing the problem, we need to enable debug log in Bitbucket by adding the following to the bitbucket.properties file:

logging.logger.ROOT=DEBUG
logging.logger.com.atlassian.bitbucket=DEBUG

 

You can then look for the following in the atlassian-bitbucket.log file:

DEBUG [spring-startup]  c.a.p.o.f.OsgiPluginUninstalledHelper Installing OSGi plugin '<Bitbucket home directory>/shared/plugins/installed-plugins/plugin_8442591682369368611_conflicting_plugin-1.0.0-SNAPSHOT.jar'
INFO  [FelixDispatchQueue]  c.a.p.o.c.f.FelixOsgiContainerManager Installed bundle com.test.bitbucket.plugin.conflicting_plugin (25)
WARN  [spring-startup]  o.s.w.c.s.XmlWebApplicationContext Exception encountered during context initialization - cancelling refresh attempt: org.springframework.context.ApplicationContextException: Failed to start bean 'pluginSystemLifecycle';

 

Locate the line with the "Exception encountered during context initialization - cancelling refresh attempt error" and find the first DEBUG line above it.
This line shows the full path of the plugin which is causing the problem.

 

To resolve the problem, we need to remove the plugin or move it to a folder outside of the Bitbucket home folder.

 

Caterina

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events