Sonarqube Upgrade to 7.9, elasticsearch failing

OS: Red Hat Enterprise Linux v7.x
Sonarqube 7.9 LTS
JDK 11

We had Sonarqube 7.1 running successfully, but it wasn’t getting blame information from Git, so we decided to upgrade.

I downloaded the 7.9 tarball, unpacked it into the /opt/sonar directory, and changed permissions recursively to sonar:sonar.

It failed to start with an error that Java was too old for Sonarqube 7.9. No problem, I installed OpenJDK 12.

Still failing, but with no clear error. So I downloaded the JDK 12 .rpm from Oracle. Still failed. I’ve read here on the forums that you generally support LTS versions of Java, so I uninstalled JDK 12 and installed JDK 11. Still failing.

As far as I can tell, elastic search is failing, but there are no errors in the log. Only a WARN about a deprecated function that will be removed sometime in the future.

And yes, I’m starting as the sonar user, not root.

sonar.log

→ Wrapper Started as Daemon
Launching a JVM…
Wrapper (Version 3.2.3) http://wrapper.tanukisoftware.org
Copyright 1999-2006 Tanuki Software, Inc. All Rights Reserved.

2019.07.16 15:28:03 INFO app[o.s.a.AppFileSystem] Cleaning or creating temp directory /opt/sonar/temp
2019.07.16 15:28:03 INFO app[o.s.a.es.EsSettings] Elasticsearch listening on /127.0.0.1:9001
2019.07.16 15:28:03 INFO app[o.s.a.ProcessLauncherImpl] Launch process[[key=‘es’, ipcIndex=1, logFilenamePrefix=es]] from [/opt/sonar/elasticsearch]: /opt/sonar/elasticsearch/bin/elasticsearch
2019.07.16 15:28:03 INFO app[o.s.a.SchedulerImpl] Waiting for Elasticsearch to be up and running
2019.07.16 15:28:04 INFO app[o.e.p.PluginsService] no modules loaded
2019.07.16 15:28:04 INFO app[o.e.p.PluginsService] loaded plugin [org.elasticsearch.transport.Netty4Plugin]
Java HotSpot™ 64-Bit Server VM warning: Option UseConcMarkSweepGC was deprecated in version 9.0 and will likely be removed in a future release.
2019.07.16 15:28:16 INFO app[o.s.a.SchedulerImpl] Process[es] is up
2019.07.16 15:28:16 INFO app[o.s.a.ProcessLauncherImpl] Launch process[[key=‘web’, ipcIndex=2, logFilenamePrefix=web]] from [/opt/sonar]: /usr/java/jdk-11.0.4/bin/java -Djava.awt.headless=true -Dfile.encoding=UTF-8 -Djava.io.tmpdir=/opt/sonar/temp --add-opens=java.base/java.util=ALL-UNNAMED --add-opens=java.base/java.lang=ALL-UNNAMED --add-opens=java.base/java.io=ALL-UNNAMED --add-opens=java.rmi/sun.rmi.transport=ALL-UNNAMED -Xmx512m -Xms128m -XX:+HeapDumpOnOutOfMemoryError -Dhttp.nonProxyHosts=localhost|127.|[::1] -cp ./lib/common/:/opt/sonar/lib/jdbc/mysql/mysql-connector-java-5.1.46.jar org.sonar.server.app.WebServer /opt/sonar/temp/sq-process6321444327756349010properties
2019.07.16 15:28:22 INFO app[o.s.a.SchedulerImpl] Process[web] is stopped
2019.07.16 15:28:22 INFO app[o.s.a.SchedulerImpl] Process[es] is stopped
2019.07.16 15:28:22 WARN app[o.s.a.p.AbstractManagedProcess] Process exited with exit value [es]: 143
2019.07.16 15:28:22 INFO app[o.s.a.SchedulerImpl] SonarQube is stopped
← Wrapper Stopped

es.log

