View Bazaar branches
Get this repository:
git clone https://git.launchpad.net/maria

MariaDB has 18 active reviews.

Branches

Name Last Modified Last Commit
bb-10.2-serg 2020-10-19 19:13:36 UTC 6 hours ago
MDEV-17408 VIEW is incorrectly defined for a combination of = and BETWEEN

Author: Sergei Golubchik
Author Date: 2020-10-19 10:57:44 UTC

MDEV-17408 VIEW is incorrectly defined for a combination of = and BETWEEN

bb-10.1-andrei 2020-10-19 18:58:22 UTC 6 hours ago
Temp commit after log.o and handler.o

Author: Andrei Elkin
Author Date: 2020-10-19 18:58:22 UTC

Temp commit after log.o and handler.o

10.2 2020-10-19 17:36:05 UTC 7 hours ago
MDEV-23982: Mariabackup hangs on backup

Author: Marko Mäkelä
Author Date: 2020-10-19 17:36:05 UTC

MDEV-23982: Mariabackup hangs on backup

MDEV-13318 introduced a condition to Mariabackup that can cause it to
hang if the server goes idle after writing a log block that has no
payload after the 12-byte header. Normal recovery in log0recv.cc would
allow blocks with exactly 12 bytes of length, and only reject blocks
where the length field is shorter than that.

bb-10.3-MDEV-23072 2020-10-19 16:48:29 UTC 8 hours ago
MDEV-23072 Diskspace not reused for Blob in data file

Author: THIRUNARAYANAN BALATHANDAYUTHAPANI
Author Date: 2020-10-15 07:56:18 UTC

MDEV-23072 Diskspace not reused for Blob in data file

- This issue is caused by commit a4948dafcd7eee65f16d848bdc6562fc49ef8916.
Purge doesn't free the externally stored page associated with the
last record of the root page. In that case, purge thread does empty
the root page and leads to more orphaned blob page in the tablespace.
Purge thread should free the blob even for the last record of the
root page.

Reviewed-by: Marko Mäkelä

bb-10.4-midenok 2020-10-19 16:21:43 UTC 8 hours ago
MDEV-23672 Assertion `v.v_indexes.empty()' failed in dict_table_t::instant_co...

Author: midenok
Author Date: 2020-10-19 16:21:43 UTC

MDEV-23672 Assertion `v.v_indexes.empty()' failed in dict_table_t::instant_column

dict_v_idx_t node was shared between two dict_v_col_t objects because
of wrong object copy. Replace memory plain copy with copy constructor.

Tha patch also removes n_v_indexes property and improves "page full"
judgements for trx_undo_log_v_idx().

bb-10.5-MDEV-23855 2020-10-19 15:08:53 UTC 10 hours ago
MDEV-23855: Flush also below innodb_adaptive_flushing_lwm

Author: Marko Mäkelä
Author Date: 2020-10-19 15:08:53 UTC

MDEV-23855: Flush also below innodb_adaptive_flushing_lwm

If innodb_adaptive_flushing=ON and we are below
innodb_adaptive_flushing_lwm, let us flush pages
according to the return value of af_get_pct_for_dirty().

bb-10.5-monty 2020-10-19 14:04:45 UTC 11 hours ago
Fixed compiler warning in connect/filemazip.cpp

Author: Monty
Author Date: 2020-10-16 12:45:50 UTC

Fixed compiler warning in connect/filemazip.cpp

10.5 2020-10-19 12:51:52 UTC 12 hours ago
MDEV-19275 Provide SQL service to plugins.

Author: Alexey Botchkov
Author Date: 2020-10-19 12:51:52 UTC

MDEV-19275 Provide SQL service to plugins.

Debian scripts fixed.

bb-10.2-MDEV-21951 2020-10-19 12:22:53 UTC 12 hours ago
MDEV-21951: mariabackup SST fail if data-directory have lost+found directory

Author: Julius Goryavsky
Author Date: 2020-03-24 13:55:07 UTC

MDEV-21951: mariabackup SST fail if data-directory have lost+found directory

To fix this, it is necessary to add an option to exclude the
database with the name "lost+found" from processing (the database
name will be checked by the check_if_skip_database_by_path() or
by the check_if_skip_database() function, and as a result
"lost+found" will be skipped).

In addition, it is necessary to slightly modify the verification
logic in the check_if_skip_database() function.

Also added a new test galera_sst_mariabackup_lost_found.test

bb-10.2-danielblack-MDEV-23326-timezone-initialization-slow-on-aria 2020-10-19 06:27:55 UTC 18 hours ago
MDEV-23495: mysql_install_db can run from srcdir

Author: Daniel Black
Author Date: 2020-08-18 02:09:11 UTC

MDEV-23495: mysql_install_db can run from srcdir

Backport part of 47334649752e109360c9e22b8f8019a0df51fe93

mysql_install_db will now automatically detect if run from srcdir

10.2-mdev23867 2020-10-19 06:21:40 UTC 18 hours ago
MDEV-23867: insert... select crash in compute_window_func

Author: varun
Author Date: 2020-10-16 08:05:24 UTC

MDEV-23867: insert... select crash in compute_window_func

There are 2 issues here:

Issue #1: memory allocation.
An IO_CACHE that uses encryption uses a larger buffer (it needs space for the encrypted data,
decrypted data, IO_CACHE_CRYPT struct to describe encryption parameters etc).

Issue #2: IO_CACHE::seek_not_done
When IO_CACHE objects are cloned, they still share the file descriptor.
This means, operation on one IO_CACHE may change the file read position
which will confuse other IO_CACHEs using it.

The fix of these issues would be:
Allocate the buffer to also include the extra size needed for encryption.
Use pread instead as it does not change the file offset.

bb-10.3-midenok 2020-10-18 16:54:39 UTC 2020-10-18
MDEV-23968 CREATE TEMPORARY TABLE .. LIKE (system versioned table) returns er...

Author: midenok
Author Date: 2020-10-18 11:26:41 UTC

MDEV-23968 CREATE TEMPORARY TABLE .. LIKE (system versioned table) returns error if unique index is defined in the table

- Remove row_start/row_end from keys in fix_create_like();

- Disable manual adding of implicit row_start/row_end to indexes on
  CREATE TABLE. INVISIBLE_SYSTEM fields are unoperable by user;

- Fix memory leak on allocation of Key_part_spec.

bb-10.6-monty 2020-10-18 13:36:39 UTC 2020-10-18
MDEV-23842 Atomic RENAME TABLE

Author: Monty
Author Date: 2020-10-14 23:25:57 UTC

MDEV-23842 Atomic RENAME TABLE

Not complete, missing:
- Test cases for the new code using debug_crash_here()

bb-10.5-anel-MDEV-22552 2020-10-17 17:12:36 UTC 2020-10-17
MDEV-22552: mytop packaging

Author: Anel Husakovic
Author Date: 2020-10-13 12:36:25 UTC

MDEV-22552: mytop packaging

- Adding socket check for MariaDB/Mysql driver
- Don't use `COMPONENT client` for RPM based on 0d05c9f8699d1ac5
Reviewed by: Sergei Golubchik

bb-10.3-anel-MDEV-21786-dump-sequence-v3 2020-10-17 17:08:54 UTC 2020-10-17
MDEV-21786 mysqldump will forget sequence definition details on --no-data dump

Author: Anel Husakovic
Author Date: 2020-08-31 14:36:32 UTC

MDEV-21786 mysqldump will forget sequence definition details on --no-data dump

- Original patch was contributed by Jani Tolonen <jani.k.tolonen@gmail.com>
https://github.com/an3l/server/commits/bb-10.3-anel-MDEV-21786-dump-sequence
which distinguishes data structure (linked list) of sequences from
tables.
- According to MDEV? added standard sql output to prevent future changes
of sequences and disabled locks for sequences
- Added test case for `MDEV-20070: mysqldump won't work correct on
sequences` where table column depends on sequence value @tbd.

bb-10.2-anel-mtrhelp 2020-10-17 12:37:24 UTC 2020-10-17
Update mtr help

Author: Anel Husakovic
Author Date: 2020-10-17 12:33:04 UTC

Update mtr help

- Based on patch: d6a983351c5a454bd0cb113852f
- Update combination example for 10.2 (commit 2a3fe45dd2df 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

bb-10.1-anel-mtrhelp 2020-10-17 12:18:59 UTC 2020-10-17
Updated mtr help

Author: Anel Husakovic
Author Date: 2020-10-17 12:18:54 UTC

Updated mtr help

- 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)

bb-10.3-mdev21265 2020-10-17 01:31:07 UTC 2020-10-17
MDEV-21265: IN predicate conversion to IN subquery should be allowed for a br...

Author: varun
Author Date: 2020-10-16 06:13:56 UTC

MDEV-21265: IN predicate conversion to IN subquery should be allowed for a broader set of datatype comparison

Allow materialization strategy when collations on the
inner and outer sides of an IN subquery are the same and the
character set of the inner side is a proper subset of the character
set on the outer side.
This allows conversion from utf8mb3 to utf8mb4
as the former is a subset of the later.

Reviewed by Sergei Petrunia

10.3 2020-10-16 16:48:36 UTC 2020-10-16
MDEV-23248 Server crashes in mi_extra / ha_partition::loop_extra_alter upon R...

Author: Monty
Author Date: 2020-10-16 12:36:12 UTC

MDEV-23248 Server crashes in mi_extra / ha_partition::loop_extra_alter upon REORGANIZE

This also fixes some issues with
MDEV-23730 s3.replication_partition 'innodb,mix' segv

The problem was that mysql_change_partitions() closes all handler files
in case of error, which was not properly reflected in
fast_alter_partition_table(). This caused handle_alter_part_error() to
try to close already closed tables, which caused the crash.

Fixed fast_alter_partion_table() to reflect when tables are opened.
I also fixed that ha_partition::change_partitions() resets m_new_file in
case of errors.
Either of the above changes fixes the issue, but both are needed to ensure
that the code works as expected.

bb-10.5-drrtuy 2020-10-16 15:41:54 UTC 2020-10-16
Update the MCS engine ref

Author: Roman Nozdrin
Author Date: 2020-10-16 15:41:54 UTC

Update the MCS engine ref

10.5-drrtuy 2020-10-16 15:41:54 UTC 2020-10-16
Update the MCS engine ref

Author: Roman Nozdrin
Author Date: 2020-10-16 15:41:54 UTC

Update the MCS engine ref

bb-10.5-midenok 2020-10-16 15:37:10 UTC 2020-10-16
MDEV-23672 Assertion `v.v_indexes.empty()' failed in dict_table_t::instant_co...

Author: midenok
Author Date: 2020-09-07 18:48:51 UTC

MDEV-23672 Assertion `v.v_indexes.empty()' failed in dict_table_t::instant_column

dict_v_idx_t node was shared between two dict_v_col_t objects because
of wrong object copy. Replace memory plain copy with copy constructor.

Tha patch also removes n_v_indexes property and improves "page full"
judgements for trx_undo_log_v_idx().

bb-10.2-sujatha 2020-10-16 13:53:08 UTC 2020-10-16
MDEV-4633: multi_source.simple test fails sporadically

Author: Sujatha Sivakumar
Author Date: 2020-10-16 11:10:01 UTC

MDEV-4633: multi_source.simple test fails sporadically

