2016-11-14 46 views
0

我想將SonarQube 5.3實例更新到5.6.3 LTS。要更新數據庫模式,我瀏覽到「http://mysonarqube/setup」,但是當我點擊「升級」按鈕時,我剛剛重定向到「http://mysonarqube/maintanance」頁面,根據服務器日誌沒有太多事情發生。 我預計會在瀏覽器中獲得某種進度指示。SonarQube更新5.3到5.6.3不起作用

當我點擊「升級」時,服務器上的日誌(sonar.log)根本沒有顯示任何活動。所以我猜測它根本不會觸發實際的模式遷移。

有沒有人知道發生了什麼事情,或者我如何進一步調試爲什麼沒有發生?

更新2016-11-15: 以下是啓動SonarQube服務器時的日誌。當我點擊設置頁面上的「升級」,而不是一個單一的行被添加到該日誌

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

2016.11.15 08:41:34 INFO app[o.s.a.AppFileSystem] Cleaning or creating temp directory C:\tools\sonarqube_playground\temp 
2016.11.15 08:41:35 INFO app[o.s.p.m.JavaProcessLauncher] Launch process[es]: c:\tools\java\jdk1.8.0_66\jre\bin\java -Djava.awt.headless=true -Xmx1G -Xms256m -Xss256k -Djava.net.preferIPv4Stack=true -XX:+UseParNewGC -XX:+UseConcMarkSweepGC -XX:CMSInitiatingOccupancyFraction=75 -XX:+UseCMSInitiatingOccupancyOnly -XX:+HeapDumpOnOutOfMemoryError -Djava.io.tmpdir=C:\tools\sonarqube_playground\temp -javaagent:c:\tools\java\jdk1.8.0_66\jre\lib\management-agent.jar -cp ./lib/common/*;./lib/search/* org.sonar.search.SearchServer C:\tools\sonarqube_playground\temp\sq-process934155640727080349properties 
2016.11.15 08:41:37 INFO es[o.s.p.ProcessEntryPoint] Starting es 
2016.11.15 08:41:37 INFO es[o.s.s.EsSettings] Elasticsearch listening on 127.0.0.1:9003 
2016.11.15 08:41:38 INFO es[o.elasticsearch.node] [sonar-1479195694200] version[1.7.5], pid[4920], build[00f95f4/2016-02-02T09:55:30Z] 
2016.11.15 08:41:38 INFO es[o.elasticsearch.node] [sonar-1479195694200] initializing ... 
2016.11.15 08:41:38 INFO es[o.e.plugins] [sonar-1479195694200] loaded [], sites [] 
2016.11.15 08:41:38 INFO es[o.elasticsearch.env] [sonar-1479195694200] using [1] data paths, mounts [[(C:)]], net usable_space [47.6gb], net total_space [69.4gb], types [NTFS] 
2016.11.15 08:41:42 WARN es[o.e.bootstrap] JNA not found. native methods will be disabled. 
2016.11.15 08:41:43 INFO es[o.elasticsearch.node] [sonar-1479195694200] initialized 
2016.11.15 08:41:43 INFO es[o.elasticsearch.node] [sonar-1479195694200] starting ... 
2016.11.15 08:41:43 INFO es[o.e.transport] [sonar-1479195694200] bound_address {inet[/127.0.0.1:9003]}, publish_address {inet[/127.0.0.1:9003]} 
2016.11.15 08:41:43 INFO es[o.e.discovery] [sonar-1479195694200] sonarqube/uESU6pKmQN2-u4e3ITgQRQ 
2016.11.15 08:41:46 INFO es[o.e.cluster.service] [sonar-1479195694200] new_master [sonar-1479195694200][uESU6pKmQN2-u4e3ITgQRQ][sonarqube][inet[/127.0.0.1:9003]]{rack_id=sonar-1479195694200}, reason: zen-disco-join (elected_as_master) 
2016.11.15 08:41:46 INFO es[o.elasticsearch.node] [sonar-1479195694200] started 
2016.11.15 08:41:47 INFO es[o.e.gateway] [sonar-1479195694200] recovered [0] indices into cluster_state 
2016.11.15 08:41:47 INFO app[o.s.p.m.Monitor] Process[es] is up 
2016.11.15 08:41:47 INFO app[o.s.p.m.JavaProcessLauncher] Launch process[web]: c:\tools\java\jdk1.8.0_66\jre\bin\java -Djava.awt.headless=true -Dfile.encoding=UTF-8 -Djruby.management.enabled=false -Djruby.compile.invokedynamic=false -Xmx2G -Xms512m -XX:MaxPermSize=160m -XX:+HeapDumpOnOutOfMemoryError -Djava.net.preferIPv4Stack=true -server -Djava.io.tmpdir=C:\tools\sonarqube_playground\temp -javaagent:c:\tools\java\jdk1.8.0_66\jre\lib\management-agent.jar -cp ./lib/common/*;./lib/server/*;C:\tools\sonarqube_playground\extensions\jdbc-driver\oracle\ojdbc7.jar org.sonar.server.app.WebServer C:\tools\sonarqube_playground\temp\sq-process4855516278340356405properties 
2016.11.15 08:41:48 INFO web[o.s.p.ProcessEntryPoint] Starting web 
2016.11.15 08:41:49 INFO web[o.s.s.a.TomcatContexts] Webapp directory: C:\tools\sonarqube_playground\web 
2016.11.15 08:41:50 INFO web[o.a.c.h.Http11NioProtocol] Initializing ProtocolHandler ["http-nio-0.0.0.0-9001"] 
2016.11.15 08:41:50 INFO web[o.a.t.u.n.NioSelectorPool] Using a shared selector for servlet write/read 
2016.11.15 08:41:55 INFO web[o.s.s.p.ServerImpl] SonarQube Server/5.6.3/3fcc98a73d6afb99388e39f46272909a6d6600b2 
2016.11.15 08:41:55 INFO web[o.sonar.db.Database] Create JDBC data source for jdbc:oracle:thin:[dbconnectionargumentsommittedforsecurity] 
2016.11.15 08:41:59 WARN web[o.s.s.p.DatabaseServerCompatibility] Database must be upgraded. Please backup database and browse /setup 
2016.11.15 08:41:59 INFO web[o.s.s.p.DefaultServerFileSystem] SonarQube home: C:\tools\sonarqube_playground 
2016.11.15 08:42:00 INFO web[o.e.plugins] [sonar-1479195694200] loaded [], sites [] 
2016.11.15 08:42:01 INFO web[o.s.s.p.RailsAppsDeployer] Deploying Ruby on Rails applications 
2016.11.15 08:42:02 INFO web[o.s.s.p.Platform] DB needs migration, entering safe mode 
2016.11.15 08:42:02 INFO web[jruby.rack] jruby 1.7.9 (ruby-1.8.7p370) 2013-12-06 87b108a on Java HotSpot(TM) 64-Bit Server VM 1.8.0_66-b17 [Windows Server 2012 R2-amd64] 
2016.11.15 08:42:02 INFO web[jruby.rack] using a shared (threadsafe!) runtime 
2016.11.15 08:42:25 INFO web[jruby.rack] keeping custom (config.logger) Rails logger instance 
2016.11.15 08:42:25 INFO web[o.a.c.h.Http11NioProtocol] Starting ProtocolHandler ["http-nio-0.0.0.0-9001"] 
2016.11.15 08:42:25 INFO web[o.s.s.a.TomcatAccessLog] Web server is started 
2016.11.15 08:42:25 INFO web[o.s.s.a.EmbeddedTomcat] HTTP connector enabled on port 9001 
2016.11.15 08:42:25 INFO app[o.s.p.m.Monitor] Process[web] is up 
2016.11.15 08:42:25 INFO app[o.s.p.m.JavaProcessLauncher] Launch process[ce]: c:\tools\java\jdk1.8.0_66\jre\bin\java -Djava.awt.headless=true -Dfile.encoding=UTF-8 -Xmx2G -Xms512m -XX:MaxPermSize=160m -XX:+HeapDumpOnOutOfMemoryError -Djava.net.preferIPv4Stack=true -server -Djava.io.tmpdir=C:\tools\sonarqube_playground\temp -javaagent:c:\tools\java\jdk1.8.0_66\jre\lib\management-agent.jar -cp ./lib/common/*;./lib/server/*;./lib/ce/*;C:\tools\sonarqube_playground\extensions\jdbc-driver\oracle\ojdbc7.jar org.sonar.ce.app.CeServer C:\tools\sonarqube_playground\temp\sq-process8088446918777658625properties 
2016.11.15 08:42:27 INFO ce[o.s.p.ProcessEntryPoint] Starting ce 
2016.11.15 08:42:27 INFO ce[o.s.c.a.WebServerWatcherImpl] Waiting for Web Server to be operational... 
2016.11.15 08:42:28 INFO ce[o.s.c.a.WebServerWatcherImpl] Still waiting for WebServer... 
2016.11.15 08:42:30 INFO ce[o.s.c.a.WebServerWatcherImpl] Still waiting for WebServer... 
2016.11.15 08:42:35 INFO ce[o.s.c.a.WebServerWatcherImpl] Still waiting for WebServer... 
2016.11.15 08:42:48 INFO ce[o.s.c.a.WebServerWatcherImpl] Still waiting for WebServer... 
2016.11.15 08:43:23 INFO ce[o.s.c.a.WebServerWatcherImpl] Still waiting for WebServer... 
2016.11.15 08:44:58 INFO ce[o.s.c.a.WebServerWatcherImpl] Still waiting for WebServer... 
2016.11.15 08:49:17 INFO ce[o.s.c.a.WebServerWatcherImpl] Still waiting for WebServer... 
2016.11.15 09:01:01 INFO ce[o.s.c.a.WebServerWatcherImpl] Still waiting for WebServer... 
2016.11.15 09:32:55 INFO ce[o.s.c.a.WebServerWatcherImpl] Still waiting for WebServer... 
+0

你能發送完整的日誌/ sonar.lo gs好嗎? –

+0

根據請求在我的描述中添加了日誌 –

+0

一種選擇是數據庫連接可以訪問SonarQube的多個Oracle模式。您應該限制用戶的權限僅限一個模式。 –

回答

0

我檢查了設置頁面的HTML,提取該按鈕將調用的URL,並試圖手動使用。我收到了「未經授權」的回覆。這讓我想到授權。

長話短說:我sonar.properties文件的選項sonar.forceAuthentication」被設置爲‘真’,因爲我不希望匿名訪問做每個人都應該使用Sonarqube時登錄但安裝。頁面沒有任何「登錄」選項,因此很明顯,開始我需要登錄後的架構更新,但網頁不支持登錄。

設置sonar.forceAuthentication後「假「sonar.properties文件並重新啓動服務我終於能夠開始架構更新。

+0

不能在sonar.properties中設置屬性sonar.forceAuthentication。該文件應該只包含註釋掉的屬性,否則可能會引發失敗。 –