Home - Waterfall Grid T-Grid Console Builders Recent Builds Buildslaves Changesources - JSON API - About

Console View


Categories: connectors experimental galera main
Legend:   Passed Failed Warnings Failed Again Running Exception Offline No data

connectors experimental galera main
Fariha Shaikh
MDEV-39153 Fix sporadic main.change_master_default mismatch

The test used "restart_abort:" in the expect file, which MTR never
recognized. It fell through to the else branch, deleted restart_opts,
and started the server with defaults (heartbeat_period=60 instead of 0).

Replace restart_abort with direct --exec $MYSQLD calls.

All new code of the whole pull request, including one or several files
that are either new files or modified ones, are contributed under the
BSD-new license. I am contributing on behalf of my employer Amazon Web
Services, Inc.
Oleksandr Byelkin
Merge branch '10.6' into 10.11
Monty
MDEV-42003 Enhance mariadbd-multi to support mariadbd prefixes

- Update my.cnf options to support [mariadbd_multi] (same as
  [mysqld_multi]), and [mariadbd#] (same as [mysqld#]).
- Change all instances of mysqld to mariadbd, mysqladmin to mariadb-admin.
  - mysqld and mysqladmin can still be used as options and in config files
- mariadb-admin gets confused when both --socket and --port is provided.
  Now socket is used if --tcp-ip or --port is not used. Only one of
  --socket or --port is sent to mariadb-admin.
- A warning is given if a group number is used more than once, like
  [mysqld2] and [mariadbd2]. For compatibility with old configuration
  files, the options of all groups with the same number are combined,
  with later options overriding earlier ones.
- --print-commands will print all system commands to stdout
  (good for debugging)
Sergei Golubchik
MDEV-40229 I_S.VECTOR_INDEXES: Unclear or inconsistent semantics of INDEX_SIZE

11.8 fix for I_S.TABLES.INDEX_LENGTH column

Take into account both data_file_length and index_file_length,
they both take space and both belong to the vercor index.
Sergei Golubchik
userstat: DROP TABLE and DROP INDEX leave stale usage statistics

delete_statistics_for_table() and delete_statistics_for_index()
removed the userstat entries only after opening the statistical
tables, and returned early when that failed.

Delete the userstat entries before opening the statistical tables.

Assisted-by: Claude:claude-opus-5-5
Fariha Shaikh
MDEV-33660 Add note when setting AUTO_INCREMENT lower than next value

Currently, ALTER TABLE ... AUTO_INCREMENT = N silently fails when using
values lower than the next AUTO_INCREMENT value in the column.

Add a note when attempting to set AUTO_INCREMENT to a lower value than
the next AUTO_INCREMENT value, and maintain the higher value.

Update existing test suites and add a new test to the maria suite for
the newly added note.

All new code of the whole pull request, including one or several files
that are either new files or modified ones, are contributed under the
BSD-new license. I am contributing on behalf of my employer Amazon Web
Services, Inc.
Dave Gosselin
MDEV-39441: Add dbug_print() helpers for join-related types

Introduces new dbug_print() functions for the following types:
  dbug_print(NESTED_JOIN)
  dbug_print(JOIN)
  dbug_print(TABLE_LIST)
  dbug_print(JOIN_TAB)
  dbug_print(List<Item>)

Typically pointers to instances of the given types are passed.
The dbug_print(List<Item>) is intended to show result row before
sending to client (e.g., invoke in debugger while tracing end_send)
but may work in other contexts.

These functions produce nicely formatted output, please use them
in conjunction with the formatted printfs available in GDB or LLDB:
  (gdb) printf "%s", dbug_print(join_tab)
  (lldb) p printf("%s", dbug_print(table))

Example output from dbug_print(JOIN) in LLDB.  The last line with
value 1302 is the number of characters produced by the printf
command.

(lldb) p printf("%s",dbug_print(join))
JOIN [0x15801bfe8]  table_count=3  const_tables=0
join_list 0x158018340 [1 element(s)]:
--- #0 ---
  [0x15801af10] "(nest_last_join)"  join=INNER (outer_join=0)  nested_join=0x15801b618 (elements=2)
    NESTED_JOIN [0x15801b618]
      used_tables:    0x0
      not_null_tables: 0x0
      n_tables:        0
      counter:        0
      nest_type:      1 (JOIN_OP_NEST)
      nj_map:          0x0
      join_list:
        join_list 0x15801b618 [2 element(s)]:
        --- #0 ---
          [0x15801a308] "t3"  join=LEFT (outer_join=1)  map=0x4
            ON: `test`.`t2`.`a` = `test`.`t3`.`a`
        --- #1 ---
          [0x158019b30] "(nest_last_join)"  join=INNER (outer_join=0)  nested_join=0x15801a238 (elements=2)
            NESTED_JOIN [0x15801a238]
              used_tables:    0x0
              not_null_tables: 0x0
              n_tables:        0
              counter:        0
              nest_type:      0
              nj_map:          0x0
              join_list:
                join_list 0x15801a238 [2 element(s)]:
                --- #0 ---
                  [0x1580187c0] "t1"  join=RIGHT (outer_join=2)  map=0x1
                    ON: `test`.`t1`.`a` = `test`.`t2`.`a`
                --- #1 ---
                  [0x158018f08] "t2"  join=INNER (outer_join=0)  map=0x2
(int) 1302
Daniel Black
MDEV-17846 Wrong result with grouping select (fix)

Prevent unused variable 'ref_type'  warnings on non-debug builds.
Yuchen Pei
MDEV-40486 Length check for vector fields in CREATE TABLE ... SELECT

The changes of MDEV-39558 2b6529426a7e7c65d286e093d84138be9dcc34a3
added length check assertion in Field_varstring constructors, and
length check in type inference for SELECT set operations, to emit
errors before reaching the assertions.

That change caused an error to turn into an assertion failure in a
separate path, when the length limit violation is not detected before
tripping the assertion. So in this patch we fix it by adding an
earlier length check in that path.

The reason that we place this check inside
Item_func_vec_fromtext::fix_length_and_dec rather than say
`create_field_for_create_select is for consistency:

If

create table t1 as select
vec_fromtext(concat('[',group_concat(1),']')) as c1 from seq_1_to_64;

fails due to length limit violation, then so should

create table t1 (v vector(64) not null);
insert into t1 select vec_fromtext(concat('[',group_concat(1),']'))
from seq_1_to_64;

Also use max_char_length() instead of max_length. This is a more
accurate length of characters. And add handling of empty string edge
case. Added testcases accordingly.

The change that uses max_char_length() causes side effects where
creating a table using a VEC_FROMTEXT(CHAR(1)) would result in a
0-dimensional vector field. This is accurate but 0-dim vector table
fields should not be allowed. So we make cases like this result in
a one-dimensional field.

Also fixed the underflow in (args[0]->max_length - 1) * 2 when the
arg's max length is 0. Previously this underflow would cause

create table t1 select vec_fromtext(NULL)

to fail with ER_TOO_BIG_FIELDLENGTH. Now it will be a VECTOR(1) field
Alexander Barkov
MDEV-40790 SELECT INTO row_type_of.field crashes the server

The server crashed on DBUG_ASSERT on a SELECT into:
- a `ROW TYPE OF table1` field variable
- a `ROW TYPE OF cursor1` field variable

Fix:

- Adding a class my_var_sp_row_field_by_name
- Adding a method sp_rcontext::set_variable_row_field_by_name()
- Fixing the DBUG_ASSERT
Sergei Golubchik
cleanup: remove obsolete CMAKE_VERSION checks

main CMakeLists.txt sets

CMAKE_MINIMUM_REQUIRED(VERSION 3.12.0)
Sergei Golubchik
caching_sha2_password: add test for max password length

as enforced by RSA with 2048-bit key and RSA PKCS1 OAEP padding
Daniel Black
MDEV-40801 ppc64le ro_after_init isn't pagesize aligned

Align ro_after_init using MAXPAGESIZE instead of COMMONPAGESIZE.

COMMONPAGESIZE may be smaller than the actual page size supported by
the target ABI. This can leave ro_after_init sharing an OS page with
adjacent sections, causing mprotect() to change permissions on data
outside ro_after_init.

Use MAXPAGESIZE so the section boundaries are aligned to the maximum
page size required by the target linker/ABI.

This is particularly important on architectures such as ppc64le and
aarch64, where the runtime page size can differ from COMMONPAGESIZE.

Before:
  .data          0x...1b80000
  ro_after_init  0x...1c70000
  .bss          0x...1c72000

After:
  ro_after_init starts and ends on MAXPAGESIZE boundaries, ensuring
  mprotect() only affects pages belonging to ro_after_init.

Co-authored-by: ChatGPT GPT-5.6 Luna <[email protected]>
Alexander Barkov
MDEV-40639 Open SYS_REFCURSOR crash, if many cursors inside a function

Problem:

If:
- A routine A() opened a SYS_REFCURSOR with a function B() in the SELECT list
- The function B() also opened some SYS_REFCURSORs

Then reallocation of the cursor array THD::m_statement_cursors could happen
during the execution of B(), so all sp_cursor_array_element pointers inside
sp_instr_copen_by_ref::exec_core() of routine A() became invalid.

Fix:

Chaging the data type of sp_cursor_array:
- from Dynamic_array<sp_cursor_array_element>
- to Dynamic_array<sp_cursor_array_element*>

So now only reallocations of the array of cursor pointers happen,
while sp_cursor_array_element instances always stay on their originally
allocated memory positions.

Note:
sp_cursor_array_element instances are allocated using the standart C++ "new"
and deleted using the standard C++ "delete". Using a MEM_ROOT does not
seem to be relevant here.
Marko Mäkelä
MDEV-40756 Incorrect multi-batch recovery of file size

file_name_t::page0_lsn: Keep track of the last applied
recv_sys_t::parse_page0() so that a multi-batch recovery
will not reset the file to a smaller size.

Reviewed by: Thirunarayanan Balathandayuthapani
Sergei Golubchik
UBSAN: runtime error: downcast of address 0x7ea259447dc8 which does not point to an object of type 'Item_row'

sql/item_cmpfunc.h:1184:34: runtime error: downcast of address 0x7ea259447dc8 which does not point to an object of type 'Item_row'
sql/item_cmpfunc.cc:2083:30: runtime error: member call on address 0x7ea259447dc8 which does not point to an object of type 'Item_row'
sql/item_cmpfunc.cc:2084:29: runtime error: member call on address 0x7ea259447dc8 which does not point to an object of type 'Item_row'
sql/item_cmpfunc.cc:2125:29: runtime error: member call on address 0x7ea259447dc8 which does not point to an object of type 'Item_row'
sql/item_cmpfunc.cc:2127:35: runtime error: member call on address 0x7ea259447dc8 which does not point to an object of type 'Item_row'

Indeed, the address was pointing to an object of type 'Item_aggregate_ref'
Daniel Black
MDEV-40243 Fix MEMORY_LEAK_C leaks in mariadb-dump  (rockdb tests)

With memory leaks fixed in the rocksdb.mysqldump/mysqldump2 no
longer need to run with leak detection disabled.

There tests are still disabled as there's no --rockdb arg to
mariadb-dump, but removing so there's no precidence to ignoring
leaks.

ref: 2217477fb8fc82f4921d9d13afcd24b1d86b34d6
Daniel Black
MDEV-40750 gcc-16.1.0 on ppc64 causes innodb to fail to compile

Assembler comes up with the error:
unrecognized opcode: `dcbstps'

dcbstps is a Power 10 instruction. The default target arch on most
platforms is Power 8 or 9.

Added the target power10 to the function pmem_phwsync. The execution
of this function is gated on the ISA 3.1 in pmem_persist_init so
there's no chance of a SIGILL.

clang supports this target as arch=pwr10 and gcc as cpu=power10.
Revert back to using opcodes for old versions.
Daniel Black
MDEV-40749 period.create test leaks/faults in asan

Selecting from the information_schema.plugins causes the loading
of all plugins. Because rockdb leaks, and duckdb triggers an
address sanitizer warning on shutdown avoid this table.

Use the information_schema.ENGINES to validate that InnoDB is
disabled per the original request in the review of MDEV-32205.
Sergei Golubchik
userstat: stack overflow on DROP TABLE with many index statistics

del_global_index_stats_for_table() collected all matching entries
into an array of MAX_INDEXES elements. Statistics of renamed indexes
stay in global_index_stats under their old names, so a table can have
more entries than that and DROP TABLE wrote past the array.

Delete the entries in batches of MAX_INDEXES.

Assisted-by: Claude:claude-opus-5-5
Sergei Golubchik
MDEV-40690 auth_pam_tool loses setuid-root bit in RPM packages

without %dir, rpm list of files includes the content of auth_pam_tool_dir
recursively, and auth_pam_tool_dir has its own line too. The end result
depends on the order in which two lines are applied which in turn
depends on the order the sort will put them in. rpm 6 was rewritten
in C++ and moved from libc qsort to std::sort.

11.4+ fix, because `%dir %attr` only works in cmake >= 3.10
Sergei Golubchik
ColumnStore now requires gettid. Skip gracefully.
Alexander Barkov
MDEV-28498 Incorrect information in file: './test/t0.frm' on CREATE TABLE

Applying HEX encoding write writting an ENUM/SET TYPELIB to FRM
if the TYPELIB has 0x00 bytes in the value.

This HEX encoding was earlier used only to write UCS2/UTF16/UTF32 TYPELIBs.

A new flag FIELDFLAG_FRM_HEX_ENCODED_TYPELIB was added to indicate
that the TYPELIB is hex encoded. It's used only inside FRM.
Note, it's mangled with FIELDFLAG_TREAT_BIT_AS_CHAR.
This should not be harmful:
- BIT and ENUM/SET columns are handled by two separate code branches
  when opening an FRM
- The flag is unset immediately after decoding TYPELIB, so the rest
  of the code does not se an unexpected flag combination.
Oleksandr Byelkin
Merge branch '11.4' into 11.8
Georgi (Joro) Kodinov
MDEV-40661: mysql_upgrade.test not stable on a busy server

The cleanup of the old connection goes on in the background.
It can take longer on a busy server and this triggers the active sessions
warning in DROP user.
Stablizied the test by disabling the warnings.
sjaakola
MDEV-36677 rsync sst fails with different innodb_log_group_home_dir and datadir

Backported the fix done by Pekka Lampio for mariaDB 11.4 in PR
https://github.com/mariadb-corporation/codership-mariadb-server/pull/543

The PR has a fix for wsrep_sst_rsync script and new mtr test:
galera_3nodes.galera_mdev_36677" to check that the rsync SST method of Galera
works correctly also when the joiner node store InnoDB log files in a dedicated
directory separate from the data dictionary

Note: merging this PR to 11.4 may not be fully functional as there are other
changes in the rsync SST script. Take a look at the original 11.4 PR when merging.
Sergei Golubchik
MDEV-40730 SHOW DATABASES allows users with only GRANT OPTION privilege to read all databases names

Followup for MDEV-37951 (e7aec1c60c4), GRANT OPTION is an *OPTION* and
alone on itself shouldn't make the table or schema visible
Sergei Golubchik
update C/C

and remove temporary workarounds for C/C bugs
Daniel Black
MDEV-37224 Remove UBSAN limitation from MTR tests

Having a not_ubsan.inc as a test case exclusion mechanism is
allowing developers to ignore UBSAN issues. As undefined behaviour
detected at runtime or compile time isn't acceptable in the
code base, remove the exclusion.

The lotofstack test, the only user of not_ubsan.inc, has this
exclusion because the stack size under UBSAN lacks predictability.

Adjust its exclusion because of this criteria, and not its UBSAN
status.

Reviewer: Jimmy Hu <[email protected]>
Sergei Golubchik
disable DuckDB in the server in favor of the externally built

Fixes #6045
Sergei Golubchik
MDEV-40608 set INSTALL_SYSCONFDIR for external plugins

so that they could store their configs in basedir/etc/ in bintars
Alexey Yurchenko
Merge branch '10.11' into MDEV-38147-missing-result-file
Sergei Golubchik
rocksdb: don't abort early in submodule update

Fix for 1fb075512a7aeab8646a163cbb6f265c49f4c075 to allow
the ADD_SUBMODULE to perform updates.
Sergei Petrunia
MDEV-40738: main.cte_update_delete missing DROP VIEW v1, refers to wrong MDEVs.

Fix the testcase.
Sergei Golubchik
MDEV-41655 caching_sha2_password does not limit the password length

let's tighten the limits to be closer to actual OpenSSL limits.

Encrypting with RSA, 2048-bit key and PKCS1 OAEP padding *always*
produces the ciphertext of 256 bytes. And to fit in this, the plaintext
cannot be longer than 214 bytes. Assuming the user can generate her
own keys, 512 bytes would be enough for 4096-bit key. Larger, 8192-bit
keys don't work anyway (don't fit in public_key[] buffer).

