Ad Widget

Collapse

Upgrade Zabbx4.0.7 to Zabbix4.4

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Tek Chand
    Member
    • Mar 2019
    • 57

    #1

    Upgrade Zabbx4.0.7 to Zabbix4.4

    Hello All,

    Currently we are using zabbix4.0.7 and we want to upgrade it to zabbix4.4. I have followed the below steps in my testing environment:

    Code:
    service stop zabbix-server
    service stop zabbix-agent
    rm -Rf /etc/apt/sources.list.d/zabbix.list
    wget https://repo.zabbix.com/zabbix/4.4/ubuntu/pool/main/z/zabbix-release/zabbix-release_4.4-1+bionic_all.deb
    dpkg -i zabbix-release_4.4-1+bionic_all.deb
    apt-get update
    apt-get install --only-upgrade zabbix-server-mysql zabbix-frontend-php zabbix-agent
    apt-get install zabbix-apache-conf 
    service zabbix-server start
    service zabbix-agent start
    But when i try to access the zabbix dashboard i am getting below error:

    Code:
    The frontend does not match Zabbix database. Current database version (mandatory/optional): 4000000/4000004. Required mandatory version: 4040000. Contact your system administrator.
    Even when i checked the `zabbix_server.conf` file i didn't found my old configuration like DBPassword etc. Its seems its replaced with new file.

    Can you please help me how we can upgrade existing zabbix to higher version without any file configuration changes.

    Thanks.
  • Atsushi
    Senior Member
    • Aug 2013
    • 2028

    #2
    The following procedure was not overwritten without confirmation.

    Code:
    $ sudo dpkg -i zabbix-release_4.4-1+bionic_all.deb
    $ sudo apt update
    $ sudo apt upgrade zabbix-server-mysql zabbix-frontend-php zabbix-agent
    A choice of whether to overwrite is displayed. By default, it should not be overwritten.
    When upgrading from 4.0 to 4.4, the following packages must also be installed.

    Code:
    $ sudo apt install zabbix-apache-conf
    Web front end errors will be resolved after the database upgrade process when starting Zabbix server.

    Comment

    • Tek Chand
      Member
      • Mar 2019
      • 57

      #3
      Atsushi , Thank you for your response. I will again setup my test lab and try.

      But i am facing one more, we want to monitor our postgresql DB also in Zabbix4.4 so we are testing same also using the below link:

      https://git.zabbix.com/projects/ZBX/.../db/postgresql

      But i didn't found any /var/lib/zabbix directory in step 2 as per documentation on my agent side. My agent version is 4.0.

      Can you please help me where we need to copy postgresql directory according to doc?

      Thanks.

      Comment


      • Atsushi
        Atsushi commented
        Editing a comment
        If /var/lib/zabbix directory do not exist, create it yourself. The copy destination is as in the document.
    • Tek Chand
      Member
      • Mar 2019
      • 57

      #4
      Atsushi , What will be the permission and ownership for /var/lib/zabbix directory?

      And i have imported template_db_postgresql.xml into template but didn't see any such template in template list. Can you please help me with some steps?

      Thanks.
      Last edited by Tek Chand; 06-12-2019, 11:32.

      Comment


      • Atsushi
        Atsushi commented
        Editing a comment
        The permissions and owner of the /var/lib/zabbix directory must be accessible to the zabbix user.
        For .pgpass files, read / write only for zabbix users.

        ex.
        # chown zabbix:zabbix ~zabbix/.pgpass
        # chmod 600 ~zabbix/.pgpass

        Although it was the post of the other day, if you are trying to import a Zabbix 4.2 template into Zabbix 4.0, it is impossible. It is sure to prepare a Zabbix 4.2 or later environment and manually set the same setting to 4.0.
    • Tek Chand
      Member
      • Mar 2019
      • 57

      #5
      Atsushi , I am really confused, we need to perform the steps which are mentioned in below doc over Zabbix server or over the machine where we have our Postgresql DB and running zabbix agent over it to monitor it using zabbix?

      https://git.zabbix.com/projects/ZBX/.../db/postgresql

      If we need to perform these steps over Zabbix server then how it will monitor the postgresql DB which are running over another machines?

      One more question this template is written for 4.2 i am running 4.4 and it was imported successfully. Can we use this template in 4.4?

      I know its very silly question but i am really confused.

      Please help me.

      Thanks.
      Last edited by Tek Chand; 06-12-2019, 12:45.

      Comment

      • Tek Chand
        Member
        • Mar 2019
        • 57

        #6
        Atsushi , Zabbix4.2 come with postgresql template. Now when we import the new template 'template_db_postgresql.xml' we need to delete the template which come with zabbix4.2 or we can import it directly?

        https://git.zabbix.com/projects/ZBX/.../db/postgresql

        Please help me.

        Thanks.

        Comment

        Working...