Analysis:
========
Writes to 'rli->log_space_total' needs to be synchronized, otherwise both
SQL_THREAD and IO_THREAD can try to modify the variable simultaneously
resulting in incorrect rli->log_space_total. In the current test scenario
SQL_THREAD is trying to decrement 'rli->log_space_total' in 'purge_first_log'
and IO_THREAD is trying to increment the 'rli->log_space_total' in
'queue_event' simultaneously. Hence test occasionally fails with result
mismatch.

Fix:
===
Convert 'rli->log_space_total' variable to atomic type.

bb-10.3-monty 2020-10-16 12:36:12 UTC 2020-10-16
Fixed crash in REORGANIZE partitions

Author: Monty
Author Date: 2020-10-16 12:36:12 UTC

Fixed crash in REORGANIZE partitions

MDEV-23248 Server crashes in mi_extra / ha_partition::loop_extra_alter
          upon REORGANIZE
MDEV-23730 s3.replication_partition 'innodb,mix' segv

The problem was that mysql_change_partitions() closes all handler files
in case of error, which was not properly reflected in
fast_alter_partition_table(). This caused handle_alter_part_error() to
try to close already closed tables, which caused the crash.

Fixed fast_alter_partion_table() to reflect when tables are opened.
I also fixed that ha_partition::change_partitions() resets m_new_file in
case of errors.
Either of the above changes fixes the issue, but both are needed to ensure
that the code works as expected.

bb-10.3-sujatha 2020-10-16 11:14:36 UTC 2020-10-16
MDEV-4633: multi_source.simple test fails sporadically

Author: Sujatha Sivakumar
Author Date: 2020-10-16 11:10:01 UTC

MDEV-4633: multi_source.simple test fails sporadically

Analysis:
========
Writes to 'rli->log_space_total' needs to be synchronized, otherwise both
SQL_THREAD and IO_THREAD can try to modify the variable simultaneously
resulting in incorrect rli->log_space_total. In the current test scenario
SQL_THREAD is trying to decrement 'rli->log_space_total' in 'purge_first_log'
and IO_THREAD is trying to increment the 'rli->log_space_total' in
'queue_event' simultaneously. Hence test occasionally fails with result
mismatch.

Fix:
===
Convert 'rli->log_space_total' variable to atomic type.

bb-10.4-MDEV-22805 2020-10-16 10:12:32 UTC 2020-10-16
MDEV-22805: SIGSEGV in check_fields on UPDATE

Author: Dmitry Shulga
Author Date: 2020-10-16 10:12:32 UTC

MDEV-22805: SIGSEGV in check_fields on UPDATE