And also let's reject too long passwords that can never authenticate.
Oleksandr Byelkin
Merge branch '10.11' into 11.4
Daniel Black
MDEV-34482 main.events_processlist test fix

As the test result is dependent of SHOW PROCESSLIST output,
adjust the wait condition to ensure the state is in sleeping
rather than "init" or another state.
Alexey Yurchenko
MDEV-38147 add missing result file for MDEV-38147_gtid_off test
Mohammad Tafzeel Shams
MDEV-39795: Assertion `n_reserved > 0' failed

Problem:
========

1. Assertion `n_reserved > 0` failed in fseg_create():

fsp_reserve_free_extents() has a special condition for small
tablespaces where it reserves individual pages instead of full
extents. In such cases, n_reserved can be 0 even when the
reservation succeeds, causing the assertion ut_ad(n_reserved > 0)
to fail incorrectly.

The code was checking n_reserved to determine whether a reservation
had already been attempted, but this logic breaks for small
tablespaces where pages, rather than extents, are reserved.

2. Encryption metadata not cleared for compressed-only pages:

buf_page_encrypt() only cleared encryption-related metadata
fields (key-version and crypt-checksum) when the page was
neither encrypted nor compressed. However, these fields should
also be cleared when page_compressed is true but encrypted is
false, to avoid leaving stale encryption metadata in
compressed-only pages.

Solution:
=========

buf_page_encrypt(): Refactored the early-return logic. Encryption
metadata fields are now cleared whenever encrypted is false,
regardless of page_compressed. The function returns early only
when both !encrypted and !page_compressed.

fseg_create(): Reintroduced a boolean variable `reserved` to track
whether fsp_reserve_free_extents() has been attempted (removed as
part of MDEV-38419 | c7313da), replacing assertion `n_reserved > 0`.
Added an early return when DB_DECRYPTION_FAILED is encountered
during inode allocation.

my_error_innodb(): Added handling for DB_DECRYPTION_FAILED to
report decryption errors to the user through ER_GET_ERRMSG.
Sergei Golubchik
Wrong table name in the warning about missing statistical table

open_stat_table_for_ddl() printed the global stat_table_name, always
`table_stats`, instead of the name of the table it failed to open.

Assisted-by: Claude:claude-opus-5-5