Red Hat Bugzilla – Bug 985778
Incorrect default of rhq.server.database.connection-url in rhq-server.properties
Last modified: 2015-11-01 19:43:20 EST
Description of problem: I was facing weird issue. Before I tried to install RHQ server I wanted it to connect to postgres on remote host.
I did it by changing rhq-server.properties this way:
then I installed RHQ via rhqctl, it worked fine (created tables and some initial data in postgres database and cassandra as well) but when rhqctl tried to start RHQ and rhq.ear started deploying, it was failing with long stacktrace on:
org.postgresql.util.PSQLException: ERROR: relation "rhq_server" does not exist
which seemed crazy, because installer just created those tables and they were of course present.
I found out that value of "rhq.server.database.connection-url" property was wrong. I've changed it's value to jdbc:postgres://<hostname>:5432/lzoubek1 (note postgres vs postgresql), then restarted server and it finally started to import resource types.
For some reason this cannot be reproduced when you connect to local postgres.
Version-Release number of selected component (if applicable):
How reproducible: always
Expected results: change default value of rhq.server.database.connection-url to jdbc:postgres://127.0.0.1:5432/rhq
Additional Info: if we change this default, then we need to handle this in upgrade scenario. It seems that users running postgres on remote hosts were already hitting this bug.
changing to jdbc:postgres://127.0.0.1:5432/rhq does not help at all, the issue is different I'll open separate.