For debug build of MariaDB server running of the following test case
will hit the assert `thd->lex->sql_command == SQLCOM_UPDATE' in the function
check_fields() on attempt to execute the UPDATE statement.

  CREATE TABLE t1 (a INT);
  UPDATE t1 FOR PORTION OF APPTIME FROM (SELECT 1 FROM t1) TO 2 SET a = 1;

Stack trace to the fired assert statement
  DBUG_ASSERT(thd->lex->sql_command == SQLCOM_UPDATE)
listed below:
  mysql_execute_command() ->
    mysql_multi_update_prepare() -->
      Multiupdate_prelocking_strategy::handle_end() -->
        check_fiels()

It's worth to note that this stack trace looks like a multi update
statement is being executed. The fired assert is checked inside the
function check_fields() in case table->has_period() returns the value
true that in turns happens when temporal period specified in the UPDATE
statement. Condition specified in the DEBUG_ASSERT statement returns
the false value since the data member thd->lex->sql_command have the
value SQLCOM_UPDATE_MULTI. So, the main question is why a program control
flow go to the path prescribed for handling MULTI update statement
despite of the fact that the ordinary UPDATE statement being executed.

The answer is a way that SQL grammar rules written.

When the statement
  UPDATE t1 FOR PORTION OF APPTIME FROM (SELECT 1 FROM t1) TO 2 SET a = 1;
being parsed an action for the rule 'table_primary_ident' (part of the this
is listed below to simplify description) is invoked to handle the table
name 't1' specified in the clause 'SELECT 1 FROM t1'.

table_primary_ident:
  table_ident opt_use_partition opt_for_system_time_clause
  opt_table_alias_clause opt_key_definition
  {
    SELECT_LEX *sel= Select;
    sel->table_join_options= 0;
    if (!($$= Select->add_table_to_list(thd, $1, $4,

This action calls the method st_select_lex::add_table_to_list()
to add the table name 't1' to the list of tables being used by the statement.

Later, an action for the following grammar rule
update_table_list:
  table_ident opt_use_partition for_portion_of_time_clause
  opt_table_alias_clause opt_key_definition
  {
    SELECT_LEX *sel= Select;
    sel->table_join_options= 0;
    if (!($$= Select->add_table_to_list(thd, $1, $4,

is invoked to handle the clause 't1 FOR PORTION OF APPTIME FROM ... TO 2'.
This action also calls the method st_select_lex::add_table_to_list()
to add the table name 't1' to the list of tables being used by the statement.

In result the table name 't1' contained twice in this list.

Presence of duplicate names for the table 't1' in a list of table used by
a statement leads to the fact that the function unique_table() called
from the function mysql_update() returns the value true that forces
implementation of the function mysql_update() to return the value 2 as
a signal to fall through the case boundary of the switch statement placed
in the function mysql_execute_statement() and start handling of the case
for sql_command SQLCOM_UPDATE_MULTI. The compound statement block for the
case SQLCOM_UPDATE_MULTI invokes the function mysql_multi_update_prepare()
that executes the statement
  set thd->lex->sql_command= SQLCOM_UPDATE_MULTI;
and after that calls the method
  Multiupdate_prelocking_strategy::handle_end(). Finally, this method
invokes the check_field() function and assert is fired.

To fix the bug a table name of subquery specified in the FROM clause
should be added to the list of tables used by a query only after the
data member exclude_from_table_unique_test is set to the true value
for a select_lex that corresponds to the query specified in the FROM
clause. When the data member SELECT::exclude_from_table_unique_test
is set a table associated with this SELECT will be skipped on searching
for a table duplication instance (see implementation of the function
find_dup_table() that is called from the function unique_table()).
In result the function unique_table() will not return the value 2
and program control flow will not switch to the path for MULTI UPDATE
statement.

bb-10.5-nikita 2020-10-16 08:21:23 UTC 2020-10-16
handler: move row change start signal down after the checks

Author: Nikita Malyavin
Author Date: 2020-10-14 05:40:46 UTC

handler: move row change start signal down after the checks

bb-10.2-mdev23867 2020-10-16 08:13:47 UTC 2020-10-16
MDEV-23867: insert... select crash in compute_window_func

Author: varun
Author Date: 2020-10-16 08:05:24 UTC

MDEV-23867: insert... select crash in compute_window_func

There are 2 issues here:

Issue #1: memory allocation.
An IO_CACHE that uses encryption uses a larger buffer (it needs space for the encrypted data,
decrypted data, IO_CACHE_CRYPT struct to describe encryption parameters etc).

Issue #2: IO_CACHE::seek_not_done
When IO_CACHE objects are cloned, they still share the file descriptor.
This means, operation on one IO_CACHE may change the file read position which will confuse other IO_CACHEs using it.

The fix of these issues would be:
Allocate the buffer to also include the extra size needed for encryption.
Use pread instead as it does not change the file offset.

bb-10.2-MDEV-23387 2020-10-16 06:40:50 UTC 2020-10-16
MDEV-23966 btr_search_sys->hash_tables accessed without taking proper ahi latch

Author: THIRUNARAYANAN BALATHANDAYUTHAPANI
Author Date: 2020-10-16 06:39:41 UTC

MDEV-23966 btr_search_sys->hash_tables accessed without taking proper ahi latch

In btr_search_update_hash_on_insert(), btr_search_sys->hash_tables is
being accessed without taking proper ahi latch. During buffer pool
resizing, btr_get_search_table() is being accessed and it leads to
segmentation fault. Taking ahi lock before btr_search_sys->hash_tables.

10.1 2020-10-15 22:44:03 UTC 2020-10-15
MDEV-23938: innodb row_search_idx_cond_check handle ICP_ABORTED_BY_USER

Author: Sergey Petrunia
Author Date: 2020-10-09 14:48:22 UTC

MDEV-23938: innodb row_search_idx_cond_check handle ICP_ABORTED_BY_USER

- row_search_mvcc() should return DB_INTERRUPTED when it got killed.
- Add a syncpoint for the ICP check.
- Add test coverage for killed-during-ICP-check scenario

Backport of MDEV-22761 fixes for ICP from 10.4 commits:
* a6f956488c712bef3b13660584d1b905e0c676cc
* c03885cd9ceb1ede7f49a9e218022b401b3a1e28

XtraDB was fixed in deb3b9a17498

Reviewer: Daniel Black

bb-10.5-release 2020-10-15 15:33:41 UTC 2020-10-15
MDEV-23855: Tweak the checkpoint margins

Author: Marko Mäkelä
Author Date: 2020-10-15 14:28:36 UTC

MDEV-23855: Tweak the checkpoint margins

We used to start an asynchronous flush upon exceeding
7/8 of the hard limit for checkpoint, and a checkpoint
upon exceeding 31/32 of the limit.

Let us change these limits to 25/32 and 7/8, so that
there will be some more headroom before we will have
to halt all writers upon reaching the hard limit.

bb-10.4-danielblack-MDEV-19508-unix-sighup-origin 2020-10-15 07:44:02 UTC 2020-10-15
MDEV-19508: signal handler SI_KERNEL not defined on Solaris/AIX

Author: Daniel Black
Author Date: 2019-09-26 22:48:27 UTC

MDEV-19508: signal handler SI_KERNEL not defined on Solaris/AIX

Solaris and AIX doesn't have a SI_KERNEL code for its siginfo code
structure. But they define sigwaitinfo. For these we can use
SI_USER and values <= aren't kernel.

SI_USER is defined on AIX (since AIX 6.1 at least) as:
/usr/include/sys/signal.h
    #define SI_USER 0 /* signal sent by another process with kill */

So its effectively not kernel.

Linux also uses SI_USER as its highest user code.

FreeBSD-12.1 available defines are:

  #if __POSIX_VISIBLE || __XSI_VISIBLE
  #define SI_NOINFO 0 /* No signal info besides si_signo. */
  #define SI_USER 0x10001 /* Signal sent by kill(). */
  #define SI_QUEUE 0x10002 /* Signal sent by the sigqueue(). */
  #define SI_TIMER 0x10003 /* Signal generated by expiration of */
                                          /* a timer set by timer_settime(). */
  #define SI_ASYNCIO 0x10004 /* Signal generated by completion of */
                                          /* an asynchronous I/O request.*/
  #define SI_MESGQ 0x10005 /* Signal generated by arrival of a */
                                          /* message on an empty message queue. */
  #define SI_KERNEL 0x10006
  #define SI_LWP 0x10007 /* Signal sent by thr_kill */
  #endif

Original commit 07e9b1389857 showed an explicit desire to catch user
signals aka kill(SI_USER). So for FreeBSD != SI_KERNEL is too broad and
should be <= SI_USER too.

ref: https://docs.oracle.com/cd/E36784_01/html/E36873/siginfo.h-3head.html
ref: https://github.com/omniosorg/illumos-omnios/blob/master/usr/src/uts/common/sys/siginfo.h#L130

bb-10.4-svoj 2020-10-15 07:42:31 UTC 2020-10-15
MDEV-19508 - Issue with: #define SI_KERNEL

Author: Sergey Vojtovich
Author Date: 2020-04-28 10:25:42 UTC

MDEV-19508 - Issue with: #define SI_KERNEL

Reverted 07e9b1389, use setsid() instead.

Conventional use of SIGHUP to dump daemon information or flush caches
assumes preceeding setsid() call.

Ideally we should not setup SIGHUP handler in bootstrap and (probably)
debug_gdb modes.

Additional information on SysV style and systemd style daemons:
https://www.freedesktop.org/software/systemd/man/daemon.html

10.6 2020-10-15 03:00:20 UTC 2020-10-15
MDEV-22596: DELETE FOR PORTION does not obey "Expression in FOR PORTION OF mu...

Author: Nayuta Yanagisawa
Author Date: 2020-10-11 12:26:38 UTC

MDEV-22596: DELETE FOR PORTION does not obey "Expression in FOR PORTION OF must be constant" limitation, data can be easily lost

DELETE...FOR PORTION OF... statement accepts non-constant
FROM...TO clause. This contradicts the documentation and
is inconsistent with the behavior of UPDATE statement.
Thus, we add a validation that checks if a given deletion
period is specified by constant.

bb-10.1-danielblack-MDEV-23938-innodb-aborted-by-user 2020-10-15 00:06:40 UTC 2020-10-15
MDEV-23938: innodb row_search_idx_cond_check handle ICP_ABORTED_BY_USER

Author: Sergey Petrunia
Author Date: 2020-10-09 14:48:22 UTC

MDEV-23938: innodb row_search_idx_cond_check handle ICP_ABORTED_BY_USER

- row_search_mvcc() should return DB_INTERRUPTED when it got killed.
- Add a syncpoint for the ICP check.
- Add test coverage for killed-during-ICP-check scenario

Backport of MDEV-22761 fixes for ICP from 10.4 commits:
* a6f956488c712bef3b13660584d1b905e0c676cc
* c03885cd9ceb1ede7f49a9e218022b401b3a1e28

XtraDB was fixed in deb3b9a17498

Reviewer: Daniel Black

bb-10.2-galera 2020-10-14 23:12:25 UTC 2020-10-14
MDEV-23659: Update Galera disabled.def file

Author: Julius Goryavsky
Author Date: 2020-10-13 11:37:33 UTC

MDEV-23659: Update Galera disabled.def file

This fix removes from the list of disabled tests all
tests that were fixed by the patch for MDEV-21770.

bb-10.2-MDEV-21770 2020-10-14 23:10:04 UTC 2020-10-14
MDEV-23659: Update Galera disabled.def file

Author: Julius Goryavsky
Author Date: 2020-10-13 11:37:33 UTC

MDEV-23659: Update Galera disabled.def file

This fix removes from the list of disabled tests all
tests that were fixed by the patch for MDEV-21770.

bb-10.1-danielblack-MDEV-23887-check_linker_flags-oldcmakesupport 2020-10-14 21:10:38 UTC 2020-10-14
MDEV-23887: check_linker_flags - cmake compatibility

Author: Daniel Black
Author Date: 2020-10-07 05:06:20 UTC

MDEV-23887: check_linker_flags - cmake compatibility

It was only from CMake-3.14.0 that CMAKE_REQUIRED_LINK_OPTIONS
was used in CHECK_CXX_SOURCE_COMPILES. Without this, it could be
the case (as was on OSX) that a flag was never checked in
CHECK_CXX_SOURCE_COMPILES, it successfully passed, but failed at link
time.

Tested on x86_64 with:
* 3.11.4
* 3.17.4

Corrects: 7473e1841c630d86f1873a2a7afacb53955b3f6f

Reviewer: Sergei Golubchik

bb-10.2-kevgs 2020-10-14 18:30:15 UTC 2020-10-14
UBSAN ../storage/innobase/buf/buf0buddy.cc:350:6: runtime error: index 4096 o...

Author: Eugene
Author Date: 2020-10-14 18:30:15 UTC

UBSAN ../storage/innobase/buf/buf0buddy.cc:350:6: runtime error: index 4096 out of bounds for type 'byte [38]'

10.4 2020-10-14 12:14:46 UTC 2020-10-14
MDEV-22761: innodb row_search_idx_cond_check handle CHECK_ABORTED_BY_USER

Author: Daniel Black
Author Date: 2020-10-09 21:28:53 UTC

MDEV-22761: innodb row_search_idx_cond_check handle CHECK_ABORTED_BY_USER

Part #3:
Two more cases within row_search_mvcc need to handle the CHECK_ABORTED_BY_USER
and process this as a DB_INTERRUPTED.

bb-10.4-danielblack-MDEV-22761 2020-10-14 12:14:46 UTC 2020-10-14
MDEV-22761: innodb row_search_idx_cond_check handle CHECK_ABORTED_BY_USER

Author: Daniel Black
Author Date: 2020-10-09 21:28:53 UTC

MDEV-22761: innodb row_search_idx_cond_check handle CHECK_ABORTED_BY_USER

Part #3:
Two more cases within row_search_mvcc need to handle the CHECK_ABORTED_BY_USER
and process this as a DB_INTERRUPTED.

bb-10.4-nikita 2020-10-14 07:01:11 UTC 2020-10-14
MDEV-19130 Assertion failed in handler::update_auto_increment

Author: Nikita Malyavin
Author Date: 2019-10-09 06:48:50 UTC

MDEV-19130 Assertion failed in handler::update_auto_increment

add store/restore_auto_increment in period portion insert/update functions

bb-10.5-MDEV-23955 2020-10-14 06:23:11 UTC 2020-10-14
MDEV-23955 main.multi_update_big times out

Author: Marko Mäkelä
Author Date: 2020-10-14 06:21:10 UTC

MDEV-23955 main.multi_update_big times out

Copying generated data from the sequence engine should be faster
than copying from MyISAM to MyISAM. Let us hope that this fixes
the test failure on Travis CI ARMv8.

10.5-mdev-18511 2020-10-13 19:25:09 UTC 2020-10-13
MDEV-18511: CTE support for UPDATE and DELETE statements

Author: Igor Babaev
Author Date: 2020-10-13 19:25:09 UTC

MDEV-18511: CTE support for UPDATE and DELETE statements
MDEV-23552: Merge mergeable derived tables used at the top level of UPDATE
            statements

A complement for the previous patch that allows to run successfully all
tests from
  derived_update.test, cte_update.test, view_update.test,
  derived_update_multi.test, cte_update_multi.test, view_update_multi.test
and from
  view.test, derived.test, derived_view.test,
  cte_nonrecursive, cte recursive
with --ps-protocol.

Some tests from view.test and derived_view were changed though. Later this
will be fixed.

bb-10.3-MDEV-21770 2020-10-13 11:40:49 UTC 2020-10-13
MDEV-23659: Update Galera disabled.def file

Author: Julius Goryavsky
Author Date: 2020-10-13 11:37:33 UTC

MDEV-23659: Update Galera disabled.def file

This fix removes from the list of disabled tests all
tests that were fixed by the patch for MDEV-21770.

bb-10.2-anel-MDEV-16676-jemalloc-v2 2020-10-13 11:37:49 UTC 2020-10-13
MDEV-16676 Using malloc-lib=jemalloc in MariaDB 10.2 causes non-critical erro...

Author: Anel Husakovic
Author Date: 2020-10-06 15:43:13 UTC

MDEV-16676 Using malloc-lib=jemalloc in MariaDB 10.2 causes non-critical error about missing mysql_config on startup

- This commit is based on patch 84fe9720a4d2483ff67b6a and suggestion of
Jean Weisbuch to use `ldconfig -p`
- Format of ldconfig output:
"libjemalloc.so.1 (libc6,x86-64) => /usr/lib/x86_64-linux-gnu/libjemalloc.so.1"

```
$ ./scripts/mysqld_safe
201013 13:36:50 mysqld_safe Adding '/usr/lib/x86_64-linux-gnu/libjemalloc.so.1' to LD_PRELOAD for mysqld
201013 13:36:50 mysqld_safe Logging to '/home/anel/builds/data-10.5/mysqld_safe_anel.err'.
201013 13:36:50 mysqld_safe Starting mysqld daemon with databases from /home/anel/builds/data-10.5
```
Reviewed by: Daniel Black, Faustin Lammler

10.3-MDEV-21770 2020-10-13 11:37:33 UTC 2020-10-13
MDEV-23659: Update Galera disabled.def file

Author: Julius Goryavsky
Author Date: 2020-10-13 11:37:33 UTC

MDEV-23659: Update Galera disabled.def file

This fix removes from the list of disabled tests all
tests that were fixed by the patch for MDEV-21770.

bb-10.6-midenok-MDEV-21652 2020-10-13 09:44:43 UTC 2020-10-13
MDEV-21652 Foreign key migration from old version

Author: midenok
Author Date: 2020-09-21 13:06:13 UTC

MDEV-21652 Foreign key migration from old version

== fk_check_legacy_storage(), fk_upgrade_legacy_storage() ==

fk_check_legacy_storage() checks whether upgrade is required for the
given table name by looking SYS_FOREIGN table for corresponding record
existence.

fk_upgrade_legacy_storage() does the upgrade routine which includes
getting the foreign keys from SYS_FOREIGN[_COLS], updating the
foreign/referenced shares as well as their FRM files, deleting the
records from SYS_FOREIGN[_COLS] tables.

Both routines utilize the internal SQL for SYS_FOREIGN[_COLS]
processing.

== Upgrade foreign keys via backoff action ==

When table is opened fk_check_legacy_storage() detects whether upgrade
is required and HA_ERR_FK_UPGRADE is returned to SQL layer which then
handles this error by backoff action from Open_table_context where
table is opened again with HA_OPEN_FOR_REPAIR flag which indicates
that fk_upgrade_legacy_storage() is required. After
fk_upgrade_legacy_storage() is done fk_check_legacy_storage() is
checked again to ensure that SYS_FOREIGN[_COLS] are empty for the
given table.

== Check foreign/referenced indexes existence ==

fk_upgrade_legacy_storage() via fk_upgrade_push_fk() fails if there
are no indexes in foreign/referenced tables for the given data
acquired from SYS_FOREIGN[_COLS].

== Internal SQL: select into both func and vars extension ==

fk_upgrade_legacy_storage() utilizes syntax extension in internal SQL:

  FETCH c INTO fk_upgrade_create_fk() fk_id, unused;

Thus the data is fetched into both fk_upgrade_create_fk() function and
fk_id variable.

== Rename table, rename column, drop table, drop column handling ==

When foreign table is opened it is automatically upgraded by backoff
action. But if the referenced table is altered or dropped first there
is no chance for the foreign table to get the correct data. So the
SYS_FOREIGN_[COLS] must be kept in sync with the above DDL operations
in respect of referenced names. DROP TABLE for the referenced table is
disabled as usual. DROP TABLE, DROP COLUMN relied in 10.5 on
dict_foreign_t cached data for the referenced tables. Now there is no
such possibility for the legacy data so we have to look at
SYS_FOREIGN_[COLS] directly.

== Reverted some SYS_FOREIGN(_COLS) routines ==

Rename table and rename column handling was done in sync with
SYS_FOREIGN_[COLS] in 10.5. To retain the above DDL consistency for
the referenced tables we still use that old synchronization code.

== ALGORITHM=COPY handling ==

Since we cannot faingrain ALGORITHM=COPY in innobase handler it is
disabled for the referenced tables unless the foreign tables are upgraded.

The check is done in create_table_info_t::create_table() and is
equivalent to DROP TABLE check as we are actually dropping the old
table after the copy routine is done.

== WITH_INNODB_LEGACY_FOREIGN_STORAGE macro ==

Every SYS_FOREIGN_[COLS] handling is wrapped inside
WITH_INNODB_LEGACY_FOREIGN_STORAGE compilation macro. When this macro
is disabled the foreign key upgrade is not possible. Future versions
will obsolete the upgrade completely.

== innodb_eval_sql debug interface ==

Test cases must fill SYS_FOREIGN_[COLS] with data. This is done with
setting the new innodb_eval_sql debug variable. The value of that
variable is processed by que_eval_sql().

== Some syntax error-friendly parser handling ==

que_eval_sql() was unfriendly on syntax errors: it just failed with
SIGABRT exception. To keep the server alive some frequent syntax
errors are now returned as DB_ERROR from que_eval_sql().

bb-10.6-midenok-MDEV-16417 2020-10-13 09:44:43 UTC 2020-10-13
MDEV-21652 Foreign key migration from old version

Author: midenok
Author Date: 2020-09-21 13:06:13 UTC

MDEV-21652 Foreign key migration from old version

== fk_check_legacy_storage(), fk_upgrade_legacy_storage() ==

fk_check_legacy_storage() checks whether upgrade is required for the
given table name by looking SYS_FOREIGN table for corresponding record
existence.

fk_upgrade_legacy_storage() does the upgrade routine which includes
getting the foreign keys from SYS_FOREIGN[_COLS], updating the
foreign/referenced shares as well as their FRM files, deleting the
records from SYS_FOREIGN[_COLS] tables.

Both routines utilize the internal SQL for SYS_FOREIGN[_COLS]
processing.

== Upgrade foreign keys via backoff action ==

When table is opened fk_check_legacy_storage() detects whether upgrade
is required and HA_ERR_FK_UPGRADE is returned to SQL layer which then
handles this error by backoff action from Open_table_context where
table is opened again with HA_OPEN_FOR_REPAIR flag which indicates
that fk_upgrade_legacy_storage() is required. After
fk_upgrade_legacy_storage() is done fk_check_legacy_storage() is
checked again to ensure that SYS_FOREIGN[_COLS] are empty for the
given table.

== Check foreign/referenced indexes existence ==

fk_upgrade_legacy_storage() via fk_upgrade_push_fk() fails if there
are no indexes in foreign/referenced tables for the given data
acquired from SYS_FOREIGN[_COLS].

== Internal SQL: select into both func and vars extension ==

fk_upgrade_legacy_storage() utilizes syntax extension in internal SQL:

  FETCH c INTO fk_upgrade_create_fk() fk_id, unused;

Thus the data is fetched into both fk_upgrade_create_fk() function and
fk_id variable.

== Rename table, rename column, drop table, drop column handling ==

When foreign table is opened it is automatically upgraded by backoff
action. But if the referenced table is altered or dropped first there
is no chance for the foreign table to get the correct data. So the
SYS_FOREIGN_[COLS] must be kept in sync with the above DDL operations
in respect of referenced names. DROP TABLE for the referenced table is
disabled as usual. DROP TABLE, DROP COLUMN relied in 10.5 on
dict_foreign_t cached data for the referenced tables. Now there is no
such possibility for the legacy data so we have to look at
SYS_FOREIGN_[COLS] directly.

== Reverted some SYS_FOREIGN(_COLS) routines ==

Rename table and rename column handling was done in sync with
SYS_FOREIGN_[COLS] in 10.5. To retain the above DDL consistency for
the referenced tables we still use that old synchronization code.

== ALGORITHM=COPY handling ==

Since we cannot faingrain ALGORITHM=COPY in innobase handler it is
disabled for the referenced tables unless the foreign tables are upgraded.

The check is done in create_table_info_t::create_table() and is
equivalent to DROP TABLE check as we are actually dropping the old
table after the copy routine is done.

== WITH_INNODB_LEGACY_FOREIGN_STORAGE macro ==

Every SYS_FOREIGN_[COLS] handling is wrapped inside
WITH_INNODB_LEGACY_FOREIGN_STORAGE compilation macro. When this macro
is disabled the foreign key upgrade is not possible. Future versions
will obsolete the upgrade completely.

== innodb_eval_sql debug interface ==

Test cases must fill SYS_FOREIGN_[COLS] with data. This is done with
setting the new innodb_eval_sql debug variable. The value of that
variable is processed by que_eval_sql().

== Some syntax error-friendly parser handling ==

que_eval_sql() was unfriendly on syntax errors: it just failed with
SIGABRT exception. To keep the server alive some frequent syntax
errors are now returned as DB_ERROR from que_eval_sql().

bb-10.3-galera 2020-10-13 09:38:57 UTC 2020-10-13
Additional tests are enabled

Author: Julius Goryavsky
Author Date: 2020-10-13 09:38:57 UTC

Additional tests are enabled

bb-10.6-cache-metadata 2020-10-12 23:03:33 UTC 2020-10-12
MDEV-19237 Do not resend unchanged result set metadata for prepared statements

Author: Vladislav Vaintroub
Author Date: 2020-09-22 16:12:58 UTC

MDEV-19237 Do not resend unchanged result set metadata for prepared statements

bb-10.2-wlad 2020-10-12 19:15:24 UTC 2020-10-12
MDEV-23740 - X509_R_CERT_ALREADY_IN_HASH_TABLE when establishing SSL connec...

Author: Vladislav Vaintroub
Author Date: 2020-10-12 19:15:24 UTC

MDEV-23740 - X509_R_CERT_ALREADY_IN_HASH_TABLE when establishing SSL connection
connection.

According to bug report it happens in OpenSSL 1.0.2k, but not in 1.1.1

How to reproduce it is not yet known. I was not trigger it on the same OS
where it happened for the reporter.

bb-10.5-MDEV-21916 2020-10-12 15:07:33 UTC 2020-10-12
MDEV-21916: COM_STMT_BULK_EXECUTE with RETURNING insert wrong values

Author: Oleksandr "Sanja" Byelkin
Author Date: 2020-06-22 16:21:21 UTC

MDEV-21916: COM_STMT_BULK_EXECUTE with RETURNING insert wrong values

To allocate new net buffer to avoid changing bufer we are reading.

bb-10.4-MDEV-22596 2020-10-12 14:40:32 UTC 2020-10-12
MDEV-22596: Check if deletion period is specified by constant

Author: Nayuta Yanagisawa
Author Date: 2020-10-11 12:26:38 UTC

MDEV-22596: Check if deletion period is specified by constant

DELETE...FOR PORTION OF... statement accepted non-constant
FROM...TO clause. This contradicts the documentation and
is inconsistent with the behavior of UPDATE statement.
Thus, we add a validation that checks if a given deletion
period is specified by constant.

bb-10.2-vicentiu 2020-10-12 10:38:59 UTC 2020-10-12
MDEV-23941: strings/json_lib.c:893:12: style: Suspicious condition

Author: Vicențiu Ciorbaru
Author Date: 2020-10-12 10:38:59 UTC

MDEV-23941: strings/json_lib.c:893:12: style: Suspicious condition

The characters parsed are always ascii characters, hence one byte. This
means that the code did not have "incorrect" logic because the boolean
condition, if true, would also evaluate to the value of 1.

The condition however is semantically wrong, assuming a length is equal
to the condition outcome. Change paranthesis to make it also read
according to the intent.

bb-10.3-MDEV-23445 2020-10-11 16:14:23 UTC 2020-10-11
MDEV-23445: LIMIT ROWS EXAMINED throws error in Debug build only

Author: Rucha Deodhar
Author Date: 2020-10-08 17:35:35 UTC

MDEV-23445: LIMIT ROWS EXAMINED throws error in Debug build only

Analysis: When we reach the maximum limit to examine rows killed_state is set
as ABORT. But this isn't an actual error and we still return TRUE. This
eventually sets error as UNKNOWN ERROR.
Fix: Check if need to stop execution by checking the killed state. If we have
to abort it, return false because this isn't an actual error.

bb-10.4-MDEV-23935 2020-10-11 14:51:45 UTC 2020-10-11
MDEV-23935: Fix warnings generated during compilation of plugin/auth_pam/test...

Author: Dmitry Shulga
Author Date: 2020-10-11 14:51:45 UTC

MDEV-23935: Fix warnings generated during compilation of plugin/auth_pam/testing/pam_mariadb_mtr.c on MacOS

During build server 10.4 on MacOS warnings like the following one
are generated on compiling the file plugin/auth_pam/testing/pam_mariadb_mtr.c

server-10.4/plugin/auth_pam/testing/pam_mariadb_mtr.c:25:22: error:
initializing 'char *' with an expression of type 'const char [23]'
discards qualifiers [-Werror,-Wincompatible-pointer-types-discards-qualifiers]
{ PAM_TEXT_INFO, "Challenge input first." }

The reason of the warnings is that the data member pam_message::msg is declared
as 'char *' on MacOS but initializer of the data member is 'const char *'.

To eliminate warnings the compiler option
  -Wno-incompatible-pointer-types-discards-qualifiers
has been added to the compiler flags used for compiling the file
pam_mariadb_mtr.c.

bb-10.2-MDEV-23925 2020-10-09 13:55:14 UTC 2020-10-09
MDEV-23925: Fix warnings generated during compilation of mysys_ssl/openssl.c ...

Author: Dmitry Shulga
Author Date: 2020-10-09 13:55:14 UTC

MDEV-23925: Fix warnings generated during compilation of mysys_ssl/openssl.c on MacOS

Compiler warnings listed below are generated during server build on MacOS:
In file included from server-10.2-MDEV-23564/mysys_ssl/openssl.c:33:
In file included from /usr/local/include/openssl/evp.h:16:
In file included from /usr/local/include/openssl/bio.h:20:
/usr/local/include/openssl/crypto.h:206:10: warning: 'CRYPTO_cleanup_all_ex_data' macro redefined [-Wmacro-redefined]
         ^
/mariadb/server-10.2-MDEV-23564/include/ssl_compat.h:46:9: note: previous definition is here
        ^
In file included from /mariadb/server-10.2-MDEV-23564/mysys_ssl/openssl.c:33:
/usr/local/include/openssl/evp.h:501:10: warning: 'EVP_MD_CTX_init' macro redefined [-Wmacro-redefined]
         ^
/mariadb/server-10.2-MDEV-23564/include/ssl_compat.h:33:9: note: previous definition is here
        ^
In file included from /mariadb/server-10.2-MDEV-23564/mysys_ssl/openssl.c:33:
/usr/local/include/openssl/evp.h:627:11: warning: 'EVP_CIPHER_CTX_init' macro redefined [-Wmacro-redefined]
          ^
/mariadb/server-10.2-MDEV-23564/include/ssl_compat.h:35:9: note: previous definition is here
        ^
In file included from /mariadb/server-10.2-MDEV-23564/mysys_ssl/openssl.c:33:
/usr/local/include/openssl/evp.h:866:11: warning: 'EVP_cleanup' macro redefined [-Wmacro-redefined]
          ^
/mariadb/server-10.2-MDEV-23564/include/ssl_compat.h:44:9: note: previous definition is here
        ^
4 warnings generated.

In case MariaDB serer is build with -DCMAKE_BUILD_TYPE=Debug it results in
build error.

The reason of compiler warnings is that header file <ssl_compat.h>
included before the openssl system header files. File ssl_compat.h
contains some macros with the name as SSL API functions declared
in the openssl system header files. It resulted in duplicate
symbols thats produces compiler warnings.

To fix the issue the header file ssl_compat.h should be included
after a line where openssl system header is included.

bb-10.2-MDEV-23926 2020-10-09 13:35:48 UTC 2020-10-09
MDEV-23926: Fix warnings generated during compilation of plugin/auth_pam/mapp...

Author: Dmitry Shulga
Author Date: 2020-10-09 13:35:48 UTC

MDEV-23926: Fix warnings generated during compilation of plugin/auth_pam/mapper/pam_user_map.c on MacOS

Compiler warnings listed below are generated during server build on MacOS:

88%] Building C object plugin/auth_pam/CMakeFiles/pam_user_map.dir/mapper/pam_user_map.c.o
/Users/shulga/projects/mariadb/server-10.2/plugin/auth_pam/mapper/pam_user_map.c:87:41: error: passing
'gid_t *' (aka 'unsigned int *') to parameter of type 'int *' converts between pointers to integer types
with different sign [-Werror,-Wpointer-sign]
if (getgrouplist(user, user_group_id, loc_groups, &ng) < 0)
^~~~~~~~~~
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk/usr/include/unistd.h:650:43: note:
passing argument to parameter here
int getgrouplist(const char *, int, int *, int *);
^
/Users/shulga/projects/mariadb/server-10.2/plugin/auth_pam/mapper/pam_user_map.c:95:46: error: passing
'gid_t *' (aka 'unsigned int *') to parameter of type 'int *' converts between pointers to integer types
with different sign [-Werror,-Wpointer-sign]
(void) getgrouplist(user, user_group_id, loc_groups, &ng);
^~~~~~~~~~
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk/usr/includ
e/unistd.h:650:43: note:
passing argument to parameter here
int getgrouplist(const char *, int, int *, int *);
^
2 errors generated.

In case MariaDB serer is build with -DCMAKE_BUILD_TYPE=Debug it results in
uild error.

The reason of compiler warnings is that declaration of the Posix C API function
getgrouplist() on MacOS differs from declration of getgrouplist() proposed
by Posix.

To suppress this compiler warning cmake configure was adapted to detect what
kind of getgrouplist() function is declared on the building platform and
set the macros HAVE_POSIX_GETGROUPLIST in case the building platform suppors
Posix compatible interface of the getgrouplist() function. Depending on
whether this macros is set the compatible type of arguments is used to pass
parameter values to the function.

bb-10.1-thiru 2020-10-08 11:59:23 UTC 2020-10-08
MDEV-23722 InnoDB: Assertion: result != FTS_INVALID in fts_trx_row_get_new_state

Author: THIRUNARAYANAN BALATHANDAYUTHAPANI
Author Date: 2020-09-29 10:48:43 UTC

MDEV-23722 InnoDB: Assertion: result != FTS_INVALID in fts_trx_row_get_new_state

Marking of deletion of row in fts index happens twice in
self-referential foreign key relation. So while performing
referential checks of foreign key, InnoDB can avoid updating
of fts index if the foreign key has self-referential relationship.

Reviewed-by: Marko Mäkelä

bb-10.2-danielblack-MDEV-23630-mysqldump-native-sql 2020-10-08 02:03:58 UTC 2020-10-08
MDEV-23630: mysqldump logically dump system table information

Author: Daniel Black
Author Date: 2020-08-30 00:53:20 UTC

MDEV-23630: mysqldump logically dump system table information

Add --system={all, users, plugins, udf, servers, stats, timezones}

This will dump system information from the server in
a logical form like
* CREATE USER
* GRANT
* CREATE ROLE
* CREATE SERVER
* INSTALL PLUGIN
* CREATE FUNCTION

"stats" is the innodb statistics tables or EITS and
these are dumped as INSERT/REPLACE INTO statements
without recreating the table.

"timezones" is the collection of timezone tables
which are important to transfer to generate identical
results on restoration.

Two other options have an effect on the SQL generated by
--system=all. These are mutually exclusive of each other.
* --replace
* --insert-ignore

--replace will include "OR REPLACE" into the logical form
like 'CREATE OR REPLACE USER ...'

--insert-ignore uses the construct " IF NOT EXISTS" where
supported in the logical syntax.

'CREATE OR REPLACE USER' includes protection against
being run as the same user that is importing the mysqldump.

Includes experimental support for dumping mysql-5.7/8.0
system tables.

bb-10.2-MDEV-23564 2020-10-07 17:48:47 UTC 2020-10-07
MDEV-23564: CMAKE failing due to deprecated Apple GSS method

Author: Dmitry Shulga
Author Date: 2020-10-07 17:48:47 UTC

MDEV-23564: CMAKE failing due to deprecated Apple GSS method

Some GSS-API functions like gss_import_name(), gss_release_buffer()
used in plugin/auth_gssapi and libmariadb/plugins/auth are marked
as deprecated in MacOS starting from version 10.14+. It results in
extra warnings output on server building.

To eliminate extra warnings the flag '-Wno-deprecated-declarations'
has been added to compiler invocation string for those source
files that invoke deprecated GSS-API functions.

bb-10.3-MDEV-21770-v2 2020-10-07 12:54:45 UTC 2020-10-07
MDEV-21770v2: Fixed address parsing issues and added explicit '-6' option for...

Author: Julius Goryavsky
Author Date: 2020-10-06 12:57:28 UTC

MDEV-21770v2: Fixed address parsing issues and added explicit '-6' option for debian netcat

bb-10.2-MDEV-15703 2020-10-07 11:43:54 UTC 2020-10-07
Fix of typo in the comment.

Author: Oleksandr "Sanja" Byelkin
Author Date: 2020-07-14 08:12:22 UTC

Fix of typo in the comment.

bb-10.6-serg 2020-10-07 11:04:23 UTC 2020-10-07
cleanup: reduce size of Item_param - my_decimal

Author: Sergei Golubchik
Author Date: 2020-10-07 09:50:25 UTC

cleanup: reduce size of Item_param - my_decimal

bb-10.3-MDEV-19273 2020-10-07 08:07:48 UTC 2020-10-07
MDEV-19273: Server crash in MDL_ticket::has_stronger_or_equal_type or Asserti...

Author: Oleksandr "Sanja" Byelkin
Author Date: 2020-03-22 10:33:53 UTC

MDEV-19273: Server crash in MDL_ticket::has_stronger_or_equal_type or Assertion `thd->mdl_context.is_lock_owner(MDL_key::TABLE, table->db.str, table->table_name.str, MDL_SHARED)' failed in mysql_rm_table_no_locks

