• Icon: Specification change (Sub-task) Specification change (Sub-task)
    • Resolution: Unresolved
    • Icon: Major Major
    • None
    • 7.0.19rc1, 7.4.3rc1, 8.0.0alpha1 (master)
    • Templates (T)
    • None
    • 100

      As the 'SHOW SLAVE STATUS' command has been deprecated in MySQL 8.0.22 and has been removed in 8.4 MySQL templates should be updated accordingly to support the old and new syntax.

      Templates "MySQL by Zabbix Agent 2" (passive + active) does not need to be changed because support for both versions of the SQL query will be implemented in the built-in MySQL plugin.

      Templates "MySQL by ODBC" and "MySQL by Zabbix agent" (passive + active) must be changed so that the new syntax is used on MySQL versions starting with 8.0.22, and the old syntax is used on versions prior to 8.0.22.

      The correct syntax to use on recent MySQL instances is

      SHOW REPLICA STATUS;
      

      The output is largely still the same, apart from the fact that the word 'slave' has been replaced by 'replica' everywhere.

      Example output on MySQL 8.4.4:

      mysql> SHOW REPLICA STATUS\G
      *************************** 1. row ***************************
      Replica_IO_State: Waiting for source to send event
      Source_Host: db-test002
      Source_User: replication
      Source_Port: 3306
      Connect_Retry: 60
      Source_Log_File: binlog.000003
      Read_Source_Log_Pos: 69400133
      Relay_Log_File: db-test001-relay-bin.000008
      Relay_Log_Pos: 1116953
      Relay_Source_Log_File: binlog.000003
      Replica_IO_Running: Yes
      Replica_SQL_Running: Yes
      Replicate_Do_DB:
      Replicate_Ignore_DB:
      Replicate_Do_Table:
      Replicate_Ignore_Table:
      Replicate_Wild_Do_Table:
      Replicate_Wild_Ignore_Table:
      Last_Errno: 0
      Last_Error:
      Skip_Counter: 0
      Exec_Source_Log_Pos: 999999
      Relay_Log_Space: 1320102
      Until_Condition: None
      Until_Log_File:
      Until_Log_Pos: 0
      Source_SSL_Allowed: No
      Source_SSL_CA_File:
      Source_SSL_CA_Path:
      Source_SSL_Cert:
      Source_SSL_Cipher:
      Source_SSL_Key:
      Seconds_Behind_Source: 0
      Source_SSL_Verify_Server_Cert: No
      Last_IO_Errno: 0
      Last_IO_Error:
      Last_SQL_Errno: 0
      Last_SQL_Error:
      Replicate_Ignore_Server_Ids:
      Source_Server_Id: 123456789
      Source_UUID: 4h56eaa1-9954-11f0-8f10-0050ecf3fc
      Source_Info_File: mysql.slave_master_info
      SQL_Delay: 0
      SQL_Remaining_Delay: NULL
      Replica_SQL_Running_State: Replica has read all relay log; waiting for more updates
      Source_Retry_Count: 10
      Source_Bind:
      Last_IO_Error_Timestamp:
      Last_SQL_Error_Timestamp:
      Source_SSL_Crl:
      Source_SSL_Crlpath:
      Retrieved_Gtid_Set: 4h56eaa1-9954-11f0-8f10-0050ecf3fc:1-1642
      Executed_Gtid_Set: 3e17a135-b21f-11ef-8253-005056a6e3fc:1-246,
                         4fe736a8-319b-11f0-9a86-005056a6e3fc:1-1642,
                         93e5f697-b09b-11ef-945a-005056a6f7d2:1-21946840
      Auto_Position: 1
      Replicate_Rewrite_DB:
      Channel_Name:
      Source_TLS_Version:
      Source_public_key_path:
      Get_Source_public_key: 1
      Network_Namespace:
      

            abrosimovs Aleksejs Abrosimovs
            esneiders Eriks Sneiders
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - Not Specified
                Not Specified
                Logged:
                Time Spent - 109h
                109h