2019.07.16 15:28:07 INFO es[o.e.e.NodeEnvironment] using [1] data paths, mounts [[/ (rootfs)]], net usable_space [76.4gb], net total_space [91gb], types [rootfs]
2019.07.16 15:28:07 INFO es[o.e.e.NodeEnvironment] heap size [1.9gb], compressed ordinary object pointers [true]
2019.07.16 15:28:07 INFO es[o.e.n.Node] node name [sonarqube], node ID [yf-MPfisRueGh5nGlga2fA]
2019.07.16 15:28:07 INFO es[o.e.n.Node] version[6.8.0], pid[17188], build[default/tar/65b6179/2019-05-15T20:06:13.172855Z], OS[Linux/3.10.0-957.21.3.el7.x86_64/amd64], JVM[Oracle Corporation/Java HotSpot™ 64-Bit Server VM/11.0.4/11.0.4+10-LTS]
2019.07.16 15:28:07 INFO es[o.e.n.Node] JVM arguments [-XX:+UseConcMarkSweepGC, -XX:CMSInitiatingOccupancyFraction=75, -XX:+UseCMSInitiatingOccupancyOnly, -Des.networkaddress.cache.ttl=60, -Des.networkaddress.cache.negative.ttl=10, -XX:+AlwaysPreTouch, -Xss1m, -Djava.awt.headless=true, -Dfile.encoding=UTF-8, -Djna.nosys=true, -XX:-OmitStackTraceInFastThrow, -Dio.netty.noUnsafe=true, -Dio.netty.noKeySetOptimization=true, -Dio.netty.recycler.maxCapacityPerThread=0, -Dlog4j.shutdownHookEnabled=false, -Dlog4j2.disable.jmx=true, -Djava.io.tmpdir=/opt/sonar/temp, -XX:ErrorFile=…/logs/es_hs_err_pid%p.log, -Des.enforce.bootstrap.checks=true, -Xms2g, -Xmx2g, -Des.path.home=/opt/sonar/elasticsearch, -Des.path.conf=/opt/sonar/temp/conf/es, -Des.distribution.flavor=default, -Des.distribution.type=tar]
2019.07.16 15:28:08 INFO es[o.e.p.PluginsService] loaded module [analysis-common]
2019.07.16 15:28:08 INFO es[o.e.p.PluginsService] loaded module [lang-painless]
2019.07.16 15:28:08 INFO es[o.e.p.PluginsService] loaded module [mapper-extras]
2019.07.16 15:28:08 INFO es[o.e.p.PluginsService] loaded module [parent-join]
2019.07.16 15:28:08 INFO es[o.e.p.PluginsService] loaded module [percolator]
2019.07.16 15:28:08 INFO es[o.e.p.PluginsService] loaded module [reindex]
2019.07.16 15:28:08 INFO es[o.e.p.PluginsService] loaded module [repository-url]
2019.07.16 15:28:08 INFO es[o.e.p.PluginsService] loaded module [transport-netty4]
2019.07.16 15:28:08 INFO es[o.e.p.PluginsService] no plugins loaded
2019.07.16 15:28:10 WARN es[o.e.d.c.s.Settings] [http.enabled] setting was deprecated in Elasticsearch and will be removed in a future release! See the breaking changes documentation for the next major version.
2019.07.16 15:28:11 INFO es[o.e.d.DiscoveryModule] using discovery type [zen] and host providers [settings]
2019.07.16 15:28:12 INFO es[o.e.n.Node] initialized
2019.07.16 15:28:12 INFO es[o.e.n.Node] starting …
2019.07.16 15:28:12 INFO es[o.e.t.TransportService] publish_address {127.0.0.1:9001}, bound_addresses {127.0.0.1:9001}
2019.07.16 15:28:12 INFO es[o.e.b.BootstrapChecks] explicitly enforcing bootstrap checks
2019.07.16 15:28:15 INFO es[o.e.c.s.MasterService] zen-disco-elected-as-master ([0] nodes joined), reason: new_master {sonarqube}{yf-MPfisRueGh5nGlga2fA}{wvNL6K6VTVSPkRg_ZEYq1g}{127.0.0.1}{127.0.0.1:9001}{rack_id=sonarqube}
2019.07.16 15:28:15 INFO es[o.e.c.s.ClusterApplierService] new_master {sonarqube}{yf-MPfisRueGh5nGlga2fA}{wvNL6K6VTVSPkRg_ZEYq1g}{127.0.0.1}{127.0.0.1:9001}{rack_id=sonarqube}, reason: apply cluster state (from master [master {sonarqube}{yf-MPfisRueGh5nGlga2fA}{wvNL6K6VTVSPkRg_ZEYq1g}{127.0.0.1}{127.0.0.1:9001}{rack_id=sonarqube} committed version [1] source [zen-disco-elected-as-master ([0] nodes joined)]])
2019.07.16 15:28:15 INFO es[o.e.n.Node] started
2019.07.16 15:28:16 INFO es[o.e.g.GatewayService] recovered [0] indices into cluster_state
2019.07.16 15:28:22 INFO es[o.e.n.Node] stopping …
2019.07.16 15:28:22 INFO es[o.e.n.Node] stopped
2019.07.16 15:28:22 INFO es[o.e.n.Node] closing …
2019.07.16 15:28:22 INFO es[o.e.n.Node] closed

Ok, nevermind. I had to scroll to the very top of web.log, but I see it’s because we’re using MySQL and that’s deprecated in 7.9.

1 Like

A post was split to a new topic: 7.9 upgrade won’t start