Sonarqube-10.1.0.73491 fails to start after postgres upgrade to 15.4

I had sonarqube-10.1.0.73491 working fine with postgresql 15.3. I recently upgrade to postgres 15.4 but since then sonar fails to start.

Java: jdk-17.0.6
OS: redhat linux

All startup logs are attached.
es.log (14.9 KB)
nohup.log (2.8 KB)
sonar.log (4.7 KB)
web.log (23.3 KB)

I tried multiple cleanup options like
changing the sonar.search.port
bringing down the disk usage to 2 % from 15%
removing /temp and data/es8 but nothing worked.

A fresh installation pointing to the same DB with default configs worked though.

I believe I misreported this to be resolved too early. I can see that this issue is intermittent and this fails even with 10.2.1.78527.

Hi,

Can you provide fresh server logs?

 
Thx,
Ann

Hi @ganncamp , Please find attached all the DEBUG logs.

java version "17.0.6" 2023-01-17 LTS
Java(TM) SE Runtime Environment (build 17.0.6+9-LTS-190)
Java HotSpot(TM) 64-Bit Server VM (build 17.0.6+9-LTS-190, mixed mode, sharing)

es.log (616.6 KB)
nohup.log (249.6 KB)
sonar.log (249.2 KB)
web.log (65.8 KB)

Hi,

Thanks for the logs. I’m not seeing a clear culprit in them. Can you check the percentage of free disc space on the SonarQube host?

 
Thx,
Ann

I did check that as i found in some other thread that the disk usage may be an issue. The partition where SonarQube is running though small (60GB) is only used 3%.

SonarQube folder size is 569M

sonarqube-10.2.1.78527]$ du -hd1
16K	./bin
155M	./data
8.0K	./extensions
1.2M	./logs
24K	./temp
93M	./elasticsearch
24K	./conf
294M	./lib
27M	./web
569M	.

1 Like

Hi,

Thanks for checking. I’m not sure what else to look at so I’m going to flag this for more expert eyes.

 
Ann

OK. Thanks for looking in to this @ganncamp . I am out of ideas myself. I guess I’ll wait for the next release to se if that fixes the issue.

thanks.

Hi @himanshu.pathak.

What edition of SonarQube are you running? Am I right to assume Community Edition?
How are you running it? Docker?

You mentioned that

Could you please elaborate on that?
A fresh installation pointing to the DB that you upgraded works?
Or do you mean that a fresh installation of SonarQube on an empty Postgres 15.4 works?

How did you upgrade from Postgres 15.3 to 15.4? You have a backup from 15.3, right?

Hi @davi.vidal ,

Apologies this thread has now mixed up a lot. So the initial issue was that i upgraded postgresql to 15.4 and my sonar instance (10.1.0.73491) failed to start after that. When it didn’t start after multiple tries, i reinstalled the same version (10.1.0.73491) by unziping the sonar zip and config changes to point to the postgres db(same 15.4). that worked and i was able to keep the instance up till i upgraded sonar to 10.2.1.78527. For both the issues logs are attached in the ticket.

I am not running docker.
Unfortunately i don’t have the DB backup.
This is community edition.

OK, so your current state is:

  • SonarQube 10.2.1.78527
  • PostgreSQL 15.4
  • PostgreSQL is up and running
  • SonarQube is down

From your logs, I get the impression that you are trying to run SonarQube from /apps, is that correct? Do you have SELinux or something like that enabled?

It is a very long shot, specially considering that you had something that was working before, but could you try to move your setup to somewhere else, say /opt/sonarqube?

Do you have any proxy configured for your environment?

How did you perform your PostgreSQL update?

Can you provide the output or lsb_release -a?

Thanks Davi.

Below is the output of lsb_release -a.

LSB Version:	:core-4.1-amd64:core-4.1-noarch
Distributor ID:	RedHatEnterpriseServer
Description:	Red Hat Enterprise Linux Server release 7.4 (Maipo)
Release:	7.4
Codename:	Maipo

Yes i am running this from /apps. I can give /opt a shot. will get back with the results.

the PG upgrade was by compiling the PG from source and inplace data upgrade with pg_upgrade.

SELinux status: enabled [Had been enabled since many years and the sonar has been updated from old version many times]

1 Like

Hi @himanshu.pathak, how are you?

Were you able to try installing SonarQube into a different directory?

We are curious about this:

Am I right in understanding that you manually compiled PostgreSQL by yourself? Did you get different results when using your distro’s official package?

Hi Davi,

unfortunately i couldn’t test /opt as for some reasons my /opt partition is really small.
I have never used Postgres distributions as i am used to of compiling softwares for years now. (A bit of unlearning and new learning is required it seems. :slight_smile: )

A new development here is that i used the same database with the latest 10.3 release and that seems to work fine. So i think for now i’ll stick to it. One lesson is to have postgres and sonar backup for each version.

Hope this helps.