Uploaded image for project: 'ZABBIX BUGS AND ISSUES'
  1. ZABBIX BUGS AND ISSUES
  2. ZBX-17841

Template DB PostgreSQL Agent 2 doesn't use {$PG.USER} macros for many items

XMLWordPrintable

    • Icon: Problem report Problem report
    • Resolution: Won't fix
    • Icon: Major Major
    • None
    • 5.0.1rc1
    • Templates (T)
    • Team INT
    • Sprint 65 (Jun 2020), Sprint 66 (Jul 2020), Sprint 67 (Aug 2020), Sprint 68 (Sep 2020), Sprint 69 (Oct 2020), Sprint 70 (Nov 2020), Sprint 71 (Dec 2020), Sprint 72 (Jan 2021), Sprint 73 (Feb 2021), Sprint 74 (Mar 2021), Sprint 75 (Apr 2021), Sprint 76 (May 2021), Sprint 77 (Jun 2021), Sprint 78 (Jul 2021), Sprint 79 (Aug 2021), Sprint 80 (Sep 2021), Sprint 81 (Oct 2021), Sprint 82 (Nov 2021), Sprint 83 (Dec 2021), Sprint 84 (Jan 2022), Sprint 85 (Feb 2022), Sprint 86 (Mar 2022), Sprint 87 (Apr 2022), Sprint 88 (May 2022), Sprint 89 (Jun 2022), Sprint 90 (Jul 2022)

      Steps to reproduce:

      1. zabbix-server with postgresql is used
      2. Install and run zabbix-agent2 on zabbix-server host
      3. Add user zbx_monitor to postgresql DB
      4. configure {$PG.USER}=zbx_monitor and {$PG.PASSWORD} macros fro zabbix-server host
      5. Add template "Template DB PostgreSQL Agent 2" to zabbix-server host

      Result:
      See log file zabbix_agent2.log. it will be a lot of messages like

      2020/05/29 10:14:41.280191 [Postgres] connection error: Cannoe etabilish connection to Postgres server: failed to connect to `host=localhost user=postgres database=postgres`: server error (FATAL: password authentication failed for user "postgres" (SQLSTATE 28P01))

      Expected:
      Template "Template DB PostgreSQL Agent 2" should use {$PG.USER} and {$PG.PASSWORD} macros for all items.

       

      Workaround: configure user/password via agent configuration files (Plugins.Postgres.User and Plugins.Postgres.Password parameters). This workaround requires zabbix-agent2 configuration changes instead of centralised management via host configuration on zabbix server.

            zabbix.dev Zabbix Development Team
            sergey1234 sergey1234
            Team INT
            Votes:
            8 Vote for this issue
            Watchers:
            9 Start watching this issue

              Created:
              Updated:
              Resolved: