Details
-
Bug
-
Status: Closed (View Workflow)
-
Blocker
-
Resolution: Fixed
-
12.3.3
-
None
-
OpenBSD
-
Can result in hang or crash
-
An ALTER TABLE involving a named FOREIGN KEY constraint invoked undefined behaviour, which caused a crash on OpenBSD.
-
Q4/2026 Server Maintenance
Description
mariadbd: backwards memcpy in /var/log/messages
Thread 15 "one_connection" received signal SIGABRT, Aborted.
|
[Switching to thread 317856 of process 30711]
|
thrkill () at /tmp/-:2
|
âš ï¸ warning: 2 /tmp/-: No such file or directory
|
(gdb) bt
|
#0 thrkill () at /tmp/-:2
|
#1 0x96c612b201c0d9ee in ?? ()
|
#2 0x000007589fbfa73b in _libc_abort ()
|
at /usr/src/lib/libc/stdlib/abort.c:51
|
#3 0x000007589fbd69f7 in memcpy (dst0=<optimized out>,
|
src0=<optimized out>, length=<optimized out>)
|
at /usr/src/lib/libc/string/memcpy.c:74
|
#4 0x000007589fc19c46 in __sfvwrite (fp=0x75853d385a8,
|
uio=0x75853d38550)
|
at /usr/src/lib/libc/stdio/fvwrite.c:128
|
#5 0x000007589fbc5c1a in __sprint (fp=0x75853d385a8,
|
uio=<optimized out>)
|
at /usr/src/lib/libc/stdio/vfprintf.c:112
|
#6 __vfprintf (fp=0x75853d385a8,
|
fmt0=0x755b36d0123 "%s\377%s", ap=0x75853d38810)
|
at /usr/src/lib/libc/stdio/vfprintf.c:1071
|
#7 0x000007589fc1ef04 in _libc_snprintf (
|
str=0x7589fbc7c3b <thrkill+27> "s\017d\211\004% ",
|
n=<optimized out>, fmt=0x755b36d0123 "%s\377%s")
|
at /usr/src/lib/libc/stdio/snprintf.c:59
|
#8 0x00000755b4529f4f in dict_table_rename_in_cache (
|
table=0x757f4026378, new_name=...,
|
replace_new_file=<optimized out>)
|
at /usr/obj/ports/mariadb-12.3.3/mariadb-12.3.3/storage/innobase/dict/dict0dict.cc:1631
|
#9 0x00000755b46835e5 in row_rename_table_for_mysql (
|
old_name=0x75853d391c0 "dbix_class_schema_loader_test/#sql-alter-77f7-9-1",
|
new_name=0x75853d38dc0 "dbix_class_schema_loader_test/load--Type <RET> for more, q to quit, c to continue without paging--c
|
er_test6", trx=0x75868c6d5c0, fk=RENAME_ALTER_COPY)
|
at /usr/obj/ports/mariadb-12.3.3/mariadb-12.3.3/storage/innobase/row/row0mysql.cc:2720
|
#10 0x00000755b44fb536 in innobase_rename_table (
|
trx=0x75868c6d5c0,
|
from=0x75853d39fd0 "./dbix_class_schema_loader_test/#sql-alter-77f7-9-1", to=<optimized out>, fk=RENAME_ALTER_COPY)
|
at /usr/obj/ports/mariadb-12.3.3/mariadb-12.3.3/storage/innobase/handler/ha_innodb.cc:13780
|
#11 0x00000755b44fba20 in ha_innobase::rename_table (
|
this=<optimized out>,
|
from=0x75853d39fd0 "./dbix_class_schema_loader_test/#sql-alter-77f7-9-1",
|
to=0x75853d3a1d0 "./dbix_class_schema_loader_test/loader_test6")
|
at /usr/obj/ports/mariadb-12.3.3/mariadb-12.3.3/storage/innobase/handler/ha_innodb.cc:14219
|
#12 0x00000755b41ec6d7 in mysql_rename_table (
|
base=<optimized out>, old_db=0x75853d3be38,
|
old_name=0x75853d3be68, new_db=0x75853d3be38,
|
new_name=0x75853d3be58, id=0x75853d3be88, flags=21)
|
at /usr/obj/ports/mariadb-12.3.3/mariadb-12.3.3/sql/sql_table.cc:5661
|
#13 0x00000755b41f3b64 in mysql_alter_table (
|
thd=0x7580c501020, new_db=<optimized out>,
|
new_name=<optimized out>, create_info=0x75853d3cd60,
|
table_list=0x75886cd9250, recreate_info=0x75853d3d140,
|
alter_info=0x75853d3cfc8, order_num=0, order=0x0,
|
ignore=<optimized out>, if_exists=<optimized out>)
|
at /usr/obj/ports/mariadb-12.3.3/mariadb-12.3.3/sql/sql_table.cc:12290
|
#14 0x00000755b4286bb7 in Sql_cmd_alter_table::execute (
|
this=<optimized out>, thd=0x7580c501020)
|
at /usr/obj/ports/mariadb-12.3.3/mariadb-12.3.3/sql/sql_alter.cc:705
|
#15 0x00000755b4119f90 in mysql_execute_command (
|
thd=0x7580c501020,
|
is_called_from_prepared_stmt=<optimized out>)
|
at /usr/obj/ports/mariadb-12.3.3/mariadb-12.3.3/sql/sql_parse.cc:5895
|
#16 0x00000755b4113ea1 in mysql_parse (thd=0x7580c501020,
|
rawbuf=<optimized out>, length=<optimized out>,
|
parser_state=<optimized out>)
|
at /usr/obj/ports/mariadb-12.3.3/mariadb-12.3.3/sql/sql_parse.cc:7932
|
#17 0x00000755b41125dd in dispatch_command (
|
command=COM_QUERY, thd=0x7580c501020,
|
packet=<optimized out>, packet_length=123,
|
blocking=<optimized out>)
|
at /usr/obj/ports/mariadb-12.3.3/mariadb-12.3.3/sql/sql_parse.cc:1903
|
#18 0x00000755b4114386 in do_command (thd=0x7580c501020,
|
blocking=<optimized out>)
|
at /usr/obj/ports/mariadb-12.3.3/mariadb-12.3.3/sql/sql_parse.cc:1437
|
#19 0x00000755b427ec2d in do_handle_one_connection (
|
connect=<optimized out>, put_in_cache=<optimized out>)
|
at /usr/obj/ports/mariadb-12.3.3/mariadb-12.3.3/sql/sql_connect.cc:1514
|
#20 0x00000755b427ea55 in handle_one_connection (
|
arg=0x7588ad216b0)
|
at /usr/obj/ports/mariadb-12.3.3/mariadb-12.3.3/sql/sql_connect.cc:1426
|
#21 0x00000755b4440b82 in pfs_spawn_thread (
|
arg=0x7586bb39320)
|
at /usr/obj/ports/mariadb-12.3.3/mariadb-12.3.3/storage/perfschema/pfs.cc:2198
|
#22 0x000007589e168c52 in _rthread_start (v=0x0)
|
at /usr/src/lib/librthread/rthread.c:99
|
#23 0x000007589fbfd82a in __tfork_thread ()
|
at /usr/src/lib/libc/arch/amd64/sys/tfork_thread.S:87
|
(gdb) frame 8
|
#8 0x00000755b4529f4f in dict_table_rename_in_cache (
|
table=0x757f4026378, new_name=...,
|
replace_new_file=<optimized out>)
|
at /usr/obj/ports/mariadb-12.3.3/mariadb-12.3.3/storage/innobase/dict/dict0dict.cc:1631
|
1631 snprintf(id, fklen, "%s\377%s", table->name.m_name, sql_id);
|
(gdb) list
|
1626 id = static_cast<char*>(
|
1627 mem_heap_alloc(foreign->heap, fklen));
|
1628 }
|
1629 table->foreign_set.erase(it);
|
1630 foreign->id = id;
|
1631 snprintf(id, fklen, "%s\377%s", table->name.m_name, sql_id);
|
1632 fk_set.insert(foreign);
|
1633
|
1634 if (foreign->referenced_table) {
|
1635 foreign->referenced_table->referenced_set.insert(foreign);
|
(gdb) p id
|
$1 = 0x7589c9580f8 "dbix_class_schema_loader_test/loader_test6\377f7-9-1\377loader_test6_to_7_fk"
|
(gdb) p table->name.m_name
|
$2 = 0x758396764c8 "dbix_class_schema_loader_test/loader_test6"
|
(gdb) p fklen
|
$3 = 64
|
(gdb) p sql_id
|
$4 = 0x7589c95812a "loader_test6_to_7_fk"
|
|
|
$ moo
|
0x7589c9580f8 + 64
|
0x7589c958138
|
8077165560120
|
The database cluster will be initialized with locale "C".
The default text search configuration will be set to "english".
Data page checksums are enabled.
creating directory /usr/ports/pobj/p5-DBIx-Class-Schema-Loader-0.07053/testdb-pg ... ok
|
creating subdirectories ... ok
|
selecting dynamic shared memory implementation ... posix
|
selecting default "max_connections" ... 100
|
selecting default "shared_buffers" ... 128MB
|
selecting default time zone ... US/Pacific
|
creating configuration files ... ok
|
running bootstrap script ... ok
|
performing post-bootstrap initialization ... ok
|
|
|
Sync to disk skipped.
|
The data directory might become corrupt if the operating system crashes.
|
|
|
Success. You can now start the database server using:
|
|
|
/usr/local/bin/pg_ctl -D /usr/ports/pobj/p5-DBIx-Class-Schema-Loader-0.07053/testdb-pg -l logfile start
|
|
|
waiting for server to start.... done
|
server started
|
WARNING: The host 'zarniwoop.home.hewus.com' could not be looked up with /usr/local/bin/resolveip.
|
This probably means that your libc libraries are not 100 % compatible
|
with this binary MariaDB version. The MariaDB daemon, mariadbd, should work
|
normally with the exception that host name resolving will not work.
|
This means that you should use IP addresses instead of hostnames
|
when specifying MariaDB privileges !
|
Installing MariaDB/MySQL system tables in '/usr/ports/pobj/p5-DBIx-Class-Schema-Loader-0.07053/testdb-mariadb' ...
|
OK
|
|
|
|
|
Two all-privilege accounts were created.
|
One is root@localhost, it has no password, but you need to
|
be system 'root' user to connect. Use, for example, sudo mariadb
|
The second is _mysql@localhost, it has no password either, but
|
you need to be the system '_mysql' user to connect.
|
After connecting you can set the password, if you would need to be
|
able to connect as any of these users with a password and without sudo
|
|
|
See the MariaDB Documentation at https://mariadb.com/docs
|
|
|
You can start the MariaDB daemon with:
|
/etc/rc.d/mysqld start
|
|
|
Please report any problems at https://mariadb.org/jira
|
|
|
The latest information about MariaDB is available at https://mariadb.org/.
|
|
|
Consider joining MariaDB's strong and vibrant community:
|
https://mariadb.org/get-involved/
|
|
|
2026-09-19 8:36:49 0 [Warning] Could not increase number of max_open_files to more than 512 (request: 32198)
|
2026-09-19 8:36:49 0 [Warning] Changed limits: max_open_files: 512 max_connections: 82 (was 151) table_cache: 200 (was 2000)
|
2026-09-19 8:36:49 0 [Note] Starting MariaDB 12.3.3-MariaDB source revision 83e909fc2a0dbc394b4b683fb3fa2d7dcf26cc5e server_uid SaqNyNIEJAP7SLoNj81ADSn8f6c= as process 41336
|
2026-09-19 8:36:50 0 [Note] InnoDB: Compressed tables use zlib 1.3.2
|
2026-09-19 8:36:50 0 [Note] InnoDB: Number of transaction pools: 1
|
2026-09-19 8:36:50 0 [Note] InnoDB: Using generic crc32 instructions
|
2026-09-19 8:36:50 0 [Note] InnoDB: innodb_buffer_pool_size_max=515m, innodb_buffer_pool_size=128m
|
2026-09-19 8:36:50 0 [Note] InnoDB: Completed initialization of buffer pool
|
2026-09-19 8:36:50 0 [Note] InnoDB: End of log at LSN=45568
|
2026-09-19 8:36:50 0 [Note] InnoDB: Opened 3 undo tablespaces
|
2026-09-19 8:36:50 0 [Note] InnoDB: 128 rollback segments in 3 undo tablespaces are active.
|
2026-09-19 8:36:50 0 [Note] InnoDB: Setting file './ibtmp1' size to 12.000MiB. Physically writing the file full; Please wait ...
|
2026-09-19 8:36:50 0 [Note] InnoDB: File './ibtmp1' size is now 12.000MiB.
|
2026-09-19 8:36:50 0 [Note] InnoDB: log sequence number 45568; transaction id 14
|
2026-09-19 8:36:50 0 [Note] Plugin 'FEEDBACK' is disabled.
|
2026-09-19 8:36:50 0 [Note] InnoDB: Loading buffer pool(s) from /usr/ports/pobj/p5-DBIx-Class-Schema-Loader-0.07053/testdb-mariadb/ib_buffer_pool
|
2026-09-19 8:36:50 0 [Note] Plugin 'wsrep-provider' is disabled.
|
2026-09-19 8:36:50 0 [Note] InnoDB: Buffer pool(s) load completed at 260919 8:36:50
|
2026-09-19 8:37:13 0 [Note] /usr/local/libexec/mariadbd: ready for connections.
|
Version: '12.3.3-MariaDB' socket: '/usr/ports/pobj/p5-DBIx-Class-Schema-Loader-0.07053/mariadb.sock' port: 0 OpenBSD port: mariadb-server-12.3.3v1
|
PERL_DL_NONLAZY=1 "/usr/bin/perl" "-MExtUtils::Command::MM" "-MTest::Harness" "-e" "undef *Test::Harness::Switches; test_harness(0, 'blib/lib', 'blib/arch')" t/*.t t/*/*.t t/*/*/*.t
|
t/01use.t ............................... ok
|
t/10_01sqlite_common.t .................. ok
|
260919 8:38:17 [ERROR] /usr/local/libexec/mariadbd got signal 6 ;
|
Sorry, we probably made a mistake, and this is a bug.
|
|
|
Your assistance in bug reporting will enable us to fix this for the next release.
|
To report this bug, see https://mariadb.com/docs/general-resources/community/community/bug-tracking/reporting-bugs about how to report
|
a bug on https://jira.mariadb.org/.
|
|
|
Please include the information from the server start above, to the end of the
|
information below.
|
|
|
Server version: 12.3.3-MariaDB source revision: 83e909fc2a0dbc394b4b683fb3fa2d7dcf26cc5e
|
|
|
The information page at https://mariadb.com/docs/server/reference/product-development/mariadb-fault-finding/how-to-produce-a-full-stack-trace-for-mariadbdcontains instructions to obtain a better version of the backtrace below.
|
Following these instructions will help MariaDB developers provide a fix quicker.
|
|
|
Attempting backtrace. Include this in the bug report.
|
(note: Retrieving this information may fail)
|
|
|
Thread pointer: 0x7d0c92e020
|
stack_bottom = 0x7d0b92fea1 thread_stack 0x49000
|
0x7ab8f3cae0 <my_print_stacktrace+0x40> at /usr/local/libexec/mariadbd
|
|
|
Connection ID (thread ID): 9
|
Status: NOT_KILLED
|
Query (0x7d78fe0040): ALTER TABLE loader_test6 ADD CONSTRAINT loader_test6_to_7_fk FOREIGN KEY (loader_test7_id) REFERENCES loader_test7 (id)
|
|
|
Optimizer switch: index_merge=on,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on,index_merge_sort_intersection=off,index_condition_pushdown=on,derived_merge=on,derived_with_keys=on,firstmatch=on,loosescan=on,duplicateweedout=on,materialization=on,in_to_exists=on,semijoin=on,partial_match_rowid_merge=on,partial_match_table_scan=on,subquery_cache=on,mrr=off,mrr_cost_based=off,mrr_sort_keys=off,outer_join_with_cache=on,semijoin_with_cache=on,join_cache_incremental=on,join_cache_hashed=on,join_cache_bka=on,optimize_join_buffer_size=on,table_elimination=on,extended_keys=on,exists_to_in=on,orderby_uses_equalities=on,condition_pushdown_for_derived=on,split_materialized=on,condition_pushdown_for_subquery=on,rowid_filter=on,condition_pushdown_from_having=on,not_null_range_scan=off,hash_join_cardinality=on,cset_narrowing=on,sargable_casefold=on,reorder_outer_joins=off
|
|
|
Error executing ' ALTER TABLE loader_test6 ADD CONSTRAINT loader_test6_to_7_fk FOREIGN KEY (loader_test7_id) REFERENCES loader_test7 (id) ': DBD::mysql::db do failed: Lost connection to server during query [for Statement " ALTER TABLE loader_test6 ADD CONSTRAINT loader_test6_to_7_fk FOREIGN KEY (loader_test7_id) REFERENCES loader_test7 (id) "] at t/lib/dbixcsl_common_tests.pm line 2146.
|
|
|
(in cleanup) DBIx::Class::Storage::DBI::catch {...} (): DBI Connection failed: Can't connect to local server through socket '/usr/ports/pobj/p5-DBIx-Class-Schema-Loader-0.07053/mariadb.sock' (61) at /usr/local/libdata/perl5/site_perl/DBIx/Class/Storage/DBI.pm line 1642. at t/lib/dbixcsl_common_tests.pm line 1544
|
# Looks like your test exited with 35 before it could output anything.
|
t/10_02mysql_common.t ...................
|
Dubious, test returned 35 (wstat 8960, 0x2300)
|
Failed 380/380 subtests
|
t/10_03pg_common.t ...................... ok
|
t/10_04db2_common.t ..................... skipped: requirements not satisfied: DBD::DB2 as well as the following group(s) of environment variables: DBICTEST_DB2_DSN/..._USER/..._PASS
|
t/10_05ora_common.t ..................... skipped: requirements not satisfied: DBD::Oracle~1.24 Math::Base36~0.07 as well as the following group(s) of environment variables: DBICTEST_ORA_DSN/..._USER/..._PASS
|
t/10_06sybase_common.t .................. skipped: requirements not satisfied: DBD::Sybase as well as the following group(s) of environment variables: DBICTEST_SYBASE_DSN/..._USER/..._PASS
|
t/10_07mssql_common.t ................... skipped: You need to set the DBICTEST_MSSQL_DSN, _USER and _PASS and/or the DBICTEST_MSSQL_ODBC_DSN, _USER and _PASS environment variables
|
t/10_08sqlanywhere_common.t ............. skipped: You need to set the DBICTEST_SQLANYWHERE_DSN, _USER and _PASS and/or the DBICTEST_SQLANYWHERE_ODBC_DSN, _USER and _PASS environment variables
|
t/10_09firebird_common.t ................ skipped: You need to set the DBICTEST_FIREBIRD_DSN, _USER and _PASS and/or the DBICTEST_FIREBIRD_ODBC_DSN, _USER and _PASS and/or the DBICTEST_FIREBIRD_INTERBASE_DSN, _USER and _PASS environment variables
|
t/10_10informix_common.t ................ skipped: requirements not satisfied: DBD::Informix as well as the following group(s) of environment variables: DBICTEST_INFORMIX_DSN/..._USER/..._PASS
|
t/10_11msaccess_common.t ................ skipped: You need to set the DBICTEST_MSACCESS_ODBC_DSN, _USER and _PASS and/or the DBICTEST_MSACCESS_ADO_DSN, _USER and _PASS environment variables
|
t/20invocations.t ....................... ok
|
t/21misc_fatal.t ........................ ok
|
t/22dump.t .............................. ok
|
t/23dumpmore.t .......................... ok
|
t/24loader_subclass.t ................... ok
|
t/25backcompat.t ........................ ok
|
t/26dump_use_moose.t .................... skipped: requirements not satisfied: Moose~1.12 MooseX::MarkAsMethods~0.13 MooseX::NonMoose~0.25 namespace::autoclean~0.09 (see DBIx::Class::Schema::Loader::Optional::Dependencies documentation for details)
|
t/27filter_generated.t .................. ok
|
t/30_01comments.t ....................... ok
|
t/30_02bad_comment_table.t .............. ok
|
t/30_03no_comment_table.t ............... ok
|
t/40overwrite_modifications.t ........... ok
|
t/45relationships.t ..................... ok
|
t/46relationships_multi_m2m.t ........... ok
|
t/50rt59849.t ........................... ok
|
t/60dbicdump_config.t ................... skipped: requirements not satisfied: Config::General (see DBIx::Class::Schema::Loader::Optional::Dependencies documentation for details)
|
t/65dbicdump_invocations.t .............. ok
|
t/70schema_base_dispatched.t ............ ok
|
t/80split_name.t ........................ ok
|
t/90bug_58_mro.t ........................ skipped: perl 5.8 required for this test
|
t/backcompat/0.04006/10sqlite_common.t .. ok
|
Failed to connect to database: Can't connect to local server through socket '/usr/ports/pobj/p5-DBIx-Class-Schema-Loader-0.07053/mariadb.sock' (61) at t/backcompat/0.04006/lib/dbixcsl_common_tests.pm line 558.
|
(in cleanup) Failed to connect to database: Can't connect to local server through socket '/usr/ports/pobj/p5-DBIx-Class-Schema-Loader-0.07053/mariadb.sock' (61) at t/backcompat/0.04006/lib/dbixcsl_common_tests.pm line 558.
|
# Looks like your test exited with 255 before it could output anything.
|
t/backcompat/0.04006/11mysql_common.t ...
|
Dubious, test returned 255 (wstat 65280, 0xff00)
|
Failed 97/97 subtests
|
t/backcompat/0.04006/12pg_common.t ...... ok
|
t/backcompat/0.04006/13db2_common.t ..... skipped: requirements not satisfied: DBD::DB2 as well as the following group(s) of environment variables: DBICTEST_DB2_DSN/..._USER/..._PASS
|
t/backcompat/0.04006/14ora_common.t ..... skipped: requirements not satisfied: DBD::Oracle~1.24 Math::Base36~0.07 as well as the following group(s) of environment variables: DBICTEST_ORA_DSN/..._USER/..._PASS
|
t/backcompat/0.04006/20invocations.t .... ok
|
t/backcompat/0.04006/21misc_fatal.t ..... ok
|
t/backcompat/0.04006/22dump.t ........... ok
|
t/backcompat/0.04006/23dumpmore.t ....... ok
|
|
|
Test Summary Report
|
-------------------
|
t/10_01sqlite_common.t (Wstat: 0 Tests: 283 Failed: 0)
|
TODO passed: 283
|
t/10_02mysql_common.t (Wstat: 8960 (exited 35) Tests: 0 Failed: 0)
|
Non-zero exit status: 35
|
Parse errors: Bad plan. You planned 380 tests but ran 0.
|
t/backcompat/0.04006/11mysql_common.t (Wstat: 65280 (exited 255) Tests: 0 Failed: 0)
|
Non-zero exit status: 255
|
Parse errors: Bad plan. You planned 97 tests but ran 0.
|
Files=41, Tests=2052, 544 wallclock secs ( 1.73 usr 1.06 sys + 338.46 cusr 63.09 csys = 404.34 CPU)
|
Result: FAIL
|
Failed 2/41 test programs. 0/2052 subtests failed.
|
*** Error 255 in /usr/ports/pobj/p5-DBIx-Class-Schema-Loader-0.07053/DBIx-Class-Schema-Loader-0.07053 (Makefile:1120 'test_dynamic')
|
/bin/sh: kill: 41336: No such process
|
waiting for server to shut down.... done
|
server stopped
|
*** Error 2 in . (Makefile:60 'do-test')
|
Attachments
Issue Links
- is caused by
-
MDEV-28933 Per-table unique FOREIGN KEY constraint names
-
- Closed
-