Ad Widget

Collapse

How to Update All Built-in Templates After Upgrading Zabbix?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • fuRyZ
    Junior Member
    • Apr 2019
    • 2

    #1

    How to Update All Built-in Templates After Upgrading Zabbix?

    hello all!
    I have a distributed Zabbix setup with two machines:
    • One machine runs Zabbix Server and Zabbix Agent, installed via the official repository.
    • Another machine is an HTTP server, hosting the Zabbix web interface.

    After upgrading Zabbix Server and Zabbix Agent, I ran /database/mysql/option-patches/history_upgrade_prepare.sql to update the database structure. I also updated the web files, and everything appears to be working fine.

    However, I noticed that the built-in templates are still on version 7.0.0, and I couldn't find any SQL scripts to update them. Since template data is stored in the database, I am unsure of the correct way to update all templates to match the latest version.

    What is the recommended method for updating the built-in templates after upgrading Zabbix?
  • fuRyZ
    Junior Member
    • Apr 2019
    • 2

    #2
    Additionally, I know how to update a single template, but that is not elegant. What I want to achieve is batch updating. Since my Zabbix Web and Zabbix Server are not on the same machine, the API service seems to be unavailable.

    Comment

    • cyber
      Senior Member
      Zabbix Certified SpecialistZabbix Certified Professional
      • Dec 2006
      • 4807

      #3
      Tempaltes are only installed on clean install. They are not touched during any upgrade, as they do not want to cause issues, if you have changed something or added.
      For now, it is mostly one by one update...If there is any update at all... The version number there does not really reflect your full zabbix version. more like major version, is it v6 or v7...
      You are not probably using all of them anyway, so download those you are using and try to import them, you will see the changes, if there is any, during that process...

      API endpoint is available on you webserver... https://example.com/zabbix/api_jsonrpc.php just as described in docs...

      Comment


      • fuRyZ
        fuRyZ commented
        Editing a comment
        I found a solution: I can first download the code package of the target upgrade version from Zabbix's Git repository, which includes the corresponding templates. Then, I can batch update them via the API, and I have successfully completed the update.
    Working...