【发布时间】:2017-11-26 02:13:01
【问题描述】:
设置 SonarQube 版本 6.4(内部版本 25310)并在出现未从上一个问题打开 9000 的问题后运行它: Setting up SonarQube on AWS using EC2
现在我正在尝试通过 AWS RDS 设置 PostGres:
- 安装 PostgreSQL 9.6.2
- 为 Sonar EC2 实例配置安全性以允许入站规则:
- PostGreSQl/TCP/5432/0.0.0.0/0, ::/0
- PostGreSQl/TCP/5432/Anywhere/0.0.0.0/0, ::/0
- PostGreSQl/TCP/5432/Custom/Sonar 安全组 --> 声纳实例组
- VI sonar.properties 文件
-
sonar.jdbc.username=XXXXXX--> RDS 设置期间使用的用户名 -
sonar.jdbc.password=XXXXXX--> RDS 设置期间使用的密码 sonar.jdbc.url=jdbc:sonardbpostgre.XXXXXXXXX.us-east-1.rds.amazonaws.com:5432cd ../bin/linux-x86-64/./sonar.sh restart
据我所知,我的配置中的某些内容并不满意,因为它确实尝试启动,因为我看到 pid 出现但随后它立即被杀死。
有什么建议吗?
如果我取消注释 sonar.properties 中的更改,它会在重新启动后恢复。
这是我尝试为数据库添加配置后看到的内容:
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
【问题讨论】:
-
2017-06-22 16:13:01 UTC::@:[2882]:WARNING: unrecognized configuration parameter "rds.logical_replication"这是我在数据库实例中看到的唯一日志 -
您在 SonarQube 服务器日志中看到了什么?
-
WrapperSimpleApp: Encountered an error running main: org.sonar.process.MessageException: Bad format of JDBC URL: jdbc:sonardbpostgre.XXXXXXX.us-east-1.rds.amazonaws.com:5432 org.sonar.process.MessageException: Bad format of JDBC URL: jdbc:sonardbpostgre.XXXXXX.us-east-1.rds.amazonaws.com:5432有特定的格式吗? -
更新了 jdca URL 以包含`jdbc:postgresql://sonardbpostgre.~`,但仍然不会出现,但从 web.log 中得到了这个并看到了这个:
java.lang.IllegalStateException: Can not connect to database. Please check connectivity and settings (see the properties prefixed by 'sonar.jdbc.').所以跟踪出
标签: linux amazon-web-services amazon-ec2 sonarqube sonarqube-ops