このコンテンツは選択した言語では利用できません。
10. Postgres Resources
- Q: Why is the agent showing an error in my PostgreSQL discovery about authentication failed for user "postgres"?
- Q: Why are most of the metrics for my Postgres resource showing up as NaN?
- Q: How many database connections are necessary to monitor a Postgres database?
- Q: Why can't I drop my database that is inventoried in JBoss ON?
Q:
Why is the agent showing an error in my PostgreSQL discovery about authentication failed for user "postgres"?
A:
The Postgres plug-in attempts to log into the database server using the username and password of postgres. In many installations, this is a default superuser and will work. However, it is also possible that this login could fail for several different reason:
- The postgres user has been deleted.
- The password for the postgres user has been changed.
- On Linux, the administrative login has been set to
ident sameuser
.
To resolve this:
- Inventory the discovered Postgres resource. Its availability will show as down and it will not find any child resources.
- Navigate to the INVENTORY tab for the Postgres resource.
- Under Connection Properties, click the Edit button.
- Change the role name and password fields to reflect a valid super user account on the Postgres instance.
Additionally, Postgres may need to be changed on Red Hat Enterprise Linux systems to allow password based logins by changing settings in the
pg_hba.conf
file.
Q:
Why are most of the metrics for my Postgres resource showing up as NaN?
A:
In many installations, Postgres will not start its statistics collector by default. To enable statistics collection, add or change the following line in the
postgres.conf
file:
stats_start_collector = on
Q:
How many database connections are necessary to monitor a Postgres database?
A:
Each Postgres database inventoried in JBoss ON requires one connection.
Q:
Why can't I drop my database that is inventoried in JBoss ON?
A:
With the frequency of availability and statistics monitoring, the Postgres plug-in keeps an open connection to the database. When attempting to drop a database currently inventoried in JBoss ON, an error is thrown about the database being in use. To drop the database, the JBoss ON agent monitoring the database must be shut down or the database resource should be removed from JBoss ON. This will close the postgres plug-in's connection to the Postgres server and allow you to drop the database.