Early report error in case of DROP SEQUENCE <non-sequence>

Do not use error variable for other purposes except error.

bb-10.6-release 2020-10-07 06:34:45 UTC 2020-10-07
MDEV-22189: Change error messages inside code to have mariadb instead of mysql

Author: Rucha Deodhar
Author Date: 2020-10-01 11:56:23 UTC

MDEV-22189: Change error messages inside code to have mariadb instead of mysql

Changed error messages, rerecorded results and changed other relevant files.

bb-10.3-danielblack-MDEV-23892-pr979 2020-10-06 21:55:23 UTC 2020-10-06
Link against libatomic on platforms missing 64-bit atomics

Author: John Paul Adrian Glaubitz
Author Date: 2018-12-01 09:34:01 UTC

Link against libatomic on platforms missing 64-bit atomics

Some architectures require linking against libatomic for
using 64-bit atomic operations like __atomic_load_8. Due
to a bug in gcc, linking against libatomic is not happening
automatically when using C11 code.

See: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81358

Atomics libraries are now global.

Rework of global check to include compile and link by Daniel
Black.

Tested on AIX7.1

cmake -UHAVE_ATOMIC_ADD_FETCH_WITH_LIBATOMIC -UHAVE_ATOMIC_ADD_FETCH .
-- Running cmake version 3.16.0
-- MariaDB 10.3.25
getconf: specified variable is not valid on this system
-- Performing Test HAVE_ATOMIC_ADD_FETCH
-- Performing Test HAVE_ATOMIC_ADD_FETCH - Failed
-- Performing Test HAVE_ATOMIC_ADD_FETCH_WITH_LIBATOMIC
-- Performing Test HAVE_ATOMIC_ADD_FETCH_WITH_LIBATOMIC - Success

