Ad Widget

Collapse

database upgrade failed on patch 06000011, exiting in 10 seconds

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • wwwzebra
    Junior Member
    • Dec 2023
    • 19

    #1

    database upgrade failed on patch 06000011, exiting in 10 seconds

    Hello!

    Ubuntu 22.04.3LTS
    Zabbix 5.4 --> 6.0.25

    After upgrading get an error on 89%

    sudo cat /var/log/zabbix/zabbix_server.log | grep database
    ...89%
    10944:20231214:174501.412 starting automatic database upgrade
    10944:20231214:174501.413 database upgrade failed on patch 06000011, exiting in 10 seconds
    10944:20231214:174511.416 database could be upgraded to use primary keys in history tables
    10957:20231214:174521.675 current database version (mandatory/optional): 06000000/06000010
    10957:20231214:174521.675 starting automatic database upgrade
    10957:20231214:174521.677 database upgrade failed on patch 06000011, exiting in 10 seconds

    What can I do?
    Thx​
  • cyber
    Senior Member
    Zabbix Certified SpecialistZabbix Certified Professional
    • Dec 2006
    • 4806

    #2
    Reread all the prerequisites for upgrade. all the DB related permissions etc.. I suspect there are some DB settings you must tweak...
    Currently it fails with adding a trigger to hosts table...

    Code:
    static int DBpatch_6000011(void)
    {
    if (SUCCEED == DBtrigger_exists("hosts", "hosts_name_upper_insert"))
    {
    zabbix_log(LOG_LEVEL_WARNING, "hosts_name_upper_insert trigger for table \"hosts\" already exists,"
    " skipping patch of adding it to \"hosts\" table");
    return SUCCEED;
    }
    
    return zbx_dbupgrade_attach_trigger_with_function_on_inse rt("hosts", "name", "name_upper", "upper", "hostid");
    }

    Comment

    • wwwzebra
      Junior Member
      • Dec 2023
      • 19

      #3
      Thank You for answer
      All was done by this article
      Upgrade Zabbix (5.0, 5.2, 5.4) to 6.0 like a Pro [+6.0 to 6.4 guide] (bestmonitoringtools.com)

      May be I need to do something before update? (It's VM and I have snapshots)
      How or where can I see? Is there any scripts - to check DB?

      Thx

      Comment

      • wwwzebra
        Junior Member
        • Dec 2023
        • 19

        #4
        Tried to do again, using this article


        I did this first:
        mysql> SET GLOBAL log_bin_trust_function_creators = 1;
        as it was recomended https://www.zabbix.com/documentation...rade_notes_640

        And after that

        wget https://repo.zabbix.com/zabbix/6.5/u...u22.04_all.deb
        sudo dpkg -i zabbix-release_6.5-1+ubuntu22.04_all.deb
        sudo apt update
        sudo apt upgrade
        sudo service zabbix-server start

        and checked DB
        sudo cat /var/log/zabbix/zabbix_server.log | grep database

        98919:20231215:151615.339 current database version (mandatory/optional): 05040000/05040001
        98919:20231215:151615.340 starting automatic database upgrade
        98919:20231215:151615.359 completed 0% of database upgrade
        98919:20231215:151615.456 completed 1% of database upgrade
        ...
        98919:20231215:151635.006 completed 98% of database upgrade
        98919:20231215:151635.301 completed 99% of database upgrade
        98919:20231215:151635.423 completed 100% of database upgrade
        98919:20231215:151635.589 database upgrade fully completed
        98919:20231215:151635.591 database could be upgraded to use primary keys in history tables


        As far as I can understand - DB was upgraded and now it works fine?

        I need only to "...upgradу to use primary keys in history tables"
        Yes?

        Comment

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

          #5
          yes... now it works but could be upgraded some more... with primary keys.

          Comment

          • shay123
            Junior Member
            • Mar 2023
            • 1

            #6
            hi I have the same issue with import DB from 6.4 to 7

            starting automatic database upgrade
            137870:20240716:202049.698 database upgrade failed on patch 06050013, exiting in 10 seconds

            DetailsCannot connect to the database.
            • The Zabbix database version does not match current requirements. Your database version: 6050012. Required version: 7000000. Please contact your system administrator.

            ​help please?

            tried everything on top anyone tried to update recently?

            Comment


            • krawler656
              krawler656 commented
              Editing a comment
              step 1: service zabbix-server stop
              step 2: mysql -u root -p
              step 3: SET GLOBAL log_bin_trust_function_creators = 1;
              step 4: service zabbix-server start
              step 5: tail -f /var/log/zabbix/zabbix_server.log|grep database
          • kuPyxa
            Junior Member
            • Dec 2024
            • 1

            #7
            Originally posted by shay123
            hi I have the same issue with import DB from 6.4 to 7

            starting automatic database upgrade
            137870:20240716:202049.698 database upgrade failed on patch 06050013, exiting in 10 seconds

            DetailsCannot connect to the database.
            • The Zabbix database version does not match current requirements. Your database version: 6050012. Required version: 7000000. Please contact your system administrator.

            help please?

            tried everything on top anyone tried to update recently?
            Try checking MySQL error log. In my case group replication was enabled, just disable it during upgrade.

            Comment

            Working...