After upgrade to sonarqube 7.3 - Fail to load plugin License [license]


(Peter Brodt) #1

I upraded our sonarqube instance from 6.7.1 LTS to 7.3. Unfortunately I installed the communitiy edtion instead of the developer edition. Database upgrade was OK but Sonarqube failed to start.
I then installed the developer edition and now I get the following error.

2018.10.05 11:24:57 ERROR web[][o.s.s.p.Platform] Background initialization failed. Stopping SonarQube
java.lang.IllegalStateException: Fail to load plugin License [license]
at org.sonar.server.plugins.ServerExtensionInstaller.installExtensions(ServerExtensionInstaller.java:82)
at org.sonar.server.platform.platformlevel.PlatformLevel4.start(PlatformLevel4.java:586)
at org.sonar.server.platform.Platform.start(Platform.java:211)
at org.sonar.server.platform.Platform.startLevel34Containers(Platform.java:185)
at org.sonar.server.platform.Platform.access$500(Platform.java:46)
at org.sonar.server.platform.Platform$1.lambda$doRun$0(Platform.java:119)
at org.sonar.server.platform.Platform$AutoStarterRunnable.runIfNotAborted(Platform.java:371)
at org.sonar.server.platform.Platform$1.doRun(Platform.java:119)
at org.sonar.server.platform.Platform$AutoStarterRunnable.run(Platform.java:355)
at java.lang.Thread.run(Thread.java:748)
Caused by: java.lang.NoClassDefFoundError: org/sonar/server/computation/task/step/StatelessInitExtension
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:763)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:467)
at java.net.URLClassLoader.access$100(URLClassLoader.java:73)
at java.net.URLClassLoader$1.run(URLClassLoader.java:368)
at java.net.URLClassLoader$1.run(URLClassLoader.java:362)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:361)
at org.sonar.classloader.ClassRealm.loadClassFromSelf(ClassRealm.java:125)
at org.sonar.classloader.ParentFirstStrategy.loadClass(ParentFirstStrategy.java:37)
at org.sonar.classloader.ClassRealm.loadClass(ClassRealm.java:87)
at org.sonar.classloader.ClassRealm.loadClass(ClassRealm.java:76)
at com.sonarsource.license.plugin.L.A(Unknown Source)
at com.sonarsource.license.plugin.L.A(Unknown Source)
at com.sonarsource.license.plugin.L.define(Unknown Source)
at org.sonar.server.plugins.ServerExtensionInstaller.installExtensions(ServerExtensionInstaller.java:72)
… 9 common frames omitted
Caused by: java.lang.ClassNotFoundException: org.sonar.server.computation.task.step.StatelessInitExtension
at org.sonar.classloader.ParentFirstStrategy.loadClass(ParentFirstStrategy.java:39)
at org.sonar.classloader.ClassRealm.loadClass(ClassRealm.java:87)
at org.sonar.classloader.ClassRealm.loadClass(ClassRealm.java:76)
… 26 common frames omitted
2018.10.05 11:24:58 INFO web[][o.s.p.StopWatcher] Stopping process

I have installed the latest license plugins sonar-license-plugin-3.4.jar

Any ideas how to get rid of the error.

Peter


(G Ann Campbell) #2

Hi Peter,

When you did this upgrade, did you copy over the plugins from the previous version? From 7.2, we produce edition distributions (as you discovered) which contain within them all the pieces previously delivered by the additional edition bundles you added on top of the Community edition. Along the way, some licensing details also changed. That means that if you did copy over your old plugin set, you’re not just running duplicate license code, but one version is also incompatible.

Instead, it might be easier if you spun up a “clean” version of the 7.3 Developer Edition and then used the Marketplace to download the most recent versions of the plugins providing any missing functionality.

 
HTH,
Ann


(Peter Brodt) #3

Hi Ann,
thanks for you answer. I did copy the plugins from the previous version (it was 7.2 not 6.7 as I presumed).
When I setup a clean install of the 7.3 Developer Edtion, do I need to restore the database. It had been upgraded successfully with the 7.3 Community Edition though.

Peter


(G Ann Campbell) #4

Hi,

Since you do have a DB backup (Yay you for following directions! :smile:) I would just go ahead and attach my fresh Developer Edition. It’s possible that additional migrations could be required, but the fact that you did Community upgrades should not be a problem. The former is a super set of the latter.

 
HTH,
Ann