Ad Widget

Collapse

postgresql monitoring problems with template pg_monz

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • emijares
    Junior Member
    • Oct 2015
    • 2

    #1

    postgresql monitoring problems with template pg_monz

    Good afternoon I have trouble monitoring PostgreSQL template pg_monz says I 'm not supplying the trusted key for the server to access the agent, use the pgpass file to set the key to confidence among servers but it throws the following errors :

    10631:20151005:185440.433 item "10.100.2.33gsql.get.pg.slow_query[{$PGSCRIPTDIR},{$PGSCRIPT_CONFDIR},{HOST.HOST},{$Z ABBIX_AGENTD_CONF},{$PGSLOWQUERY_TIME_THRESHOLD}]" became not supported: Received value [Password for user postgres: psql: fe_sendauth: no password supplied] is not suitable for value type [Numeric (unsigned)] and data type [Decimal]
    10631:20151005:185440.433 item "10.100.2.33gsql.get.pg.transactions[{$PGSCRIPTDIR},{$PGSCRIPT_CONFDIR},{HOST.HOST},{$Z ABBIX_AGENTD_CONF}]" became not supported: Received value [Password for user postgres: psql: fe_sendauth: no password supplied] is not suitable for value type [Numeric (unsigned)] and data type [Decimal]
    10632:20151005:185455.436 item "10.100.2.33sql.primary_server[{$PGSCRIPTDIR},{$PGSCRIPT_CONFDIR}]" became not supported: Received value [Password for user postgres: psql: fe_sendauth: no password supplied] is not suitable for value type [Numeric (unsigned)] and data type [Decimal]
    10630:20151005:185500.437 item "10.100.2.33sql.standby_server[{$PGSCRIPTDIR},{$PGSCRIPT_CONFDIR}]" became not supported: Received value [Password for user postgres: psql: fe_sendauth: no password supplied] is not suitable for value type [Numeric (unsigned)] and data type [Decimal]
    10633:20151005:185505.439 item "10.100.2.33:grpsum[{$PG_HOST_GROUP},"psql.primary_server[{$PGSCRIPTDIR},{$PGSCRIPT_CONFDIR}]",last,0]" became not supported: No items for key "psql.primary_server[/usr/local/bin,/usr/local/etc]" in group(s) "PostgreSQL".
    10633:20151005:185505.439 item "10.100.2.33:grpsum[{$PG_HOST_GROUP},"psql.running[{$PGSCRIPTDIR},{$PGSCRIPT_CONFDIR}]",last,]" became not supported: No items for key "psql.running[/usr/local/bin,/usr/local/etc]" in group(s) "PostgreSQL".
    10633:20151005:185505.439 item "10.100.2.33:grpsum[{$PG_HOST_GROUP},"psql.standby_server[{$PGSCRIPTDIR},{$PGSCRIPT_CONFDIR}]",last,0]" became not supported: No items for key "psql.standby_server[/usr/local/bin,/usr/local/etc]" in group(s) "PostgreSQL".
    10626:20151005:193930.845 executing housekeeper
    Thank you for the cooperation
  • ingus.vilnis
    Senior Member
    Zabbix Certified Trainer
    Zabbix Certified SpecialistZabbix Certified Professional
    • Mar 2014
    • 908

    #2
    Hello and welcome to Zabbix forums!

    If you carefully look at the provided log lines, they give you a clear clue where the initial problem is:
    Code:
    Password for user postgres: psql: fe_sendauth: no password supplied
    Please supply the password where it should be and check the items again. I don't know the template you are using so I can't tell much where that password could be stored. Maybe check if there is a template description where you downloaded it.

    Best Regards,
    Ingus

    Comment

    • emijares
      Junior Member
      • Oct 2015
      • 2

      #3
      postgresql monitoring problems with template pg_monz

      hello, thank you very much for taking into account my problems.

      I am using a file called pgpass where I keep the password, but apparently not capture the password .

      call pgsql_funcs.conf archive file as follows :

      PGHOST = localhost
      PGPORT = 5432
      PGROLE = postgres
      PgDatabase = postgres

      PGPASSFILE export = / usr / local / etc / pgpass

      pgpass file content is:

      localhost: 5432 : *: postgres : somepassword


      template I'm using are : Template PostgreSQL App
      PostgreSQL template SR App
      SR Template Cluster PostgreSQL App

      Focus in this part it says, is not suitable for the type of value [ Numeric ( unsigned ) ] and the data type [ Decimal ]

      Comment

      • ingus.vilnis
        Senior Member
        Zabbix Certified Trainer
        Zabbix Certified SpecialistZabbix Certified Professional
        • Mar 2014
        • 908

        #4
        I am not familiar with the templates you are using but apparently they are unable to pick up the password from the pgpass file and authorize. Check the macros in the template configurations. Do they hold the correct values?

        Code:
        {$PGSCRIPTDIR},{$PGSCRIPT_CONFDIR},{$Z ABBIX_AGENTD_CONF},{$PGSLOWQUERY_TIME_THRESHOLD}
        Originally posted by emijares
        Focus in this part it says, is not suitable for the type of value [ Numeric ( unsigned ) ] and the data type [ Decimal ]
        These are only consequences of the password issue.
        The item expects a numeric value, a number, but with wrong password an error message (Password for user postgres: psql: fe_sendauth: no password supplied) is returned and text is not suitable for numeric item type.

        Best Regards,
        Ingus

        Comment

        • kaloyan.s
          Junior Member
          • Nov 2016
          • 13

          #5
          You need to make zabbix user on the monitored machine able to execute commands.

          For example you can edit and create a home folder for zabbix and place the .pgpass file there:

          /etc/passwd
          zabbix:x:112:119::/var/lib/zabbix:/usr/sbin/nologin

          Comment

          Working...