closes #979

bb-10.2-MDEV-16664 2020-10-06 06:28:55 UTC 2020-10-06
MDEV-16664 : InnoDB: Failing assertion: !other_lock || wsrep_thd_is_BF ... if...

Author: Jan Lindström
Author Date: 2020-10-06 05:45:48 UTC

MDEV-16664 : InnoDB: Failing assertion: !other_lock || wsrep_thd_is_BF ... if innodb_lock_schedule_algorithm=VATS

Problem was that conflicting lock request was added to the lock wait
queue before a conflicting lock granted lock.

lock_rec_insert_by_trx_age
 Added assertion that if there is lock request in a queue
 it has to be a waiting lock request. While we find place
 for this lock request we need to check that lock request
 in a queue has not been granted as this new lock request
 can't be inserted before it.

bb-10.2-MDEV-20787 2020-10-05 22:00:58 UTC 2020-10-05
MDEV-20787: Script dgcov.pl does not work

Author: Anel Husakovic
Author Date: 2020-10-05 21:39:07 UTC

MDEV-20787: Script dgcov.pl does not work

- This patch is done after doing test on 00f9df29224ada9cdbb796c99f4
where difference was found between versions of gcov.
- This patch doesn't take gcov versions in account since is extracting
filename of a `.gcov` file, which is generated with `gcov -i
<source-file>.gcda` during `dgcov.pl --generate`.
- There is a check if file exists.
Reason for that is because some generated `gcov` files are outliers from above
rule (that a file generated in intermediate format(gcov) has the same source name).
Example 1: `aestables.cpp.gcda` is not generating `aestables.cpp.gcov`,
but only the files used in #include `modes.hpp.gcov runtime.hpp.gcov`
Example 2: `my_sha256.cc.gcda` is generating `my_sha.ic.gcov`
- Make sure to test `MTR_BINDIR` which gets set during out-of-source
build and generate error when running `./mysql-test/mtr --gcov alias`
- During the testing:
  10.1 results are stored in
  - `<basedir>//mysql-test-gcov.msg` and errors in
  - `<basedir>//mysql-test-gcov.err`
  10.2 results should be stored in
  `./mysql-test/var/last_changes.dgcov`, but only empty results are
  obtained (tests `1st` and `alias`).

bb-10.4-release 2020-10-05 16:18:05 UTC 2020-10-05
Merge branch '10.3' into 10.4

Author: Sergei Golubchik
Author Date: 2020-10-05 16:18:05 UTC

Merge branch '10.3' into 10.4

bb-10.3-release 2020-10-05 16:05:38 UTC 2020-10-05
Merge branch '10.2' into 10.3

Author: Sergei Golubchik
Author Date: 2020-10-05 16:05:38 UTC

Merge branch '10.2' into 10.3

bb-10.2-release 2020-10-05 15:53:10 UTC 2020-10-05
Merge branch '10.1' into 10.2

Author: Sergei Golubchik
Author Date: 2020-10-05 15:53:10 UTC

Merge branch '10.1' into 10.2

bb-10.1-release 2020-10-05 15:52:00 UTC 2020-10-05
bump VERSION

Author: Sergei Golubchik
Author Date: 2020-10-05 15:52:00 UTC

