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

Zabbix Agent 2: allowing dashes in config keys

XMLWordPrintable

    • Team INT

      Hi.

       

      Issue:

      Zabbix-agent2 does not allow dashes in it's config keys - but PostgreSQL, MySQL and Oracle do allow database names to have dashes in them. And we do have databases with hyphens in their names.

       

      That means that we can't create per-database sessions without workarounds - such as replacing all hyphens with underscores inside config and using regsub in item keys. Which is hacky at best.

       

      The old syntax (4-tuple of connstring, user, pass, db) doesn't scale - it will eat up to (databases * per-db-items) connections.

       

      Seems like slightly changing validateParameterName is all that required to allow hyphens ( https://git.zabbix.com/projects/AP/repos/plugin-support/browse/conf/conf.go ).

       

      Alternatively, allowing quotes inside parameter names will also work. (i.e. .Session."prod-db".Username).

       

      Can you share your opinion on this?

            zit Zabbix Integration Team
            YaDr Iaroslav Dronskii
            Team INT
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: