1. 15 Jun, 2018 2 commits
  2. 13 Jun, 2018 1 commit
  3. 12 Jun, 2018 1 commit
    • Marko Mäkelä's avatar
      MDEV-16469 SET GLOBAL innodb_change_buffering has no effect · b52bb6eb
      Marko Mäkelä authored
      When type of the settable global variable innodb_change_buffering was
      changed from string to ENUM in MDEV-12218, the "shadow" variable ibuf_use
      stopped being updated as a result of SET GLOBAL innodb_change_buffering.
      Only on InnoDB startup, the parameter innodb_change_buffering would
      take effect.
      
      ibuf_use: Remove, and use the global variable innodb_change_buffering.
      b52bb6eb
  4. 08 Jun, 2018 1 commit
  5. 07 Jun, 2018 3 commits
    • Marko Mäkelä's avatar
      Merge 10.2 into 10.3 · 62d21dda
      Marko Mäkelä authored
      62d21dda
    • Marko Mäkelä's avatar
      MDEV-16367 mariabackup: error: failed to copy enough redo log · dc9c5554
      Marko Mäkelä authored
      log_copying_thread(): Keep copying redo log until the end has been
      reached. (Previously, we would stop copying as soon as
      the first batch of xtrabackup_copy_logfile() returned.)
      
      log_copying: Remove. Use log_copying_running instead.
      
      copy_logfile: Remove. Log copying will now only be invoked from
      2 places: from xtrabackup_backup_func() for the initial batch,
      and from log_copying_thread() until all of the log has been read.
      Use the global variable metadata_to_lsn for determining if the
      final part of the log is being copied.
      
      xtrabackup_copy_log(): Add diagnostic messages for terminating
      the copying. These messages should be dead code, because
      log_group_read_log_seg() should be checking for the same.
      
      xtrabackup_copy_logfile(): Correct the retrying logic.
      If anything was successfully read, process the portion that
      was read. On failure, let the caller close dst_log_file.
      
      io_watching_thread(): Stop throttling during the last phase
      of copying the log (metadata_to_lsn!=0). The final copying
      of the log will now be performed in log_copying_thread().
      
      stop_backup_threads(): Clean up the message about stopping
      the log copying thread.
      
      xtrabackup_backup_low(): Read metadata_to_lsn from the latest
      checkpoint header page, even if it is the first page.
      Let the log_copying_thread take care of copying all of
      the redo log.
      dc9c5554
    • Marko Mäkelä's avatar
      Mariabackup: Make some globals static · 619c277a
      Marko Mäkelä authored
      619c277a
  6. 06 Jun, 2018 2 commits
  7. 05 Jun, 2018 8 commits
    • Marko Mäkelä's avatar
      MDEV-16124 fil_rename_tablespace() times out and crashes server during table-rebuilding ALTER TABLE · 55abcfa7
      Marko Mäkelä authored
      InnoDB insisted on closing the file handle before renaming a file.
      Renaming a file should never be a problem on POSIX systems. Also on
      Windows it should work if the file was opened in FILE_SHARE_DELETE
      mode.
      
      fil_space_t::stop_ios: Remove. We no longer need to stop file access
      during rename operations.
      
      fil_mutex_enter_and_prepare_for_io(): Remove the wait for stop_ios.
      
      fil_rename_tablespace(): Remove the retry logic; do not close the
      file handle. Remove the unused fault injection that was added along
      with the DATA DIRECTORY functionality (MySQL WL#5980).
      
      os_file_create_simple_func(), os_file_create_func(),
      os_file_create_simple_no_error_handling_func(): Include FILE_SHARE_DELETE
      in the share_mode. (We will still prevent multiple InnoDB instances
      from using the same files by not setting FILE_SHARE_WRITE.)
      55abcfa7
    • Otto Kekäläinen's avatar
    • Daniel Black's avatar
      MDEV-16318: mysqld_safe - partial revert on 64094e12 · 88a263ea
      Daniel Black authored
      Revert part of 64094e12 because mysqld_safe isn't just used for
      Debian. As such references to specific packaging files like
      /etc/mysql/debian.cnf shouldn't have passed a review.
      
      There's also no history of why 64094e12 was needed based on
      the history of debian/patches/38_scripts__mysqld_safe.sh__signals.dpatch
      
      Other distos have survived without mysqld_safe handling signals.
      88a263ea
    • Daniel Black's avatar
      mysqld_safe: use sh not bash · c10bed17
      Daniel Black authored
      c902d5a4 changed this to bash.
      This isn't approprate as mysqld_safe is used by FreeBSD where
      there is no bash by default.
      
      The original reason to use bash seems related to MDEV-3279 which
      was a dash bug fixed in 2009 - https://git.kernel.org/pub/scm/utils/dash/dash.git/commit/?id=3800d4934391b144fd261a7957aea72ced7d47ea
      
      Working around 9 year old fixed bugs shouldn't be done here.
      c10bed17
    • Marko Mäkelä's avatar
      MDEV-15824 innodb_defragment=ON trumps innodb_optimize_fulltext_only=ON in OPTIMIZE TABLE · 3b7da8a4
      Marko Mäkelä authored
      ha_innobase::optimize(): If both innodb_defragment and
      innodb_optimize_fulltext_only are at their default settings (OFF),
      fall back to ALTER TABLE. Else process one or both options.
      3b7da8a4
    • Marko Mäkelä's avatar
    • Marko Mäkelä's avatar
      Remove dead code that was added in MDEV-5834 · 41cbe92b
      Marko Mäkelä authored
      ha_innobase::set_partition_owner_stats(): Remove (unused function).
      
      ha_innobase::ha_partition_stats: Remove (the variable is never read).
      
      Remove unused ut_timer functions.
      41cbe92b
    • Alexander Barkov's avatar
      MDEV-16385 ROW SP variable is allowed in unexpected context · 106f0b57
      Alexander Barkov authored
      The problem described in the bug report happened because the code
      did not test check_cols(1) after fix_fields() in a few places.
      
      Additionally, fix_fields() could be called multiple times for SP variables,
      because they are all fixed at a early stage in append_for_log().
      
      Solution:
      1. Adding a few helper methods
         - fix_fields_if_needed()
         - fix_fields_if_needed_for_scalar()
         - fix_fields_if_needed_for_bool()
         - fix_fields_if_needed_for_order_by()
        and using it in many cases instead of fix_fields() where
        the "fixed" status is not definitely known to be "false".
      
      2. Adding DBUG_ASSERT(!fixed) into Item_splocal*::fix_fields()
         to catch double execution.
      
      3. Adding tests.
      
      As a good side effect, the patch removes a lot of duplicate code (~60 lines):
      
         if (!item->fixed &&
             item->fix_fields(..) &&
             item->check_cols(1))
           return true;
      106f0b57
  8. 04 Jun, 2018 3 commits
    • Marko Mäkelä's avatar
      Merge 10.2 into 10.3 · b50685af
      Marko Mäkelä authored
      b50685af
    • Marko Mäkelä's avatar
      MDEV-16376 ASAN: heap-use-after-free in gcol.innodb_virtual_debug · 8dc70c86
      Marko Mäkelä authored
      After a failed ADD INDEX, dict_index_remove_from_cache_low()
      could iterate the index fields and dereference a freed virtual
      column object when trying to remove the index from the v_indexes
      of the virtual column.
      
      This regression was caused by a merge of
      MDEV-16119 InnoDB lock->index refers to a freed object.
      
      ha_innobase_inplace_ctx::clear_added_indexes(): Detach the
      indexes of uncommitted indexes from virtual columns, so that
      the iteration in dict_index_remove_from_cache_low() can be avoided.
      
      ha_innobase::prepare_inplace_alter_table(): Ignore uncommitted
      corrupted indexes when rejecting ALTER TABLE. (This minor bug was
      revealed by the extension of the test case.)
      
      dict_index_t::detach_columns(): Detach an index from virtual columns.
      Invoked by both dict_index_remove_from_cache_low() and
      ha_innobase_inplace_ctx::clear_added_indexes().
      
      dict_col_t::detach(const dict_index_t& index): Detach an index from
      a column.
      
      dict_col_t::is_virtual(): Replaces dict_col_is_virtual().
      
      dict_index_t::has_virtual(): Replaces dict_index_has_virtual().
      8dc70c86
    • Marko Mäkelä's avatar
      MDEV-13834: Upgrade failure from 10.1 innodb_encrypt_log · 5932a4e7
      Marko Mäkelä authored
      log_crypt_101_read_block(): Mimic MariaDB 10.1, and use the first
      encryption key if the key for the checkpoint cannot be found.
      Redo log encryption key rotation was ultimately disabled
      in MDEV-9422 (MariaDB 10.1.13) due to design issues. So, from
      MariaDB 10.1.13 onwards only one log encryption key should matter.
      
      recv_log_format_0_recover(): Add the parameter 'bool crypt'.
      Indicate when the log cannot be decrypted for upgrade, instead of
      making a possibly false claim that the log requires crash recovery.
      
      init_crypt_key(): Remove extra space from a message.
      5932a4e7
  9. 03 Jun, 2018 5 commits
  10. 02 Jun, 2018 1 commit
  11. 01 Jun, 2018 3 commits
    • Yuqi's avatar
      Make MariaDB CRC32-lib platform independence (#780) · ee5124d7
      Yuqi authored
      Make mariadb crc32 lib platform independent
      
      It looks strange that someone can make use of 2 crc libraries
      (Power64 or AArch64) at the same time.
      
      The patch sets macros 'CRC32_LIBRARY' to make platform independence as an optional crc32 library.
      
      Change-Id: I68bbf73cafb6a12f7fb105ad57d117b114a8c4af
      Signed-off-by: default avatarYuqi Gu <yuqi.gu@arm.com>
      ee5124d7
    • gvtek's avatar
      Better Link Spacing · 40dc1a68
      gvtek authored
      Just spacing out the links on separate linkes, they were running together
      in a block of text and could be a little hard for some people to
      differentiate where one begins and the next ends. Seems silly, but just
      trying to help in the formatting a bit.
      40dc1a68
    • Igor Babaev's avatar
      MDEV-16353 Server crash on query with CTE · b2f86ebd
      Igor Babaev authored
      This bug caused crashes for queries with unreferenced non-recursive
      CTEs specified by unions.It happened because the function
      st_select_lex_unit::prepare() tried to use the value of the field 'derived'
      that could not be set for unferenced CTEs as there was no derived
      table associated with an unreferenced CTE.
      b2f86ebd
  12. 31 May, 2018 1 commit
    • Marko Mäkelä's avatar
      Follow-up to MDEV-14168: Correct INNOBASE_DEFAULTS · db677cc6
      Marko Mäkelä authored
      INNOBASE_DEFAULTS: Replace ALTER_ADD_COLUMN with the more appropriate
      ALTER_ADD_STORED_BASE_COLUMN. This clean-up causes no change of
      behaviour, because ALGORITHM=INPLACE would be refused for
      ALTER_ADD_STORED_GENERATED_COLUMN, and default values are not computed
      nor substituted for ALTER_ADD_VIRTUAL_COLUMN.
      db677cc6
  13. 30 May, 2018 4 commits
    • Vladislav Vaintroub's avatar
      MDEV-16345 : No upgrade wizard in 10.3 in Windows packages. · 5a61fa98
      Vladislav Vaintroub authored
      Disable /permissive- flag, so MFC  is found, and upgrade_wizard is built.
      
      MFC code is not standard C++, so it doesn not play well with /permissive-
      5a61fa98
    • Marko Mäkelä's avatar
      MDEV-16334 Incorrect ALTER TABLE for changing column option · 682e7b8f
      Marko Mäkelä authored
      commit 2dbeebdb accidentally changed
      ALTER_COLUMN_OPTION and ALTER_COLUMN_STORAGE_TYPE to be separate flags.
      InnoDB and Mroonga are only checking for the latter;
      the example storage engine is checking for the former only.
      
      The impact of this bug should be incorrect operation of Mroonga when
      the column options GROONGA_TYPE, FLAGS are changed.
      
      InnoDB does not define any column options, only table options,
      so the flag ALTER_COLUMN_OPTION should never have been set.
      
      Also, remove the unused flag ALTER_DROP_HISTORICAL.
      682e7b8f
    • Marko Mäkelä's avatar
      Remove an unnecessary #include · a31e99a8
      Marko Mäkelä authored
      a31e99a8
    • Marko Mäkelä's avatar
      After-merge fixes · c0f97710
      Marko Mäkelä authored
      Fix type mismatches in the unit test mdev10259().
      
      btr_search_info_get_ref_count(): Do not return early if !table->space.
      We can simply access table->space_id even after the tablespace has
      been discarded.
      
      btr_get_search_latch(): Relax a debug assertion to allow
      !index->table->space.
      c0f97710
  14. 29 May, 2018 5 commits