Ad Widget

Collapse

upgrade 4.0 to 6.0 recommendation

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • tvtue
    Member
    • Sep 2012
    • 71

    #1

    upgrade 4.0 to 6.0 recommendation

    Dear Zabbix Users,

    we are planning a major upgrade from 4.0 to 6.0.

    Current system is CentOS7 with PostgreSQL 12, no custom partitioning or any other scripts, 16 proxies, database size is about 350 GB, the pg_dumpall file compressed is 20 GB.

    Target system should be RHEL8 with php7, PostgreSQL14 which I have in prepared before the upgrade. I.e. I have installed the RHEL8, php7 and Zabbix6 on a fresh system.


    The following procedure is what I think up about after I read through the upgrade documentation:

    1) disable all trigger actions

    2) disable all hosts that are monitored by proxies

    3) stop all proxies

    4) stop zabbix-server and frontend

    5) do a pg_dumpall (ascii format)

    6) copy the dump file over to the new Zabbix server system and import it into the PostgreSQL 14 database



    7) At this point I am not sure how to proceed. I would like to take advantage of the improved performance by using primary keys in Zabbix 6.0. So should I continue with the primary key script now? On the other hand there is this blog post (https://blog.zabbix.com/a-guide-to-m...ne-2021/18569/) which does not recommend doing the primary key change „when upgrading an existing instance“.



    8) Apply the double.sql script on the database

    9) then timescale or better wait with that and do that some time later?

    10) start zabbix-server on the new system and watch it converting the database in the log

    11) start the frontend

    12) check if everything works so far, then take over the ip address and name of the old system, do a reboot

    13) upgrade proxies and start them

    14) enable hosts

    15) enable trigger actions




    Thank you for your thoughts and recommendations

    Cheers

    Timo
  • Linwood
    Senior Member
    • Dec 2013
    • 398

    #2
    I was just going through this on a much smaller scale... Are you sure Zabbix 6.0 supports Postgresql 14, everything I see says 13.x explicitly, under requirements and under the upgrade notes, nothing about "or later".

    I ran through an upgrade from sources on a small test instance. I also did it in place (using a VM snapshot). I did do the primary key update (but it was a tiny instance). My reading of that blog is that it is "not recommended" due to the length of time it will take. I have no idea how long it will be for a production system, but am inclined to get it over with.

    I did not do the timescale stuff, I saved it for later as I knew nothing about that feature, am curious how big of a benefit one gets from it.

    Comment

    • tvtue
      Member
      • Sep 2012
      • 71

      #3
      Dear Linwood,
      thank you for your reply. Indeed I did not check whether Postgresql 14 is supported beforehand. You are right, it seems that only 13 is supported. Maybe 14 will show up in the requirements for Zabbix 6.0.1? I have to do a test installation anyway so I will see. I am new to the timescale stuff too so I will probably leave it out for now. The step from 4.0 to 6.0 is big enough already.
      Cheers,
      Timo

      Comment

      • tvtue
        Member
        • Sep 2012
        • 71

        #4
        Just in case anyone is interested in the progress of this:

        I did a test upgrade and here are my findings
        - The import of the pg_dumpall file took 56 minutes.
        - Applying the double.sql script took 13 minutes.
        - Then I did the primary key changes (described here https://www.zabbix.com/documentation...eys#postgresql). That took 5 hours for the history_uint table, 74 minutes for history table and 28 min for the history_str table. The other history tables could be ex- and imported in less time. I found that not worth to mention compared to the aforementioned.
        - The initial start of the zabbix-server converted the database to 6.0 version in about 1 min.
        - I did not apply the timescale stuff.
        The update seems to be ok, it only took a long time and I the zabbix server log complains this:

        zabbix_server[24598]: /usr/sbin/zabbix_server: /usr/pgsql-14/lib/libpq.so.5: no version information available (required by /usr/sbin/zabbix_server)

        Which is probabbly the upper mentioned PostgreSQL 14 version mismatch. I hope this will come with 6.0.1.

        Comment

        • tvtue
          Member
          • Sep 2012
          • 71

          #5
          Oh, I found this

          Comment

          • tvtue
            Member
            • Sep 2012
            • 71

            #6
            [root@zbx60 ~]# rpm -qf /usr/pgsql-14/lib/libpq.so.5
            postgresql14-libs-14.2-1PGDG.rhel8.x86_64

            [root@zbx60 ~]# rpm -qa | grep postgres
            timescaledb-2-loader-postgresql-14-2.6.0-0.el8.x86_64
            postgresql14-libs-14.2-1PGDG.rhel8.x86_64
            postgresql14-contrib-14.2-1PGDG.rhel8.x86_64
            postgresql14-14.2-1PGDG.rhel8.x86_64
            postgresql14-docs-14.2-1PGDG.rhel8.x86_64
            timescaledb-2-postgresql-14-2.6.0-0.el8.x86_64
            postgresql14-server-14.2-1PGDG.rhel8.x86_64

            Comment

            • tvtue
              Member
              • Sep 2012
              • 71

              #7
              and this: https://support.zabbix.com/browse/ZBX-19801

              Comment

              • Myron9822
                Junior Member
                • Feb 2022
                • 1

                #8
                My reading of that blog is that it is "not recommended" due to the length of time it will take. I have no idea how long it will be for a production system, but am inclined to get it over with.

                Comment

                • tvtue
                  Member
                  • Sep 2012
                  • 71

                  #9


                  seems that postgresql 14 should be supported, but I am getting that ugly error. Is it an error then?

                  Comment

                  • RKZabbix
                    Junior Member
                    • Sep 2022
                    • 3

                    #10
                    could someone please tell me the recommended parameters during 6.0 upgrade for the below?
                    CacheSize
                    CacheUpdateFrequency
                    DebugLevel
                    HistoryCacheSize
                    HistoryIndexCacheSize
                    LogFileSize
                    LogSlowQueries
                    MaxHousekeeperDelete
                    ProxyConfigFrequency
                    ProblemHousekeepingFrequency
                    ProxyDataFrequency
                    ServiceManagerSyncFrequency
                    SNMPTrapperFile
                    StartAlerters
                    StartDBSyncers
                    StartDiscoverers
                    StartEscalators
                    StartHistoryPollers
                    StartHTTPPollers
                    StartIPMIPollers
                    StartJavaPollers
                    StartLLDProcessors
                    StartODBCPollers
                    StartPingers
                    StartPollersUnreachable
                    StartPollers
                    StartPreprocessors
                    StartProxyPollers
                    StartReportWriters
                    StartSNMPTrapper
                    StartTimers
                    StartTrappers
                    StartVMwareCollectors
                    Timeout
                    TrapperTimeout
                    TrendCacheSize
                    TrendFunctionCacheSize
                    UnavailableDelay
                    UnreachableDelay
                    UnreachablePeriod
                    ValueCacheSize
                    VMwareCacheSize
                    VMwareFrequency
                    VMwarePerfFrequency
                    VMwareTimeout
                    WebServiceURL

                    Comment

                    Working...