Postgresql topology discovery is not working
I am trying to use OMi management Pack for postgresql, but after send the discovery policy "PostgreSQL_Discovery" to the node, the postgresql ICs was not created on OMi.
Ilook on "cat /var/opt/OV/log/monitors/PostgreSQL_Collector.log" and I can see:
2018-4-19 13:59 Starting collection
2018-4-19 13:59 Error code received: 1
2018-4-19 13:59 Finished collection
I try to run the command "/var/opt/OV/bin/instrumentation/monitorframeworkperl monitorframework.pl -production -topology PostgreSQL_Collector.pm" to find if ICs is decovered, but I does not receive any answare. This is the output of this command:
# /var/opt/OV/bin/instrumentation/monitorframeworkperl monitorframework.pl -production -topology PostgreSQL_Collector.pm
I have OMi installed on a virtual machine for test and whe I run this command I receive this result:
<Attribute name="hpom_rootcontainer" value="host_node__dfcdsrvv3893" />
<Attribute name="ucmdb_version" value="9.6" />
<Attribute name="ucmdb_application_path" value="/opt/HP/BSM/pgsql" />
<Attribute name="ucmdb_discovered_product_name" value="postgres#5433" />
<Attribute name="ucmdb_name" value="postgres#5433" />
<Attribute name="hpom_citype" value="postgresql" />
<Attribute name="ucmdb_application_port" value="5433" datatype="integer"/>
<Attribute name="ucmdb_vendor" value="PostgreSQL" />
<Attribute name="hpom_citype" value="unix" />
<Attribute name="ucmdb_name" value="dfcdsrvv3893" />
<Attribute name="ucmdb_primary_dns_name" value="dfcdsrvv3893" />
<Attribute name="hpom_modifyexisting" value="false" />
What could be happening?
Hello SeanSun ,
Thanks for your time. I followed the manual OMi_MP_for_Postgres_SQL_1_10_UserGuide.pdf , and set the task 2, deploy the configuration on task 3, but the topologi is not discovered. On PostgreSQL_Collector.log I only can see:
2018-4-24 16:26 Starting collection
2018-4-24 16:26 Error code received: 1
2018-4-24 16:26 Finished collection
Try running this command:
monitorframeworkperl monitorframework.pl -developer -topology PostgreSQL_Collector.pm
It will show any errors it encountered trying to search for the topology. For example, if the postgres policies are not deployed or some problem with a perl script not finding where your postgres is.
Hello Carol Park,
Thanks for your time.
When I run the command “/var/opt/OV/bin/instrumentation/monitorframeworkperl monitorframework.pl -developer -topology PostgreSQL_Collector.pm” and I receive this answer:
ERROR: PostgreSQL is not running on the managed node
I open the file “PostgreSQL_Collector.pm” and look for variable “$PGDAEMON” and it is set to “bin/postgres”
When I look on my PostgreSQL servers, all of then does not have have “bin/postgres” running. But I found the “bin/postmaster”. I change the variable “$PGDAEMON” to “bin/postmaster” and the file “PostgreSQL_Collector-topo.xml” was created with databases.
What is the right configuration “bin/postgres” or “bin/postmaster”? or I need to use another Management Pack?
Thanks a lot,
Good to know you got it discovered ok. Next will be to see if the monitoring is working after you assign/deploy the postgres aspects.
I think you will want to open a Support case about updating the Postgres MP to discover postmaster and not just postgres.