Error upon updating sonarqube dev edition from v10.7 to LTA

Greetings,

I’m having trouble to update my docker base sonarqube instance from v10.7 to the latest version via docker.

I’ve been strictly following this guide, so I’ve just been stoping my sonarqube container, an relaunching with the same parameter (db password/link).

However, I get this message from the sonarqube container :

2025.03.18 14:54:59 INFO  web[][o.s.c.e.CoreExtensionsLoader] Loaded core extensions: developer-edition, developer-scanner, developer-server, github-provisioning, gitlab-provisioning, license, monitoring, gitlab-vulnerability-report
2025.03.18 14:54:59 WARN  web[][o.s.c.a.AnnotationConfigApplicationContext] Exception encountered during context initialization - cancelling refresh attempt: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'jdk.internal.loader.ClassLoaders$AppClassLoader@2c1156a7-org.sonar.server.platform.DatabaseServerCompatibility': Initialization of bean failed; nested exception is Database was upgraded to a more recent version of SonarQube. A backup must probably be restored or the DB settings are incorrect.
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'jdk.internal.loader.ClassLoaders$AppClassLoader@2c1156a7-org.sonar.server.platform.DatabaseServerCompatibility': Initialization of bean failed; nested exception is Database was upgraded to a more recent version of SonarQube. A backup must probably be restored or the DB settings are incorrect.

This error stop the container.

I did not change anything on the DB, I’ve only restart its container.

So I’m assuming that the version of the DB cannot be higher than the latest version of Sonarqubes (especially since this db was used for a 10.7 version). I think there is something else going on here.

Am I missing something here ? Should I do something on the database to update the instance ?

I’ve been told to be carefull with the database (it is backed up already) as my license is link to it.

Thanks in advance :grinning_face:

Hi,

This message indicates that at some point you did successfully upgrade SonarQube beyond the version that you’re trying to run now.

You need to figure out what SonarQube version your DB is at and move to or beyond that version. Given the message you’re getting, your procedure can’t possibly be invoking the “latest” version of SonarQube. Since your docs link points to an out-of-date version of the docs, your first step is probably to work from the latest docs version (altho TBH, the upgrade instructions rarely change).

 
HTH,
Ann

Hi G Ann,

Thnks for the answer it guide me toward resolution :

I was using a cached image of sonarqube:developper wich was most likely an old one causing the database to not be aligned with the version.

By using a more specific tag (2025.1-developper).I forced docker to get the newest one.

Thnks for the quick help.

Regards.

Maximilien;

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.