Hello,
I’m working on updating sonarqube v7.9.3 to sonarqube v8.9.9.
The database update step seems to work fine.
But then I have this error in the file web.log :
2022.06.30 17:19:48 INFO web[][o.s.p.ProcessEntryPoint] Starting web
2022.06.30 17:19:49 INFO web[][o.a.t.u.n.NioSelectorPool] Using a shared selector for servlet write/read
2022.06.30 17:19:49 INFO web[][o.s.c.e.CoreExtensionsLoader] Loaded core extensions: developer-edition, developer-scanner, developer-server, license
2022.06.30 17:19:49 INFO web[][o.s.s.e.EsClientProvider] Connected to local Elasticsearch: [http://localhost:9001]
2022.06.30 17:19:50 INFO web[][o.s.s.p.LogServerVersion] SonarQube Server / 8.9.9.56886 / f7ef403a1f66dde923eda25b58df08d40a16e043
2022.06.30 17:19:50 INFO web[][o.sonar.db.Database] Create JDBC data source for jdbc:postgresql://PGSSOND1/dpsond1
2022.06.30 17:19:51 INFO web[][o.s.s.p.ServerFileSystemImpl] SonarQube home: /logiciel/sonarqube/sonarqube-8.9.9.56886
2022.06.30 17:19:51 INFO web[][o.s.s.u.SystemPasscodeImpl] System authentication by passcode is disabled
2022.06.30 17:19:51 INFO web[][o.s.s.p.ServerPluginManager] Deploy plugin ABAP Code Quality and Security / 3.9.1.3127 / a62ddf6ddd7379d398a58d32c9931a2feef61e24
2022.06.30 17:19:51 INFO web[][o.s.s.p.ServerPluginManager] Deploy plugin C# Code Quality and Security / 8.22.0.31243 / e3cee7838d992e31dcdd90cf4f7406bb20535e8e
2022.06.30 17:19:51 INFO web[][o.s.s.p.ServerPluginManager] Deploy plugin CFamily Code Quality and Security / 6.20.5.49286 / 1de27cf105c23a2bdeef4d5c9ce908192f518af9
2022.06.30 17:19:51 INFO web[][o.s.s.p.ServerPluginManager] Deploy plugin CSS Code Quality and Security / 1.4.2.2002 / faa7d4f1407df67df7ada53caf677ab783721173
2022.06.30 17:19:51 INFO web[][o.s.s.p.ServerPluginManager] Deploy plugin Flex Code Quality and Security / 2.6.1.2564 / bb723840701bda72510b7a47742811d20daad331
2022.06.30 17:19:51 INFO web[][o.s.s.p.ServerPluginManager] Deploy plugin Go Code Quality and Security / 1.8.3.2219 / d6ad7a5a47fc4785d2e80918fb7424be46e38a7f
2022.06.30 17:19:51 INFO web[][o.s.s.p.ServerPluginManager] Deploy plugin HTML Code Quality and Security / 3.4.0.2754 / 38f7ff864ae15152c9f1efc3014594f7e7ca7b6e
2022.06.30 17:19:51 INFO web[][o.s.s.p.ServerPluginManager] Deploy plugin JaCoCo / 1.1.1.1157 / 83478572b9f23efac29de15e30c7758bbb0c0e47
2022.06.30 17:19:51 INFO web[][o.s.s.p.ServerPluginManager] Deploy plugin Java Code Quality and Security / 6.15.1.26025 / 1b1e96715bfa9f6a4ae24e95cc5b91f0edce609f
2022.06.30 17:19:51 INFO web[][o.s.s.p.ServerPluginManager] Deploy plugin JavaScript/TypeScript Code Quality and Security / 7.4.4.15624 / 481b2e69339b016b5d7d1eb27f0abf20dd6bd961
2022.06.30 17:19:51 INFO web[][o.s.s.p.ServerPluginManager] Deploy plugin Kotlin Code Quality and Security / 1.8.3.2219 / d6ad7a5a47fc4785d2e80918fb7424be46e38a7f
2022.06.30 17:19:51 INFO web[][o.s.s.p.ServerPluginManager] Deploy plugin PHP Code Quality and Security / 3.17.0.7439 / 44c7760147080c157fa0ff579772f92d3c8e1ebf
2022.06.30 17:19:51 INFO web[][o.s.s.p.ServerPluginManager] Deploy plugin PL/SQL Code Quality and Security / 3.6.1.3873 / 342f7fcf17ecb7fbf827a2aacf630be1f4157625
2022.06.30 17:19:51 INFO web[][o.s.s.p.ServerPluginManager] Deploy plugin Python Code Quality and Security / 3.4.1.8066 / 22139ec73fb2f32044f66477ea52734415683668
2022.06.30 17:19:51 INFO web[][o.s.s.p.ServerPluginManager] Deploy plugin Ruby Code Quality and Security / 1.8.3.2219 / d6ad7a5a47fc4785d2e80918fb7424be46e38a7f
2022.06.30 17:19:51 INFO web[][o.s.s.p.ServerPluginManager] Deploy plugin Scala Code Quality and Security / 1.8.3.2219 / d6ad7a5a47fc4785d2e80918fb7424be46e38a7f
2022.06.30 17:19:51 INFO web[][o.s.s.p.ServerPluginManager] Deploy plugin Swift Code Quality and Security / 4.3.1.4892 / 2b249272bc4430519bdab769886b12c9a82084b5
2022.06.30 17:19:51 INFO web[][o.s.s.p.ServerPluginManager] Deploy plugin T-SQL Code Quality and Security / 1.5.1.4340 / 11f3de5739b539749d6c2848bda8fc90135d91b6
2022.06.30 17:19:51 INFO web[][o.s.s.p.ServerPluginManager] Deploy plugin VB.NET Code Quality and Security / 8.22.0.31243 / e3cee7838d992e31dcdd90cf4f7406bb20535e8e
2022.06.30 17:19:51 INFO web[][o.s.s.p.ServerPluginManager] Deploy plugin Vulnerability Analysis / 8.9.0.11439 / 04498e7b336a73db9508145d1e8cc44b9330528d
2022.06.30 17:19:51 INFO web[][o.s.s.p.ServerPluginManager] Deploy plugin Vulnerability Rules for C# / 8.9.0.11439 / 04498e7b336a73db9508145d1e8cc44b9330528d
2022.06.30 17:19:51 INFO web[][o.s.s.p.ServerPluginManager] Deploy plugin Vulnerability Rules for JS / 8.9.0.11439 / 04498e7b336a73db9508145d1e8cc44b9330528d
2022.06.30 17:19:51 INFO web[][o.s.s.p.ServerPluginManager] Deploy plugin Vulnerability Rules for Java / 8.9.0.11439 / 04498e7b336a73db9508145d1e8cc44b9330528d
2022.06.30 17:19:51 INFO web[][o.s.s.p.ServerPluginManager] Deploy plugin Vulnerability Rules for PHP / 8.9.0.11439 / 04498e7b336a73db9508145d1e8cc44b9330528d
2022.06.30 17:19:51 INFO web[][o.s.s.p.ServerPluginManager] Deploy plugin Vulnerability Rules for Python / 8.9.0.11439 / 04498e7b336a73db9508145d1e8cc44b9330528d
2022.06.30 17:19:51 INFO web[][o.s.s.p.ServerPluginManager] Deploy plugin XML Code Quality and Security / 2.2.0.2973 / 16002945f0725643a7b42f090572795dd8b72a0f
2022.06.30 17:19:52 INFO web[][o.s.s.p.d.m.c.PostgresCharsetHandler] Verify that database charset supports UTF8
2022.06.30 17:19:52 INFO web[][o.s.s.p.w.MasterServletFilter] Initializing servlet filter org.sonar.server.platform.web.WebServiceFilter@21967d85 [pattern=UrlPattern{inclusions=[/api/system/migrate_db.*, ...], exclusions=[/api/components/update_key, ...]}]
2022.06.30 17:19:52 INFO web[][o.s.s.a.EmbeddedTomcat] HTTP connector enabled on port 9000
2022.06.30 17:19:53 INFO web[][A.A.A.A.A.C] JavaScript/TypeScript frontend is enabled
2022.06.30 17:19:53 INFO web[][o.s.s.p.UpdateCenterClient] Update center: https://update.sonarsource.org/update-center.properties (HTTP proxy: **********:****)
2022.06.30 17:19:55 INFO web[][o.s.s.s.LogServerId] Server ID: B9BE0753-18ddab37a78c4ca
2022.06.30 17:19:55 WARN web[][o.s.s.a.LogOAuthWarning] For security reasons, OAuth authentication should use HTTPS. You should set the property 'Administration > Configuration > Server base URL' to a HTTPS URL.
2022.06.30 17:19:55 INFO web[][org.sonar.INFO] Security realm: LDAP
2022.06.30 17:19:55 INFO web[][o.s.a.l.LdapSettingsManager] User mapping: LdapUserMapping{baseDn=*******, request=(&(objectClass=user)(sAMAccountName={0})), realNameAttribute=cn, emailAttribute=mail}
2022.06.30 17:19:55 INFO web[][o.s.a.l.LdapSettingsManager] Groups will not be synchronized, because property 'ldap.group.baseDn' is empty.
2022.06.30 17:19:55 INFO web[][o.s.a.l.LdapContextFactory] Test LDAP connection on ldap://*******:***: OK
2022.06.30 17:19:55 INFO web[][org.sonar.INFO] Security realm started
2022.06.30 17:19:55 ERROR web[][o.s.s.p.Platform] Background initialization failed. Stopping SonarQube
org.apache.ibatis.exceptions.PersistenceException:
### Error committing transaction. Cause: org.apache.ibatis.executor.BatchExecutorException: org.sonar.db.notification.NotificationQueueMapper.insert (batch index #1) failed. Cause: java.sql.BatchUpdateException: Batch entry 0 INSERT INTO notifications (uuid,data,created_at)
VALUES ('AYG1MoQNZP4GmwjHQ3ZS',?,1656602395661) was aborted: ERROR: record "new" has no field "id"
Where: SQL statement "SELECT NEW.id IS null"
PL/pgSQL function trigger_fct_notifications_idt() line 3 at IF Call getNextException to see other errors in the batch.
### Cause: org.apache.ibatis.executor.BatchExecutorException: org.sonar.db.notification.NotificationQueueMapper.insert (batch index #1) failed. Cause: java.sql.BatchUpdateException: Batch entry 0 INSERT INTO notifications (uuid,data,created_at)
VALUES ('AYG1MoQNZP4GmwjHQ3ZS',?,1656602395661) was aborted: ERROR: record "new" has no field "id"
Where: SQL statement "SELECT NEW.id IS null"
PL/pgSQL function trigger_fct_notifications_idt() line 3 at IF Call getNextException to see other errors in the batch.
at org.apache.ibatis.exceptions.ExceptionFactory.wrapException(ExceptionFactory.java:30)
at org.apache.ibatis.session.defaults.DefaultSqlSession.commit(DefaultSqlSession.java:226)
at org.apache.ibatis.session.defaults.DefaultSqlSession.commit(DefaultSqlSession.java:217)
at org.sonar.db.DbSessionImpl.commit(DbSessionImpl.java:42)
at org.sonar.db.BatchSession.commit(BatchSession.java:168)
at org.sonar.db.notification.NotificationQueueDao.insert(NotificationQueueDao.java:50)
at org.sonar.server.notification.DefaultNotificationManager.scheduleForSending(DefaultNotificationManager.java:79)
at org.sonar.server.authentication.DefaultAdminCredentialsVerifierImpl.sendEmailToAdmins(DefaultAdminCredentialsVerifierImpl.java:105)
at org.sonar.server.authentication.DefaultAdminCredentialsVerifierImpl.start(DefaultAdminCredentialsVerifierImpl.java:61)
at org.sonar.core.platform.StartableCloseableSafeLifecyleStrategy.start(StartableCloseableSafeLifecyleStrategy.java:40)
at org.picocontainer.injectors.AbstractInjectionFactory$LifecycleAdapter.start(AbstractInjectionFactory.java:84)
at org.picocontainer.behaviors.AbstractBehavior.start(AbstractBehavior.java:169)
at org.picocontainer.behaviors.Stored$RealComponentLifecycle.start(Stored.java:132)
at org.picocontainer.behaviors.Stored.start(Stored.java:110)
at org.picocontainer.DefaultPicoContainer.potentiallyStartAdapter(DefaultPicoContainer.java:1016)
at org.picocontainer.DefaultPicoContainer.startAdapters(DefaultPicoContainer.java:1009)
at org.picocontainer.DefaultPicoContainer.start(DefaultPicoContainer.java:767)
at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:136)
at org.sonar.server.platform.platformlevel.PlatformLevel.start(PlatformLevel.java:90)
at org.sonar.server.platform.platformlevel.PlatformLevel4.start(PlatformLevel4.java:581)
at org.sonar.server.platform.PlatformImpl.start(PlatformImpl.java:213)
at org.sonar.server.platform.PlatformImpl.startLevel34Containers(PlatformImpl.java:187)
at org.sonar.server.platform.PlatformImpl.access$500(PlatformImpl.java:46)
at org.sonar.server.platform.PlatformImpl$1.lambda$doRun$0(PlatformImpl.java:120)
at org.sonar.server.platform.PlatformImpl$AutoStarterRunnable.runIfNotAborted(PlatformImpl.java:370)
at org.sonar.server.platform.PlatformImpl$1.doRun(PlatformImpl.java:120)
at org.sonar.server.platform.PlatformImpl$AutoStarterRunnable.run(PlatformImpl.java:354)
at java.base/java.lang.Thread.run(Thread.java:829)
Caused by: org.apache.ibatis.executor.BatchExecutorException: org.sonar.db.notification.NotificationQueueMapper.insert (batch index #1) failed. Cause: java.sql.BatchUpdateException: Batch entry 0 INSERT INTO notifications (uuid,data,created_at)
VALUES ('AYG1MoQNZP4GmwjHQ3ZS',?,1656602395661) was aborted: ERROR: record "new" has no field "id"
Where: SQL statement "SELECT NEW.id IS null"
PL/pgSQL function trigger_fct_notifications_idt() line 3 at IF Call getNextException to see other errors in the batch.
at org.apache.ibatis.executor.BatchExecutor.doFlushStatements(BatchExecutor.java:149)
at org.apache.ibatis.executor.BaseExecutor.flushStatements(BaseExecutor.java:129)
at org.apache.ibatis.executor.BaseExecutor.flushStatements(BaseExecutor.java:122)
at org.apache.ibatis.executor.BaseExecutor.commit(BaseExecutor.java:242)
at org.apache.ibatis.executor.CachingExecutor.commit(CachingExecutor.java:119)
at org.apache.ibatis.session.defaults.DefaultSqlSession.commit(DefaultSqlSession.java:223)
... 26 common frames omitted
Caused by: java.sql.BatchUpdateException: Batch entry 0 INSERT INTO notifications (uuid,data,created_at)
VALUES ('AYG1MoQNZP4GmwjHQ3ZS',?,1656602395661) was aborted: ERROR: record "new" has no field "id"
Where: SQL statement "SELECT NEW.id IS null"
PL/pgSQL function trigger_fct_notifications_idt() line 3 at IF Call getNextException to see other errors in the batch.
at org.postgresql.jdbc.BatchResultHandler.handleError(BatchResultHandler.java:165)
at org.postgresql.core.ResultHandlerDelegate.handleError(ResultHandlerDelegate.java:52)
at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:2366)
at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:559)
at org.postgresql.jdbc.PgStatement.internalExecuteBatch(PgStatement.java:887)
at org.postgresql.jdbc.PgStatement.executeBatch(PgStatement.java:910)
at org.postgresql.jdbc.PgPreparedStatement.executeBatch(PgPreparedStatement.java:1638)
at org.apache.commons.dbcp2.DelegatingStatement.executeBatch(DelegatingStatement.java:242)
at org.apache.commons.dbcp2.DelegatingStatement.executeBatch(DelegatingStatement.java:242)
at org.apache.ibatis.executor.BatchExecutor.doFlushStatements(BatchExecutor.java:123)
... 31 common frames omitted
Caused by: org.postgresql.util.PSQLException: ERROR: record "new" has no field "id"
Where: SQL statement "SELECT NEW.id IS null"
PL/pgSQL function trigger_fct_notifications_idt() line 3 at IF
at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:2675)
at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:2365)
... 38 common frames omitted
2022.06.30 17:19:56 INFO web[][o.s.p.ProcessEntryPoint] Hard stopping process
2022.06.30 17:19:56 WARN web[][o.a.c.l.WebappClassLoaderBase] The web application [sonar] appears to have started a thread named [Thread-2] but has failed to stop it. This is very likely to create a memory leak. Stack trace of thread:\n java.base@11.0.15/java.net.SocketInputStream.socketRead0(Native Method)\n java.base@11.0.15/java.net.SocketInputStream.socketRead(SocketInputStream.java:115)\n java.base@11.0.15/java.net.SocketInputStream.read(SocketInputStream.java:168)\n java.base@11.0.15/java.net.SocketInputStream.read(SocketInputStream.java:140)\n java.base@11.0.15/java.io.BufferedInputStream.fill(BufferedInputStream.java:252)\n java.base@11.0.15/java.io.BufferedInputStream.read1(BufferedInputStream.java:292)\n java.base@11.0.15/java.io.BufferedInputStream.read(BufferedInputStream.java:351)\n java.naming@11.0.15/com.sun.jndi.ldap.Connection.run(Connection.java:855)\n java.base@11.0.15/java.lang.Thread.run(Thread.java:829)
Could you please help me to resolve this issue ?
Thank you.
OS: RHEL 7.9
DB: PostgreSQL 11.16