An error occurred fetching the project authors.
  1. 25 Jun, 2023 1 commit
  2. 20 Apr, 2023 2 commits
  3. 30 Jan, 2023 1 commit
  4. 01 Jul, 2022 1 commit
  5. 15 Jul, 2021 1 commit
    • Dmitry Shulga's avatar
      MDEV-26142: Fix failures of the tests main.features and... · 429382c2
      Dmitry Shulga authored
      MDEV-26142: Fix failures of the tests main.features and sys_vars.stored_program_cache_func when they are run in PS mode
      
      These tests produced different results in case they were run
      with the option --ps-protocol.
      
      These tests produced different result sets since a value of
      Feature_subquery and handler_read_key status system variables
      are updated one time more for ps-protocol (the first time it is updated
      on Prepare phase and the second time on Execute phase of PS protocol)
      So different result sets are expected for both tests. To make tests
      successfully runnable both for case it is run with and without
      the option --ps-protocol the new protocol combination [ps, nm]
      and protocol specific result files have been added.
      
      Moreover, the perl script mysql-test/mariadb-test-run.pl
      has been updated to make the variable opt_ps_protocol visible
      outside perl file containing this variable.
      429382c2
  6. 04 Jul, 2021 1 commit
  7. 14 Jun, 2021 1 commit
    • Rucha Deodhar's avatar
      MDEV-22010: use executables MariaDB named in scripts · 193bfdd8
      Rucha Deodhar authored
      As a part of this MDEV following changes were made:
      1) Mariadb named executables used instead of mysql named executables in scripts
      2) renamed mysql-test-run and mysql-stress-test to mariadb-test-run and
      mariadb-stress-test and created a symlink.
      193bfdd8
  8. 09 Jun, 2021 1 commit
    • Anel Husakovic's avatar
      MDEV-25857: MTR should report at least last test that was executed in case of... · 29e8c154
      Anel Husakovic authored
      MDEV-25857: MTR should report at least last test that was executed in case of shutdown and not-completed
      
      - Report the test name in case not all tests are completed and server
      closed the connection
      - Rerport the failure of the last test with the server log in case of
      server shutdown.
      - Ignore stackdump files (obtained on Windows).
      
      Reviewed by: wlad@mariadb.com
      29e8c154
  9. 24 May, 2021 1 commit
  10. 20 May, 2021 1 commit
  11. 19 May, 2021 2 commits
    • Monty's avatar
      Made --mariadbd a synonym for --mysqld in mysql-test-run · aa1626d1
      Monty authored
      - mariadbd and mariadbd-env added
      - Changed output of print_global_resfile to use mariadbd instead of mysqld
      aa1626d1
    • Monty's avatar
      MDEV-23842 Atomic RENAME TABLE · 47010ccf
      Monty authored
      - Major rewrite of ddl_log.cc and ddl_log.h
        - ddl_log.cc described in the beginning how the recovery works.
        - ddl_log.log has unique signature and is dynamic. It's easy to
          add more information to the header and other ddl blocks while still
          being able to execute old ddl entries.
        - IO_SIZE for ddl blocks is now dynamic. Can be changed without affecting
          recovery of old logs.
        - Code is more modular and is now usable outside of partition handling.
        - Renamed log file to dll_recovery.log and added option --log-ddl-recovery
          to allow one to specify the path & filename.
      - Added ddl_log_entry_phase[], number of phases for each DDL action,
        which allowed me to greatly simply set_global_from_ddl_log_entry()
      - Changed how strings are stored in log entries, which allows us to
        store much more information in a log entry.
      - ddl log is now always created at start and deleted on normal shutdown.
        This simplices things notable.
      - Added probes debug_crash_here() and debug_simulate_error() to simply
        crash testing and allow crash after a given number of times a probe
        is executed. See comments in debug_sync.cc and rename_table.test for
        how this can be used.
      - Reverting failed table and view renames is done trough the ddl log.
        This ensures that the ddl log is tested also outside of recovery.
      - Added helper function 'handler::needs_lower_case_filenames()'
      - Extend binary log with Q_XID events. ddl log handling is using this
        to check if a ddl log entry was logged to the binary log (if yes,
        it will be deleted from the log during ddl_log_close_binlogged_events()
      - If a DDL entry fails 3 time, disable it. This is to ensure that if
        we have a crash in ddl recovery code the server will not get stuck
        in a forever crash-restart-crash loop.
      
      mysqltest.cc changes:
      - --die will now replace $variables with their values
      - $error will contain the error of the last failed statement
      
      storage engine changes:
      - maria_rename() was changed to be more robust against crashes during
        rename.
      47010ccf
  12. 20 Apr, 2021 1 commit
    • Monty's avatar
      Fix all warnings given by UBSAN · 031f1171
      Monty authored
      The easiest way to compile and test the server with UBSAN is to run:
      ./BUILD/compile-pentium64-ubsan
      and then run mysql-test-run.
      After this commit, one should be able to run this without any UBSAN
      warnings. There is still a few compiler warnings that should be fixed
      at some point, but these do not expose any real bugs.
      
      The 'special' cases where we disable, suppress or circumvent UBSAN are:
      - ref10 source (as here we intentionally do some shifts that UBSAN
        complains about.
      - x86 version of optimized int#korr() methods. UBSAN do not like unaligned
        memory access of integers.  Fixed by using byte_order_generic.h when
        compiling with UBSAN
      - We use smaller thread stack with ASAN and UBSAN, which forced me to
        disable a few tests that prints the thread stack size.
      - Verifying class types does not work for shared libraries. I added
        suppression in mysql-test-run.pl for this case.
      - Added '#ifdef WITH_UBSAN' when using integer arithmetic where it is
        safe to have overflows (two cases, in item_func.cc).
      
      Things fixed:
      - Don't left shift signed values
        (byte_order_generic.h, mysqltest.c, item_sum.cc and many more)
      - Don't assign not non existing values to enum variables.
      - Ensure that bool and enum values are properly initialized in
        constructors.  This was needed as UBSAN checks that these types has
        correct values when one copies an object.
        (gcalc_tools.h, ha_partition.cc, item_sum.cc, partition_element.h ...)
      - Ensure we do not called handler functions on unallocated objects or
        deleted objects.
        (events.cc, sql_acl.cc).
      - Fixed bugs in Item_sp::Item_sp() where we did not call constructor
        on Query_arena object.
      - Fixed several cast of objects to an incompatible class!
        (Item.cc, Item_buff.cc, item_timefunc.cc, opt_subselect.cc, sql_acl.cc,
         sql_select.cc ...)
      - Ensure we do not do integer arithmetic that causes over or underflows.
        This includes also ++ and -- of integers.
        (Item_func.cc, Item_strfunc.cc, item_timefunc.cc, sql_base.cc ...)
      - Added JSON_VALUE_UNITIALIZED to json_value_types and ensure that
        value_type is initialized to this instead of to -1, which is not a valid
        enum value for json_value_types.
      - Ensure we do not call memcpy() when second argument could be null.
      - Fixed that Item_func_str::make_empty_result() creates an empty string
        instead of a null string (safer as it ensures we do not do arithmetic
        on null strings).
      
      Other things:
      
      - Changed struct st_position to an OBJECT and added an initialization
        function to it to ensure that we do not copy or use uninitialized
        members. The change to a class was also motived that we used "struct
        st_position" and POSITION randomly trough the code which was
        confusing.
      - Notably big rewrite in sql_acl.cc to avoid using deleted objects.
      - Changed in sql_partition to use '^' instead of '-'. This is safe as
        the operator is either 0 or 0x8000000000000000ULL.
      - Added check for select_nr < INT_MAX in JOIN::build_explain() to
        avoid bug when get_select() could return NULL.
      - Reordered elements in POSITION for better alignment.
      - Changed sql_test.cc::print_plan() to use pointers instead of objects.
      - Fixed bug in find_set() where could could execute '1 << -1'.
      - Added variable have_sanitizer, used by mtr.  (This variable was before
        only in 10.5 and up).  It can now have one of two values:
        ASAN or UBSAN.
      - Moved ~Archive_share() from ha_archive.cc to ha_archive.h and marked
        it virtual. This was an effort to get UBSAN to work with loaded storage
        engines. I kept the change as the new place is better.
      - Added in CONNECT engine COLBLK::SetName(), to get around a wrong cast
        in tabutil.cpp.
      - Added HAVE_REPLICATION around usage of rgi_slave, to get embedded
        server to compile with UBSAN. (Patch from Marko).
      - Added #ifdef for powerpc64 to avoid a bug in old gcc versions related
        to integer arithmetic.
      
      Changes that should not be needed but had to be done to suppress warnings
      from UBSAN:
      
      - Added static_cast<<uint16_t>> around shift to get rid of a LOT of
        compiler warnings when using UBSAN.
      - Had to change some '/' of 2 base integers to shift to get rid of
        some compile time warnings.
      
      Reviewed by:
      - Json changes: Alexey Botchkov
      - Charset changes in ctype-uca.c: Alexander Barkov
      - InnoDB changes & Embedded server: Marko Mäkelä
      - sql_acl.cc changes: Vicențiu Ciorbaru
      - build_explain() changes: Sergey Petrunia
      031f1171
  13. 12 Apr, 2021 1 commit
  14. 18 Mar, 2021 2 commits
  15. 15 Mar, 2021 1 commit
    • Marko Mäkelä's avatar
      MDEV-24883 add io_uring support for tpool · 783625d7
      Marko Mäkelä authored
      liburing is a new optional dependency (WITH_URING=auto|yes|no)
      that replaces libaio when it is available.
      
      aio_uring: class which wraps io_uring stuff
      
      aio_uring::bind()/unbind(): optional optimization
      
      aio_uring::submit_io(): mutex prevents data race. liburing calls are
      thread-unsafe. But if you look into it's implementation you'll see
      atomic operations. They're used for synchronization between kernel and
      user-space only. That's why our own synchronization is still needed.
      
      For systemd, we add LimitMEMLOCK=524288 (ulimit -l 524288)
      because the io_uring_setup system call that is invoked
      by io_uring_queue_init() requests locked memory. The value
      was found empirically; with 262144, we would occasionally
      fail to enable io_uring when using the maximum values of
      innodb_read_io_threads=64 and innodb_write_io_threads=64.
      
      aio_uring::thread_routine(): Tolerate -EINTR return from
      io_uring_wait_cqe(), because it may occur on shutdown
      on Ubuntu 20.10 (Groovy Gorilla).
      
      This was mostly implemented by Eugene Kosov. Systemd integration
      and improved startup/shutdown error handling by Marko Mäkelä.
      783625d7
  16. 01 Mar, 2021 1 commit
    • Sergei Golubchik's avatar
      mtr --gdb: fix for --rr and for a warning · dd9e5827
      Sergei Golubchik authored
      use _RR_TRACE_DIR=dir instead of -o dir, as the former can store
      multiple traces in dir (if, e.g., the test restarts mysqld)
      
      suppress uninitialized warning when $exe is undefined (--manual-XXX)
      dd9e5827
  17. 22 Feb, 2021 2 commits
    • Sergei Golubchik's avatar
      unify mtr handling of debuggers · feacc0aa
      Sergei Golubchik authored
      "debugger" is anything that wraps execution of a target
      binary (mysqld or mysqltest). Currently the list includes:
      gdb, ddd, dbx, lldb, valgrind, strace, ktrace, rr,
      devenv, windbg, vsjitdebugger.
      
      for every debugger xxx, mtr will recognize four options:
      --xxx, --boot-xxx, --manual-xxx, --client-xxx.
      They all support an optional "=string" argument. String
      being a semicolon-separated list of commands (e.g. for gdb)
      or one (not semicolon-separated) command line of options
      (e.g. for valgrind). Or both (e.g. --gdb='-quiet -nh;info files'
      
      In embedded both --xxx and --client-xxx work.
      
      Functionality changed/removed:
      * --rr-args is gone
      * --rr-dir is gone
      * --manual-debug is gone
      * --debugger={devenv|vc|windbg|vc_express|vsjitdebugger} is gone
      * --strace-option is gone
      * --stracer={strace|ktrace} is gone
      * --valgrind only enables it for the server, not for everything
      * --valgrind-all is gone
      * --valgrind-mysqltest is gone
      * --valgrind-mysqld is gone
      * --valgrind-options is gone
      * --valgrind-option is gone
      * --valgrind-path is gone
      * --callgrind is gone
      * one cannot combine --valgrind --gdb anymore
      * valgrind report doesn't add a fake test line to the output
      * vc and vcexpress on windows are no longer supported
      feacc0aa
    • Sergei Golubchik's avatar
      cleanup: remove dead code in mtr · 3b0b4e61
      Sergei Golubchik authored
      3b0b4e61
  18. 24 Jan, 2021 1 commit
  19. 07 Dec, 2020 1 commit
    • Anel Husakovic's avatar
      MDEV-24177 && MDEV-24178 · a82209ca
      Anel Husakovic authored
      - MDEV-24177: main.sp2 test fails: Result length mismatch
      - MDEV-24178: main.upgrade_MDEV-19650 test fails: Result length mismatch
      
      Reviewed by: serg@mariadb.com
      a82209ca
  20. 10 Nov, 2020 1 commit
    • Anel Husakovic's avatar
      MDEV-23769: MTR can abort before it prints the test result summary · cd927dd3
      Anel Husakovic authored
      - Patch is solving generating report on warning
              To repeat the error run single worker:
              ```
              ./mtr --mysqld=--lock-wait-timeout=-xx 1st 1st --force --parallel 1
              ```
              or `N` workers with `N+1` tests with failures and `force`
              ```
              ./mtr --mysqld=--lock-wait-timeout=-xx 1st 1st grant5 --force --parallel 2
              ```
      - Patch is doing cosmetic fix of `current_test` log file which holds the old log value of test `CURRENT TEST:..` in `mark_log()` in case of `unknown option` and as such
        the logic which is using it's content doesn't output valid log content and doesn't generate valid `$test->{'comment'}` message.asdf
      
      - Closing the socket/handler after the removing the handler from IO for
      consistency
      
      Reviewed by: serg@mariadb.com
      cd927dd3
  21. 21 Oct, 2020 1 commit
  22. 20 Oct, 2020 2 commits
    • Anel Husakovic's avatar
      Update mtr help · d1af93a5
      Anel Husakovic authored
      - Based on patch: d6a983351c5a454bd0cb113852f
      - Update combination example for 10.2 (commit 2a3fe45d added change
      for 10.3+)
      ```
      ==============================================================================
      
      TEST                                      RESULT   TIME (ms) or COMMENT
      --------------------------------------------------------------------------
      
      worker[1] Using MTR_BUILD_THREAD 300, with reserved ports 16000..16019
      rpl.rpl_invoked_features 'innodb,mix'    [ pass ]   1677
      rpl.rpl_invoked_features 'innodb,row'    [ pass ]   3516
      rpl.rpl_invoked_features 'innodb,stmt'   [ pass ]   1609
      --------------------------------------------------------------------------
      ```
      - `gdb` option will be added during the merge
      d1af93a5
    • Anel Husakovic's avatar
      Updated mtr help · 0627c4ae
      Anel Husakovic authored
      - Updated combination example to use `innodb_plugin`
      ```
      $ ./mysql-test/mtr rpl.rpl_invoked_features # no rpl.rpl_invoked_features,mix,xtradb_plugin
      
      worker[1] Using MTR_BUILD_THREAD 300, with reserved ports 16000..16019
      rpl.rpl_invoked_features 'innodb_plugin,mix' [ pass ]    904
      rpl.rpl_invoked_features 'mix,xtradb'    [ pass ]   1707
      rpl.rpl_invoked_features 'innodb_plugin,row' [ pass ]    927
      rpl.rpl_invoked_features 'row,xtradb'    [ pass ]    828
      rpl.rpl_invoked_features 'innodb_plugin,stmt' [ pass ]    855
      rpl.rpl_invoked_features 'stmt,xtradb'   [ pass ]    952
      --------------------------------------------------------------------------
      ```
      - `gdb` option can take optional gdb arguments (good documentation in
      KB)
      0627c4ae
  23. 06 Oct, 2020 1 commit
    • Aleksey Midenkov's avatar
      MDEV-23787 mtr --rr fixes · 2b832151
      Aleksey Midenkov authored
      1. rr record -h randomizes number of processors. Disable THREAD_POOL_SIZE check.
      
      2. check for kernel.perf_event_paranoid for user-friendly error message.
      2b832151
  24. 23 Sep, 2020 1 commit
  25. 01 Aug, 2020 1 commit
    • Alexander Barkov's avatar
      MDEV-19632 Replication aborts with ER_SLAVE_CONVERSION_FAILED upon CREATE ... SELECT in ORACLE mode · d63631c3
      Alexander Barkov authored
      - Adding optional qualifiers to data types:
          CREATE TABLE t1 (a schema.DATE);
        Qualifiers now work only for three pre-defined schemas:
      
          mariadb_schema
          oracle_schema
          maxdb_schema
      
        These schemas are virtual (hard-coded) for now, but may turn into real
        databases on disk in the future.
      
      - mariadb_schema.TYPE now always resolves to a true MariaDB data
        type TYPE without sql_mode specific translations.
      
      - oracle_schema.DATE translates to MariaDB DATETIME.
      
      - maxdb_schema.TIMESTAMP translates to MariaDB DATETIME.
      
      - Fixing SHOW CREATE TABLE to use a qualifier for a data type TYPE
        if the current sql_mode translates TYPE to something else.
      
      The above changes fix the reported problem, so this script:
      
          SET sql_mode=ORACLE;
          CREATE TABLE t2 AS SELECT mariadb_date_column FROM t1;
      
      is now replicated as:
      
          SET sql_mode=ORACLE;
          CREATE TABLE t2 (mariadb_date_column mariadb_schema.DATE);
      
      and the slave can unambiguously treat DATE as the true MariaDB DATE
      without ORACLE specific translation to DATETIME.
      
      Similar,
      
          SET sql_mode=MAXDB;
          CREATE TABLE t2 AS SELECT mariadb_timestamp_column FROM t1;
      
      is now replicated as:
      
          SET sql_mode=MAXDB;
          CREATE TABLE t2 (mariadb_timestamp_column mariadb_schema.TIMESTAMP);
      
      so the slave treats TIMESTAMP as the true MariaDB TIMESTAMP
      without MAXDB specific translation to DATETIME.
      d63631c3
  26. 27 Jul, 2020 3 commits
  27. 24 Jun, 2020 1 commit
  28. 23 Jun, 2020 1 commit
    • Daniel Black's avatar
      mtr: use env for perl · 37c88445
      Daniel Black authored
      On FreeBSD, perl isn't in /usr/bin, its in /usr/local/bin or
      elsewhere in the path.
      
      Like storage/{maria/unittest/,}ma_test_* , we use /usr/bin/env to
      find perl and run it.
      37c88445
  29. 22 Jun, 2020 2 commits
    • Aleksey Midenkov's avatar
      MDEV-22179 rr support for mtr review · 009ef36d
      Aleksey Midenkov authored
      * --rr-arg instead of --rr_option
      * Bootstrap saved to rr.bootstrap
      * Replication slaves are saved to rr.N dirs
      * Perl coding fixes
      009ef36d
    • Sachin's avatar
      MDEV-22179 rr(record and replay) support for mtr · 804ed12e
      Sachin authored
      This feature adds the support for rr in mtr. These 2 options are added
      --rr         run   the mysqld in rr record mode
      --rr_option= run the rr with custom record option, for multiple
                   options use --rr_option= for each option.
                   For example
                    ./mtr main.view --rr_option=-h --rr_option=-u --rr_option=-c=23
      --boot-rr    run the mysqld performing bootstrap in rr record mode
      
      Recording are stored in mysql-test/var/rr folder.
      To run recording please run
      rr replay var/rr/mysql-X
      
      Limitations
      Restart will create a new recording.
      Repeat will work on same recording , So might be harder to debug.
      If test create the multiple instance of mariadb all will be stored in var/rr
      804ed12e
  30. 04 Jun, 2020 1 commit
  31. 27 May, 2020 1 commit
  32. 19 May, 2020 1 commit