• Marko Mäkelä's avatar
    MDEV-15270 Mariabackup should not try to use doublewrite buffer · 00f0c039
    Marko Mäkelä authored
    When Mariabackup gets a bad read of the first page of the system
    tablespace file, it would inappropriately try to apply the doublewrite
    buffer and write changes back to the data file (to the source file)!
    This is very wrong and must be prevented.
    
    The correct action would be to retry reading the system tablespace
    as well as any other files whose first page was read incorrectly.
    Fixing this was not attempted.
    
    xb_load_tablespaces(): Shorten a bogus message to be more relevant.
    The message can be displayed by --backup or --prepare.
    
    xtrabackup_backup_func(), os_file_write_func(): Add a missing space
    to a message.
    
    Datafile::restore_from_doublewrite(): Do not even attempt the
    operation in Mariabackup.
    
    recv_init_crash_recovery_spaces(): Do not attempt to restore the
    doublewrite buffer in Mariabackup (--prepare or --export), because
    all pages should have been copied correctly in --backup already,
    and because --backup should ignore the doublewrite buffer.
    
    SysTablespace::read_lsn_and_check_flags(): Do not attempt to initialize
    the doublewrite buffer in Mariabackup.
    
    innodb_make_page_dirty(): Correct the bounds check.
    
    Datafile::read_first_page(): Correct the name of the parameter.
    00f0c039
ha_innodb.cc 642 KB