• unknown's avatar
    WL#3072 Maria recovery · 8f714513
    unknown authored
    - fixes (in recovery, checkpoint, log handler) of bugs found
    during testing.
    - new option --check for maria_read_log: with --only-display (which only
    reads the header) it reads the full record, for debugging.
    
    
    storage/maria/ma_loghandler.c:
      importing patch from Sanja for bug of translog_next_LSN() found
      during recovery
    storage/maria/ma_loghandler_lsn.h:
      better types (0L is 4 bytes on some platforms, it causes problems
      when used into lsn_store(): right shift >= width of type.
    storage/maria/ma_pagecache.c:
      work around infamous "PAGECACHE_PLAIN_PAGE used for transactional
      tables in specialm case"; REDO phase disables logging and this causes
      pages to be PAGECACHE_PLAIN_PAGE, thus ignored wrongly by the
      checkpoint taken at the end of the REDO phase.
    storage/maria/ma_recovery.c:
      - a #ifdef which broke maria_read_log in non-debug builds (no output!)
      - support for maria_read_log --check
      - detect record corruption before opening the table
      - updating is_of_horizon requires writing the state
      - fix for wrong parsing of checkpoint record by recovery
    storage/maria/ma_recovery.h:
      support for maria_read_log --check
    storage/maria/maria_read_log.c:
      Option --check: --only-display only looks at the header;
      adding --check tries a translog_read_record() to see if record can
      be fully read (this is to find bugs).
    8f714513
ma_loghandler.c 221 KB