SonarQube does not come back up after I enable Pos

2019-06-08 16:47发布

Setup SonarQube Version 6.4 (build 25310) and have it running after having issue not opening 9000 from previous question: Setting up SonarQube on AWS using EC2

Now I am trying to setup PostGres via AWS RDS:

  1. Setup PostgreSQL 9.6.2
  2. Configure security for Sonar EC2 instance to allow inbound rules:
  3. PostGreSQl/TCP/5432/0.0.0.0/0, ::/0
  4. PostGreSQl/TCP/5432/Anywhere/0.0.0.0/0, ::/0
  5. PostGreSQl/TCP/5432/Custom/Sonar Security group --> group for the sonar instance
  6. VI sonar.properties file
  7. sonar.jdbc.username=XXXXXX --> Username used during RDS setup
  8. sonar.jdbc.password=XXXXXX --> Password used during RDS setup
  9. sonar.jdbc.url=jdbc:sonardbpostgre.XXXXXXXXX.us-east-1.rds.amazonaws.com:5432
  10. cd ../bin/linux-x86-64/
  11. ./sonar.sh restart

From what I can tell something in my config is not happy as it does try to start as I can see the pid come up but then it immediately gets killed.

Any suggestions?

If I uncomment the changes in the changes in sonar.properties it comes back up after restart.

Here is what I see after I try adding the config for the DB:

root@ip-172- linux-x86-64]# ls
lib  SonarQube.pid  sonar.sh  wrapper
[root@ip-172- linux-x86-64]# ./sonar.sh restart
Stopping SonarQube...
Stopped SonarQube.
Starting SonarQube...
Started SonarQube.
[root@ip-172- linux-x86-64]# ls
lib  sonar.sh  wrapper
[root@ip-172- linux-x86-64]# ls
lib  sonar.sh  wrapper
[root@ip-172- linux-x86-64]# ./sonar.sh restart
Stopping SonarQube...
SonarQube was not running.
Starting SonarQube...
Started SonarQube.
[root@ip-172- linux-x86-64]# ls
lib  SonarQube.pid  sonar.sh  wrapper
[root@ip-172- linux-x86-64]# ls
lib  sonar.sh  wrapper

1条回答
Root(大扎)
2楼-- · 2019-06-08 16:58

Format of JDBC URL for PostgreSQL is jdbc:postgresql://<host>/<database>. In your case the property should look like sonar.jdbc.url=jdbc:postgresql://xxx.us-east-1.rds.amazonaws.com:5432/sonarqube.

查看更多
登录 后发表回答