Skip to content
  • Venkatesh Venugopal's avatar
    70bb88ed
    Bug#29769293: ERROR 1236 "MASTER HAS PURGED BINARY LOGS CONTAINING GTIDS": GTID NOT LOGGED · 70bb88ed
    Venkatesh Venugopal authored
    This is a backport of Bug#26004541.
    
    Description
    -----------
    A misleading error message is outputted when
    ER_MASTER_HAS_PURGED_REQUIRED_GTIDS error is generated. The message
    should be changed and the user should be informed about the missing
    transactions and should be guided to a solution.
    
    Analysis
    --------
    - Message is stored in errmsg-utf8.txt.
    - The error message gets trimmed by wrapping error message defined in
      errmsg-utf8.txt. ER_MASTER_FATAL_ERROR_READING_BINLOG truncates the
      message if the message is of length more than 320 characters.
    - Increasing the message max length, for debugging purposes, disclosed
      another problem, the lack of escaping in
      ./include/show_slave_status.inc, which got broken because of
      unescaped '"' in the error message while executing:
    
      --let $_show_slave_status_value= SELECT REPLACE("$_show_slave_status_value",
                                       '$MYSQL_TEST_DIR', 'MYSQL_TEST_DIR')
    
    Fix
    ---
    - Log the missing GTIDs to the master's error log as a warning.
      If the missing GTIDs are too long to print in the message, suggest
      the steps to extract the missing transactions.
    - Write a not misleading error message that gives information about
      the GTID set sent by the slave, transactions missing on the master
      and few suggestions to recover from the error. This message shall be
      sent to slave and will be logged as an error wrapped by
      ER_MASTER_FATAL_ERROR_READING_BINLOG.
    - Increase the length of the wrapped error message to 512 characters.
      As a result, ER_MASTER_FATAL_ERROR_READING_BINLOG is now capable of
      wrapping the messages of length upto 512 characters.
    - Replace occurrences of old message in related test and result files.
    - Created escape_sql.inc script, providing SQL escaping functionality.
    
    Reviewed by: Pedro Figueiredo <pedro.figueiredo@oracle.com>
    Reviewed by: Pedro Gomes <pedro.gomes@oracle.com>
    
    RB: 22926, 23030, 23031
    70bb88ed
    Bug#29769293: ERROR 1236 "MASTER HAS PURGED BINARY LOGS CONTAINING GTIDS": GTID NOT LOGGED
    Venkatesh Venugopal authored
    This is a backport of Bug#26004541.
    
    Description
    -----------
    A misleading error message is outputted when
    ER_MASTER_HAS_PURGED_REQUIRED_GTIDS error is generated. The message
    should be changed and the user should be informed about the missing
    transactions and should be guided to a solution.
    
    Analysis
    --------
    - Message is stored in errmsg-utf8.txt.
    - The error message gets trimmed by wrapping error message defined in
      errmsg-utf8.txt. ER_MASTER_FATAL_ERROR_READING_BINLOG truncates the
      message if the message is of length more than 320 characters.
    - Increasing the message max length, for debugging purposes, disclosed
      another problem, the lack of escaping in
      ./include/show_slave_status.inc, which got broken because of
      unescaped '"' in the error message while executing:
    
      --let $_show_slave_status_value= SELECT REPLACE("$_show_slave_status_value",
                                       '$MYSQL_TEST_DIR', 'MYSQL_TEST_DIR')
    
    Fix
    ---
    - Log the missing GTIDs to the master's error log as a warning.
      If the missing GTIDs are too long to print in the message, suggest
      the steps to extract the missing transactions.
    - Write a not misleading error message that gives information about
      the GTID set sent by the slave, transactions missing on the master
      and few suggestions to recover from the error. This message shall be
      sent to slave and will be logged as an error wrapped by
      ER_MASTER_FATAL_ERROR_READING_BINLOG.
    - Increase the length of the wrapped error message to 512 characters.
      As a result, ER_MASTER_FATAL_ERROR_READING_BINLOG is now capable of
      wrapping the messages of length upto 512 characters.
    - Replace occurrences of old message in related test and result files.
    - Created escape_sql.inc script, providing SQL escaping functionality.
    
    Reviewed by: Pedro Figueiredo <pedro.figueiredo@oracle.com>
    Reviewed by: Pedro Gomes <pedro.gomes@oracle.com>
    
    RB: 22926, 23030, 23031
Loading