bump VERSION

bb-10.5-MDEV-21452 2020-10-05 14:53:48 UTC 2020-10-05
MDEV-23888: Potential server hang on replication with InnoDB

Author: Marko Mäkelä
Author Date: 2020-10-05 14:50:49 UTC

MDEV-23888: Potential server hang on replication with InnoDB

In MDEV-21452, SAFE_MUTEX flagged an ordering problem that involved
trx_t::mutex, LOCK_global_system_variables, and LOCK_commit_ordered
when running
./mtr --no-reorder\
 binlog.binlog_checksum,mix binlog.binlog_commit_wait,mix

Because LOCK_commit_ordered is acquired by replication code before
innobase_commit_ordered() is invoked, and because LOCK_commit_ordered
should be below LOCK_global_system_variables in the global latching
order, it turns out that we must avoid acquiring
LOCK_global_system_variables in any low-level code.

It also turns out that lock_rec_lock() acquires lock_sys_t::mutex
and then carries on to call lock_rec_enqueue_waiting(), which may
invoke THDVAR() via thd_lock_wait_timeout(). This call is problematic
if THDVAR() had never been invoked in that thread earlier.

innobase_trx_init(): Let us invoke THDVAR() at the start of an InnoDB
transaction so that future invocations of THDVAR() will avoid
LOCK_global_system_variables acquisition on the same THD. Because
the first call to intern_sys_var_ptr() will initialize all session
variables by not passing the offset to sync_dynamic_session_variables(),
this will indeed make any future THDVAR() invocation mutex-free.

There are some THDVAR() calls in other code (related to indexed virtual
columns, fulltext indexes, and DDL operations). No SAFE_MUTEX warning
was known for those, but there does not appear to be any replication
test coverage for indexed virtual columns or fulltext indexes. DDL should
be covered, and perhaps DDL code paths were already invoking THDVAR()
while not holding any InnoDB mutex.

Side note: MySQL should avoid this type of deadlocks since
mysql/mysql-server@4d275c8.
MariaDB never defined alloc_and_copy_thd_dynamic_variables(),
because we prefer to avoid overhead during connection creation.

Thanks to Andrei Elkin for debugging the SAFE_MUTEX issue, and to
Sergei Golubchik for the suggestion to invoke THDVAR() early.

bb-10.2-MDEV-23888 2020-10-05 14:50:49 UTC 2020-10-05
MDEV-23888: Potential server hang on replication with InnoDB

Author: Marko Mäkelä
Author Date: 2020-10-05 14:50:49 UTC

MDEV-23888: Potential server hang on replication with InnoDB

In MDEV-21452, SAFE_MUTEX flagged an ordering problem that involved
trx_t::mutex, LOCK_global_system_variables, and LOCK_commit_ordered
when running
./mtr --no-reorder\
 binlog.binlog_checksum,mix binlog.binlog_commit_wait,mix

Because LOCK_commit_ordered is acquired by replication code before
innobase_commit_ordered() is invoked, and because LOCK_commit_ordered
should be below LOCK_global_system_variables in the global latching
order, it turns out that we must avoid acquiring
LOCK_global_system_variables in any low-level code.

It also turns out that lock_rec_lock() acquires lock_sys_t::mutex
and then carries on to call lock_rec_enqueue_waiting(), which may
invoke THDVAR() via thd_lock_wait_timeout(). This call is problematic
if THDVAR() had never been invoked in that thread earlier.

innobase_trx_init(): Let us invoke THDVAR() at the start of an InnoDB
transaction so that future invocations of THDVAR() will avoid
LOCK_global_system_variables acquisition on the same THD. Because
the first call to intern_sys_var_ptr() will initialize all session
variables by not passing the offset to sync_dynamic_session_variables(),
this will indeed make any future THDVAR() invocation mutex-free.

There are some THDVAR() calls in other code (related to indexed virtual
columns, fulltext indexes, and DDL operations). No SAFE_MUTEX warning
was known for those, but there does not appear to be any replication
test coverage for indexed virtual columns or fulltext indexes. DDL should
be covered, and perhaps DDL code paths were already invoking THDVAR()
while not holding any InnoDB mutex.

Side note: MySQL should avoid this type of deadlocks since
mysql/mysql-server@4d275c8.
MariaDB never defined alloc_and_copy_thd_dynamic_variables(),
because we prefer to avoid overhead during connection creation.

Thanks to Andrei Elkin for debugging the SAFE_MUTEX issue, and to
Sergei Golubchik for the suggestion to invoke THDVAR() early.

bb-10.1-serg 2020-10-04 11:46:36 UTC 2020-10-04
MDEV-23358 main.upgrade_MDEV-19650 fails with result difference

Author: Sergei Golubchik
Author Date: 2020-08-26 11:08:33 UTC

MDEV-23358 main.upgrade_MDEV-19650 fails with result difference

When including a generated file, always use <...>.
We need the compiler to find it in the BINDIR, not in the SRCDIR.
But when including as "..." SRCDIR is always searched first.

The bug can only happen in out-of-source builds, if there was an
in-source build before.

bb-10.5-serg 2020-10-03 21:23:12 UTC 2020-10-03
S3 plugin fails to load depending on loaded storage engines

Author: Sergei Golubchik
Author Date: 2020-08-27 16:59:09 UTC

S3 plugin fails to load depending on loaded storage engines

storage engines are generally initialized in some random order
(by iterating the hash of plugin names).

S3 fails if it's initialized before Aria.

But it looks that while S3 needs Aria, it does not need
Aria to be initialized before S3. S3 copies maria_hton and then
overwrites every single member of it, so it can handle Aria being
initialized after S3.

bb-10.1-anel-MDEV-23679-mtrabort 2020-10-03 00:34:03 UTC 2020-10-03
MDEV-23769: MTR can abort before it prints the test result summary

Author: Anel Husakovic
Author Date: 2020-10-02 22:44:58 UTC

MDEV-23769: MTR can abort before it prints the test result summary

- Patch is solving generating report on warning
- 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.

Here are the test cases observed. Note that only in 6. scenario there is `print $child "HELLO\n";` problem in printing (to delete?).

1. Valid test case, but warning in server log
```
$ ./mtr MDEV-23769 --force
Logging: ./mtr MDEV-23769 --force
vardir: /home/anel/mariadb/10.1-mtr-in-source/mysql-test/var
Checking leftover processes...
Removing old var directory...
Creating var directory '/home/anel/mariadb/10.1-mtr-in-source/mysql-test/var'...
Checking supported features...
MariaDB Version 10.1.47-MariaDB-debug
 - SSL connections supported
 - binaries are debug compiled
Sphinx 'indexer' binary not found, sphinx suite will be skipped
Collecting tests...
Installing system database...

==============================================================================

TEST RESULT TIME (ms) or COMMENT
--------------------------------------------------------------------------

worker[1] Using MTR_BUILD_THREAD 300, with reserved ports 16000..16019
show databases;
Database
information_schema
mtr
mysql
performance_schema
test
main.MDEV-23769 [ fail ] Found warnings/errors in server log file!
        Test ended at 2020-10-03 02:13:00
line
2020-10-03 2:13:00 140309996242496 [Warning] option 'lock_wait_timeout': unsigned value 18446744073709551615 adjusted to 31536000
^ Found warnings in /home/anel/mariadb/10.1-mtr-in-source/mysql-test/var/log/mysqld.1.err
ok

 - saving '/home/anel/mariadb/10.1-mtr-in-source/mysql-test/var/log/main.MDEV-23769/' to '/home/anel/mariadb/10.1-mtr-in-source/mysql-test/var/log/main.MDEV-23769/'
--------------------------------------------------------------------------
The servers were restarted 0 times
Spent 0.000 of 4 seconds executing testcases
mysql-test-run: WARNING: Got errors/warnings while running tests, please examine '/home/anel/mariadb/10.1-mtr-in-source/mysql-test/var/log/warnings' for details.

Completed: Failed 1/1 tests, 0.00% were successful.

Failing test(s): main.MDEV-23769

The log files in var/log may give you some hint of what went wrong.

If you want to report this error, please read first the documentation
at http://dev.mysql.com/doc/mysql/en/mysql-test-suite.html

mysql-test-run: *** ERROR: there were failing test cases
```

2. Valid test cases (same), but warning in server log (Note reported single test case)
```
$ ./mtr MDEV-23769 MDEV-23769 --force
Logging: ./mtr MDEV-23769 MDEV-23769 --force
vardir: /home/anel/mariadb/10.1-mtr-in-source/mysql-test/var
Checking leftover processes...
Removing old var directory...
Creating var directory '/home/anel/mariadb/10.1-mtr-in-source/mysql-test/var'...
Checking supported features...
MariaDB Version 10.1.47-MariaDB-debug
 - SSL connections supported
 - binaries are debug compiled
Sphinx 'indexer' binary not found, sphinx suite will be skipped
Collecting tests...
Installing system database...

==============================================================================

TEST RESULT TIME (ms) or COMMENT
--------------------------------------------------------------------------

worker[1] Using MTR_BUILD_THREAD 300, with reserved ports 16000..16019
show databases;
Database
information_schema
mtr
mysql
performance_schema
test
main.MDEV-23769 [ fail ] Found warnings/errors in server log file!
        Test ended at 2020-10-03 02:15:05
line
2020-10-03 2:15:04 139868136609344 [Warning] option 'lock_wait_timeout': unsigned value 18446744073709551615 adjusted to 31536000
^ Found warnings in /home/anel/mariadb/10.1-mtr-in-source/mysql-test/var/log/mysqld.1.err
ok

 - saving '/home/anel/mariadb/10.1-mtr-in-source/mysql-test/var/log/main.MDEV-23769/' to '/home/anel/mariadb/10.1-mtr-in-source/mysql-test/var/log/main.MDEV-23769/'
show databases;
Database
information_schema
mtr
mysql
performance_schema
test
main.MDEV-23769 [ fail ] Found warnings/errors in server log file!
        Test ended at 2020-10-03 02:15:05
line
2020-10-03 2:15:05 140513782085184 [Warning] option 'lock_wait_timeout': unsigned value 18446744073709551615 adjusted to 31536000
^ Found warnings in /home/anel/mariadb/10.1-mtr-in-source/mysql-test/var/log/mysqld.1.err
ok

 - saving '/home/anel/mariadb/10.1-mtr-in-source/mysql-test/var/log/main.MDEV-23769/' to '/home/anel/mariadb/10.1-mtr-in-source/mysql-test/var/log/main.MDEV-23769/'
--------------------------------------------------------------------------
The servers were restarted 1 times
Spent 0.000 of 5 seconds executing testcases
mysql-test-run: WARNING: Got errors/warnings while running tests, please examine '/home/anel/mariadb/10.1-mtr-in-source/mysql-test/var/log/warnings' for details.

Completed: Failed 2/2 tests, 0.00% were successful.

Failing test(s): main.MDEV-23769

The log files in var/log may give you some hint of what went wrong.

If you want to report this error, please read first the documentation
at http://dev.mysql.com/doc/mysql/en/mysql-test-suite.html

mysql-test-run: *** ERROR: there were failing test cases
```

3. Valid test cases (different test cases), but warning in server log (Note one passed one failed)

