1. 16 Aug, 2018 6 commits
    • Marko Mäkelä's avatar
      Merge 10.2 into 10.3 · 1eb2d8f6
      Marko Mäkelä authored
      1eb2d8f6
    • Marko Mäkelä's avatar
      Report all redo log corruption · 05153a67
      Marko Mäkelä authored
      Amend commit b853b4fd
      that was reverted in commit 29150e23.
      
      recv_parse_log_recs(): Do check for corrupted redo log or file
      system before checking for len==0, but only read *ptr if
      it is not past the end of the buffer (end_ptr).
      
      recv_parse_log_rec(): Report incorrect redo log type
      in a consistent way with recv_parse_or_apply_log_rec_body().
      This is a follow-up to commit f30c5af4.
      05153a67
    • Marko Mäkelä's avatar
      MDEV-16136 Various ASAN failures after MDEV-15030 · a0ce3216
      Marko Mäkelä authored
      The Pool poisoning that was introduced in MDEV-15030 introduced
      race conditions in AddressSanitizer builds, because concurrent
      poisoning and unpoisoning were not prevented by any synchronization
      primitive.
      
      Pool::get(): Protect the unpoisoning by m_lock_strategy.
      
      Pool::mem_free(): Protect the poisoning by m_lock_strategy.
      
      Pool::putl(): Renamed from put(), because now the caller is
      responsible for invoking m_lock_strategy.
      a0ce3216
    • Marko Mäkelä's avatar
      MDEV-16136: Prevent wrong reuse in trx_reference() · fa2a74e0
      Marko Mäkelä authored
      If trx_free() and trx_create_low() were called while a call to
      trx_reference() was pending, we could get a reference to a wrong
      transaction object.
      
      trx_reference(): Return NULL if the trx->id no longer matches.
      
      lock_trx_release_locks(): Assign trx->id = 0, so that trx_reference()
      will not return a reference to this object.
      
      trx_cleanup_at_db_startup(): Assign trx->id = 0.
      
      assert_trx_is_free(): Assert !trx->n_ref. Assert trx->id == 0,
      now that it will be cleared as part of a transaction commit.
      fa2a74e0
    • Marko Mäkelä's avatar
      Rename lock_pool_t to lock_list · 65835065
      Marko Mäkelä authored
      Also, replace reverse iteration with forward iteration.
      
      lock_table_has(): Remove a redundant condition.
      65835065
    • Marko Mäkelä's avatar
      MDEV-16136: Simplify trx_lock_t memory management · 3ce8a0fc
      Marko Mäkelä authored
      Allocate trx->lock.rec_pool and trx->lock.table_pool directly from trx_t.
      Remove unnecessary use of std::vector.
      
      In order to do this, move some definitions from lock0priv.h to
      lock0types.h, so that ib_lock_t will not be an opaque type.
      3ce8a0fc
  2. 15 Aug, 2018 2 commits
  3. 14 Aug, 2018 3 commits
  4. 13 Aug, 2018 6 commits
  5. 12 Aug, 2018 16 commits
  6. 10 Aug, 2018 4 commits
    • Otto Kekäläinen's avatar
      Deb: Make libmariadb3 Breaks+Replaces libmariadbclient18 so upgrade pass · 9dd3e5ea
      Otto Kekäläinen authored
      The package libmariadbclient18 contains the dialog.so plugin, which also
      the new libmariadb3 ships. As they both use the exact same path the latter
      must be marked as a with Breaks and Replaces relations ship.
      
      Note: This fix is conservative hack for stable releases 10.2 and 10.3.
      In 10.4, the development release at the time, we will clean up how the
      libmariadb3 packaging and it's -compat packages are done to match that
      what is done in downstream Debian official.
      9dd3e5ea
    • Marko Mäkelä's avatar
      Revert part of b853b4fd · 29150e23
      Marko Mäkelä authored
      recv_parse_log_recs(): Do not check for corruption before
      checking for end-of-log-buffer. For some reason, adding the
      check to the logical-looking place would cause intermittent
      recovery failures in the tests innodb.innodb-index and
      innodb_gis.rtree_compress2.
      29150e23
    • Marko Mäkelä's avatar
      Report InnoDB redo log corruption better · b853b4fd
      Marko Mäkelä authored
      recv_parse_log_recs(): Check for corruption before checking for
      end-of-log-buffer.
      
      mlog_parse_initial_log_record(), page_cur_parse_delete_rec():
      Flag corruption for out-of-bounds values, and let the caller
      dump the corrupted redo log extract.
      b853b4fd
    • Marko Mäkelä's avatar
      recv_report_corrupt_log(): Avoid buffer overflow · 0e15ae16
      Marko Mäkelä authored
      If recv_sys_justify_left_parsing_buf() has been invoked, it is possible
      that recv_previous_parsed_rec_offset is after the current offset.
      In this case, we must not dump any bytes before the current record.
      0e15ae16
  7. 09 Aug, 2018 3 commits
    • Marko Mäkelä's avatar
      log_group_read_log_seg(): Validate the length · bdf50c3e
      Marko Mäkelä authored
      If the LOG_BLOCK_HDR_DATA_LEN field is corrupted, scanning the
      log records could fail in strange ways. It is better to validate
      the field as part of validating each log block.
      bdf50c3e
    • Marko Mäkelä's avatar
      InnoDB: Correct an error message · f30c5af4
      Marko Mäkelä authored
      Display the log record type in hexadecimal, not binary.
      f30c5af4
    • Otto Kekäläinen's avatar
      Deb: Make libmariadb3 Breaks+Replaces libmariadbclient18 so upgrade pass · 10d347dc
      Otto Kekäläinen authored
      The package libmariadbclient18 contains the dialog.so plugin, which also
      the new libmariadb3 ships. As they both use the exact same path the latter
      must be marked as a with Breaks and Replaces relations ship.
      
      Note: This fix is conservative hack for stable releases 10.2 and 10.3.
      In 10.4, the development release at the time, we will clean up how the
      libmariadb3 packaging and it's -compat packages are done to match that
      what is done in downstream Debian official.
      10d347dc