```
$ ./mtr MDEV-23769 1st --force
Logging: ./mtr MDEV-23769 1st --force
vardir: /home/anel/mariadb/10.1-mtr-in-source/mysql-test/var
Checking leftover processes...
Removing old var directory...
Creating var directory '/home/anel/mariadb/10.1-mtr-in-source/mysql-test/var'...
Checking supported features...
MariaDB Version 10.1.47-MariaDB-debug
 - SSL connections supported
 - binaries are debug compiled
Sphinx 'indexer' binary not found, sphinx suite will be skipped
Collecting tests...
Installing system database...

==============================================================================

TEST RESULT TIME (ms) or COMMENT
--------------------------------------------------------------------------

worker[1] Using MTR_BUILD_THREAD 300, with reserved ports 16000..16019
show databases;
Database
information_schema
mtr
mysql
performance_schema
test
main.MDEV-23769 [ fail ] Found warnings/errors in server log file!
        Test ended at 2020-10-03 02:17:09
line
2020-10-03 2:17:08 140658805515840 [Warning] option 'lock_wait_timeout': unsigned value 18446744073709551615 adjusted to 31536000
^ Found warnings in /home/anel/mariadb/10.1-mtr-in-source/mysql-test/var/log/mysqld.1.err
ok

 - saving '/home/anel/mariadb/10.1-mtr-in-source/mysql-test/var/log/main.MDEV-23769/' to '/home/anel/mariadb/10.1-mtr-in-source/mysql-test/var/log/main.MDEV-23769/'
main.1st [ pass ] 1
--------------------------------------------------------------------------
The servers were restarted 1 times
Spent 0.001 of 4 seconds executing testcases
mysql-test-run: WARNING: Got errors/warnings while running tests, please examine '/home/anel/mariadb/10.1-mtr-in-source/mysql-test/var/log/warnings' for details.

Completed: Failed 1/2 tests, 50.00% were successful.

Failing test(s): main.MDEV-23769

The log files in var/log may give you some hint of what went wrong.

If you want to report this error, please read first the documentation
at http://dev.mysql.com/doc/mysql/en/mysql-test-suite.html

mysql-test-run: *** ERROR: there were failing test cases

```

4. Now for example 3. create artificial failure with warnings in server log (note, both test failed)

```

$ ./mtr MDEV-23769 1st --force
Logging: ./mtr MDEV-23769 1st --force
vardir: /home/anel/mariadb/10.1-mtr-in-source/mysql-test/var
Checking leftover processes...
Removing old var directory...
Creating var directory '/home/anel/mariadb/10.1-mtr-in-source/mysql-test/var'...
Checking supported features...
MariaDB Version 10.1.47-MariaDB-debug
 - SSL connections supported
 - binaries are debug compiled
Sphinx 'indexer' binary not found, sphinx suite will be skipped
Collecting tests...
Installing system database...

==============================================================================

TEST RESULT TIME (ms) or COMMENT
--------------------------------------------------------------------------

worker[1] Using MTR_BUILD_THREAD 300, with reserved ports 16000..16019
show databases;
Database
information_schema
mtr
mysql
performance_schema
test
main.MDEV-23769 [ fail ] Found warnings/errors in server log file!
        Test ended at 2020-10-03 02:17:52
line
2020-10-03 2:17:51 140260493149760 [Warning] option 'lock_wait_timeout': unsigned value 18446744073709551615 adjusted to 31536000
^ Found warnings in /home/anel/mariadb/10.1-mtr-in-source/mysql-test/var/log/mysqld.1.err
ok

 - saving '/home/anel/mariadb/10.1-mtr-in-source/mysql-test/var/log/main.MDEV-23769/' to '/home/anel/mariadb/10.1-mtr-in-source/mysql-test/var/log/main.MDEV-23769/'
main.1st [ fail ]
        Test ended at 2020-10-03 02:17:52

CURRENT_TEST: main.1st
mysqltest: At line 5: End of line junk detected: "show tables in mysql
"

The result from queries just before the failure was:
show databases;
Database
information_schema
mtr
mysql
performance_schema
test

 - saving '/home/anel/mariadb/10.1-mtr-in-source/mysql-test/var/log/main.1st/' to '/home/anel/mariadb/10.1-mtr-in-source/mysql-test/var/log/main.1st/'
--------------------------------------------------------------------------
The servers were restarted 1 times
Spent 0.000 of 4 seconds executing testcases
mysql-test-run: WARNING: Got errors/warnings while running tests, please examine '/home/anel/mariadb/10.1-mtr-in-source/mysql-test/var/log/warnings' for details.

Completed: Failed 2/2 tests, 0.00% were successful.

Failing test(s): main.MDEV-23769 main.1st

The log files in var/log may give you some hint of what went wrong.

If you want to report this error, please read first the documentation
at http://dev.mysql.com/doc/mysql/en/mysql-test-suite.html

mysql-test-run: *** ERROR: there were failing test cases

```

5. Generate unknown option, for the same example as 3. (note: both failed)
```

$ ./mtr MDEV-23769 1st --mysqld=--xx --force
Logging: ./mtr MDEV-23769 1st --mysqld=--xx --force
vardir: /home/anel/mariadb/10.1-mtr-in-source/mysql-test/var
Checking leftover processes...
Removing old var directory...
Creating var directory '/home/anel/mariadb/10.1-mtr-in-source/mysql-test/var'...
Checking supported features...
MariaDB Version 10.1.47-MariaDB-debug
 - SSL connections supported
 - binaries are debug compiled
Sphinx 'indexer' binary not found, sphinx suite will be skipped
Collecting tests...
Installing system database...

==============================================================================

TEST RESULT TIME (ms) or COMMENT
--------------------------------------------------------------------------

worker[1] Using MTR_BUILD_THREAD 300, with reserved ports 16000..16019
worker[1] mysql-test-run: WARNING: Process [mysqld.1 - pid: 52531, winpid: 52531, exit: 512] died after mysql-test-run waited 0.3 seconds for /home/anel/mariadb/10.1-mtr-in-source/mysql-test/var/run/mysqld.1.pid to be created.
main.MDEV-23769 [ fail ]
        Test ended at 2020-10-03 02:19:01

CURRENT_TEST: main.MDEV-23769

Failed to start mysqld.1
mysqltest failed but provided no output

 - saving '/home/anel/mariadb/10.1-mtr-in-source/mysql-test/var/log/main.MDEV-23769/' to '/home/anel/mariadb/10.1-mtr-in-source/mysql-test/var/log/main.MDEV-23769/'
***Warnings generated in error logs during shutdown after running tests: main.MDEV-23769

2020-10-03 2:19:01 140238937720384 [Warning] option 'lock_wait_timeout': unsigned value 18446744073709551615 adjusted to 31536000
2020-10-03 2:19:01 140238937720384 [ERROR] /home/anel/mariadb/10.1-mtr-in-source/sql/mysqld: unknown option '--xx'
2020-10-03 2:19:01 140238937720384 [ERROR] Aborting

worker[1] mysql-test-run: WARNING: Process [mysqld.1 - pid: 52537, winpid: 52537, exit: 512] died after mysql-test-run waited 0.3 seconds for /home/anel/mariadb/10.1-mtr-in-source/mysql-test/var/run/mysqld.1.pid to be created.
main.1st [ fail ]
        Test ended at 2020-10-03 02:19:02

CURRENT_TEST: main.1st

Failed to start mysqld.1
mysqltest failed but provided no output

 - saving '/home/anel/mariadb/10.1-mtr-in-source/mysql-test/var/log/main.1st/' to '/home/anel/mariadb/10.1-mtr-in-source/mysql-test/var/log/main.1st/'
***Warnings generated in error logs during shutdown after running tests: main.1st

2020-10-03 2:19:02 140048201700928 [ERROR] /home/anel/mariadb/10.1-mtr-in-source/sql/mysqld: unknown option '--xx'
2020-10-03 2:19:02 140048201700928 [ERROR] Aborting

Can't use an undefined value as a symbol reference at ./mtr line 657.
--------------------------------------------------------------------------
The servers were restarted 1 times
Spent 0.000 of 5 seconds executing testcases

Completed: Failed 2/2 tests, 0.00% were successful.

Failing test(s): main.MDEV-23769 main.1st

The log files in var/log may give you some hint of what went wrong.

If you want to report this error, please read first the documentation
at http://dev.mysql.com/doc/mysql/en/mysql-test-suite.html

Errors/warnings were found in logfiles during server shutdown after running the
following sequence(s) of tests:
    main.MDEV-23769
    main.1st
mysql-test-run: *** ERROR: there were failing test cases

```

6. Again the same option, but with 2 same tests -> not perl error: `Can't use an undefined value as a symbol reference at ./mtr line 657.
` ` print $child "HELLO\n";` (solution delete the line).

```
$ ./mtr MDEV-23769 MDEV-23769 --mysqld=--xx --force
Logging: ./mtr MDEV-23769 MDEV-23769 --mysqld=--xx --force
vardir: /home/anel/mariadb/10.1-mtr-in-source/mysql-test/var
Checking leftover processes...
Removing old var directory...
Creating var directory '/home/anel/mariadb/10.1-mtr-in-source/mysql-test/var'...
Checking supported features...
MariaDB Version 10.1.47-MariaDB-debug
 - SSL connections supported
 - binaries are debug compiled
Sphinx 'indexer' binary not found, sphinx suite will be skipped
Collecting tests...
Installing system database...

==============================================================================

TEST RESULT TIME (ms) or COMMENT
--------------------------------------------------------------------------

worker[1] Using MTR_BUILD_THREAD 300, with reserved ports 16000..16019
worker[1] mysql-test-run: WARNING: Process [mysqld.1 - pid: 52595, winpid: 52595, exit: 512] died after mysql-test-run waited 0.3 seconds for /home/anel/mariadb/10.1-mtr-in-source/mysql-test/var/run/mysqld.1.pid to be created.
main.MDEV-23769 [ fail ]
        Test ended at 2020-10-03 02:20:12

CURRENT_TEST: main.MDEV-23769

Failed to start mysqld.1
mysqltest failed but provided no output

 - saving '/home/anel/mariadb/10.1-mtr-in-source/mysql-test/var/log/main.MDEV-23769/' to '/home/anel/mariadb/10.1-mtr-in-source/mysql-test/var/log/main.MDEV-23769/'
***Warnings generated in error logs during shutdown after running tests: main.MDEV-23769

2020-10-03 2:20:12 139815724283456 [Warning] option 'lock_wait_timeout': unsigned value 18446744073709551615 adjusted to 31536000
2020-10-03 2:20:12 139815724283456 [ERROR] /home/anel/mariadb/10.1-mtr-in-source/sql/mysqld: unknown option '--xx'
2020-10-03 2:20:12 139815724283456 [ERROR] Aborting

worker[1] mysql-test-run: WARNING: Process [mysqld.1 - pid: 52601, winpid: 52601, exit: 512] died after mysql-test-run waited 0.3 seconds for /home/anel/mariadb/10.1-mtr-in-source/mysql-test/var/run/mysqld.1.pid to be created.
main.MDEV-23769 [ fail ]
        Test ended at 2020-10-03 02:20:12

CURRENT_TEST: main.MDEV-23769

Failed to start mysqld.1
mysqltest failed but provided no output

 - saving '/home/anel/mariadb/10.1-mtr-in-source/mysql-test/var/log/main.MDEV-23769/' to '/home/anel/mariadb/10.1-mtr-in-source/mysql-test/var/log/main.MDEV-23769/'
***Warnings generated in error logs during shutdown after running tests: main.MDEV-23769

2020-10-03 2:20:12 140650797745728 [Warning] option 'lock_wait_timeout': unsigned value 18446744073709551615 adjusted to 31536000
2020-10-03 2:20:12 140650797745728 [ERROR] /home/anel/mariadb/10.1-mtr-in-source/sql/mysqld: unknown option '--xx'
2020-10-03 2:20:12 140650797745728 [ERROR] Aborting

Can't use an undefined value as a symbol reference at ./mtr line 657.
--------------------------------------------------------------------------
The servers were restarted 1 times
Spent 0.000 of 5 seconds executing testcases

Completed: Failed 2/2 tests, 0.00% were successful.

Failing test(s): main.MDEV-23769

The log files in var/log may give you some hint of what went wrong.

If you want to report this error, please read first the documentation
at http://dev.mysql.com/doc/mysql/en/mysql-test-suite.html

Errors/warnings were found in logfiles during server shutdown after running the
following sequence(s) of tests:
    main.MDEV-23769
    main.MDEV-23769
mysql-test-run: *** ERROR: there were failing test cases

```

bb-10.4-MDEV-23518 2020-10-02 11:49:26 UTC 2020-10-02
MDEV-23518 Syntax error in ond SP results in misleading message on SHOW CREAT...

Author: Oleksandr "Sanja" Byelkin
Author Date: 2020-08-28 14:05:38 UTC

MDEV-23518 Syntax error in ond SP results in misleading message on SHOW CREATE PROCEDURE

Add info to the error message how to get details about error which happened.

bb-10.4-MDEV-21329 2020-10-02 04:41:01 UTC 2020-10-02
MDEV-21329 InnoDB: Failing assertion: lock->lock_word.load(std::memory_order_...

Author: THIRUNARAYANAN BALATHANDAYUTHAPANI
Author Date: 2020-10-02 04:40:28 UTC

MDEV-21329 InnoDB: Failing assertion: lock->lock_word.load(std::memory_order_relaxed) == X_LOCK_DECR upon server shutdown

Problem is that dropping of fts table and sync of fts table
happens concurrently during fts optimize thread shutdown.
fts_optimize_remove_table() doesn't remove the table from the queue
and it leads to above scenario. While removing the table from
fts_optimize_wq, if the table can't be removed then wait till
fts_optimize_thread shuts down.

bb-10.2-MDEV-21329 2020-10-02 04:30:59 UTC 2020-10-02
MDEV-21329 InnoDB: Failing assertion: lock->lock_word.load(std::memory_order_...

Author: THIRUNARAYANAN BALATHANDAYUTHAPANI
Author Date: 2020-10-02 04:30:59 UTC

MDEV-21329 InnoDB: Failing assertion: lock->lock_word.load(std::memory_order_relaxed) == X_LOCK_DECR upon server shutdown

Problem is that dropping of fts table and sync of fts table
happens concurrently during fts optimize thread shutdown.
fts_optimize_remove_table() doesn't remove the table from the queue
and it leads to above scenario. While removing the table from
fts_optimize_wq, if the table can't be removed then wait till
fts_optimize_thread shuts down.

10.4-opt_trace 2020-10-01 15:49:03 UTC 2020-10-01
MDEV-23646: Optimizer trace: optimize_cond() should show ON expression proces...

Author: varun
Author Date: 2020-10-01 15:49:03 UTC

MDEV-23646: Optimizer trace: optimize_cond() should show ON expression processing

bb-10.5-MDEV-23399 2020-10-01 15:14:19 UTC 2020-10-01
MDEV-21452: Clean up LatchDebug, remove OSMutex, latch_t, ...

Author: Marko Mäkelä
Author Date: 2020-10-01 15:14:19 UTC

MDEV-21452: Clean up LatchDebug, remove OSMutex, latch_t, ...

bb-10.5-hf 2020-10-01 05:51:11 UTC 2020-10-01
FAke - just to kick the buildbot.

Author: Alexey Botchkov
Author Date: 2020-10-01 05:51:11 UTC

FAke - just to kick the buildbot.

bb-10.3-andrei 2020-09-30 15:18:03 UTC 2020-09-30
MDEV-23832 Crash at startup in Log_event::read_log_event

Author: Andrei Elkin
Author Date: 2020-09-29 16:12:00 UTC

MDEV-23832 Crash at startup in Log_event::read_log_event

The crash was caused by inproper raising of an error or replication checksum
verification at time of the server initialization. As there is no THD object
associated with the main initializing thread yet the error text should be
assigned with calling a respective macro that is aware of that possibility.

Fixed accordingly.

bb-10.5-danielblack-MDEV-22678-debian-mysql.com-5.7-upgrade-unix_socket-pr1670 2020-09-30 00:01:34 UTC 2020-09-30
MDEV-22678: Debian Upgrade from MySQL-5.7 CE fails with "Plugin 'auth_socket'...

Author: Daniel Black
Author Date: 2020-09-17 00:36:25 UTC

MDEV-22678: Debian Upgrade from MySQL-5.7 CE fails with "Plugin 'auth_socket' is not loaded

MySQL.com and Percona packages can be root auth_socket only. MariaDB uses unix_socket.
As the root user, as the default Debian maintaince user, needs to
be accessible to run mariadb-upgrade for a start, we make it accessible
again.

closes #1670

10.5-mdev21829-unique-interface 2020-09-29 12:10:56 UTC 2020-09-29
MDEV-21829: Packed Sort Keys in Unique: Address review input

Author: Sergey Petrunia
Author Date: 2020-09-29 12:10:56 UTC

MDEV-21829: Packed Sort Keys in Unique: Address review input

Make the Unique class an interface, and move the implementation
into class Unique_impl.

The idea is to allow seamless change of Unique class's implementation/
to something else.

The construction of Unique object still exposes the implementation:
the code uses "new Unique_impl(...)". It will be hidden in a factory
function.

bb-10.2-midenok 2020-09-29 10:51:42 UTC 2020-09-29
MDEV-23787 mtr --rr fixes

Author: midenok
Author Date: 2020-09-23 16:42:31 UTC

MDEV-23787 mtr --rr fixes

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.

bb-10.5-sujatha 2020-09-29 10:30:42 UTC 2020-09-29
Merge branch '10.4' into 10.5

Author: Sujatha Sivakumar
Author Date: 2020-09-29 10:30:42 UTC

Merge branch '10.4' into 10.5

# Conflicts:
# BUILD/SETUP.sh
# mysql-test/suite/galera_3nodes/disabled.def
# sql-common/client.c
# sql/handler.cc
# sql/log_event.cc
# sql/sql_class.cc
# sql/sql_class.h
# sql/sql_table.cc
# storage/innobase/btr/btr0sea.cc

bb-10.2-MDEV-23722 2020-09-29 07:08:07 UTC 2020-09-29
MDEV-23722 InnoDB: Failing assertion: result != FTS_INVALID in

Author: THIRUNARAYANAN BALATHANDAYUTHAPANI
Author Date: 2020-09-25 15:53:36 UTC

MDEV-23722 InnoDB: Failing assertion: result != FTS_INVALID in
   fts_trx_row_get_new_state

Marking of deletion of row in fts index happens twice in
self-referential foreign key relation. So while performing
referential checks of foreign key, InnoDB can avoid updating
of fts index if the foreign key has self-referential relationship.

bb-10.6-MDEV-21365 2020-09-29 06:54:48 UTC 2020-09-29
MDEV-21365: Check $MARIADB_HOME/my.cnf in addition to $MYSQL_HOME/my.cnf

Author: Rucha Deodhar
Author Date: 2020-09-29 06:54:48 UTC

MDEV-21365: Check $MARIADB_HOME/my.cnf in addition to $MYSQL_HOME/my.cnf

Currently for the server, we only check if $MYSQL_HOME is set. Added a check
if $MARIADB_HOME is set and try to read the configuration file from this
directory.
To keep behavior consistent with MariaDB Connector/C, checking $MARIADB_HOME
after $MYSQL_HOME.

bb-10.6-MDEV-23485-pr1651 2020-09-29 06:54:43 UTC 2020-09-29
MDEV-23485: Change table to merge engine may cause table data lost.

Author: zbdba
Author Date: 2020-08-24 09:51:10 UTC

MDEV-23485: Change table to merge engine may cause table data lost.

Problem:
If we want to change a table to merge engine, the original table
is not merge engine table and have rows may cause table data lost.

Solution:
Add check in the mysql_alter_table method, check if the original
table want to change to merge engine, it should't be merge engine
and have no rows.

closes #1651

bb-17399-hf 2020-09-27 12:12:48 UTC 2020-09-27
MDEV-17399 Add support for JSON_TABLE.

Author: Alexey Botchkov
Author Date: 2020-09-27 12:12:48 UTC

MDEV-17399 Add support for JSON_TABLE.

The specific table handler for the table functions was introduced,
and used to implement JSON_TABLE.

bb-10.5-bar 2020-09-26 14:04:17 UTC 2020-09-26
MDEV-23825 Join select_handler and Pushdown_select + XPand changes

Author: Alexander Barkov
Author Date: 2020-09-26 14:04:17 UTC

MDEV-23825 Join select_handler and Pushdown_select + XPand changes

10.6-varun 2020-09-25 16:35:00 UTC 2020-09-25
Refactoring

Author: varun <Varun Gupta>
Author Date: 2020-09-24 15:00:47 UTC

Refactoring

bb-10.5-MDEV-20386 2020-09-25 11:39:37 UTC 2020-09-25
Downgrade WolfSSL to fix a Windows build

Author: Marko Mäkelä
Author Date: 2020-09-25 11:39:37 UTC

Downgrade WolfSSL to fix a Windows build

The Windows build would fail even after reverting the
535c10f4586f0484c7d0d13434bcd55719b64ca4 changes to
extra/wolfssl/CMakeLists.txt.

bb-10.4-monty 2020-09-25 10:38:48 UTC 2020-09-25
Added asssert to init_of_queries() to make it more safe

Author: Monty
Author Date: 2020-09-25 10:38:48 UTC

Added asssert to init_of_queries() to make it more safe

Part of review of 10.4 code by Sergei.

Other things:

- Changed return type if is_active() from my_bool to bool as this is
  only used by C++ code.

bb-10.4-MDEV-23675 2020-09-25 09:47:35 UTC 2020-09-25
MDEV-23675 Assertion `pos < table->n_def' fails in dict_table_get_nth_col

Author: THIRUNARAYANAN BALATHANDAYUTHAPANI
Author Date: 2020-09-08 11:54:08 UTC

MDEV-23675 Assertion `pos < table->n_def' fails in dict_table_get_nth_col

- During insertion of clustered inde, InnoDB does the check for
foreign key constraints. It rebuild the tuple based on foreign
column names when there is no foreign index. While rebuilding,
InnoDB should ignore the dropped columns.

bb-10.4-sujatha 2020-09-25 06:47:17 UTC 2020-09-25
MDEV-22330: mysqlbinlog stops with an error Don't know how to handle columnMD...

Author: Sujatha Sivakumar
Author Date: 2020-09-25 06:26:29 UTC

MDEV-22330: mysqlbinlog stops with an error Don't know how to handle columnMDEV-22330: mysqlbinlog stops with an error Don't know how to handle column type: 255 meta: 4 (0004)

10.4 changes. Clean merge from 10.3

1100 of 810 results

Other repositories

Name Last Modified
lp:maria 2 hours ago
lp:~maria-captains/maria/+git/connector-c 2018-01-08
12 of 2 results
You can't create new repositories for MariaDB.