Bug #118106 Assertion failure

Submitted: 2 May 2025 12:13 Modified: 5 May 2025 11:30
Reporter: Kieran Brahney Email Updates:
Status: Can't repeat Impact on me:
None 
Category:MySQL Server Severity:S1 (Critical)
Version:8.0.41 OS:Ubuntu
Assigned to: MySQL Verification Team CPU Architecture:Any

[2 May 2025 12:13] Kieran Brahney
Description:
MySQL is randomly crashing when creating a new table containing a foreign key. Oddly, the same query worked after MySQL came back online...

MySQL is installed via ubuntu package repositories: 8.0.41-0ubuntu0.20.04.1

2025-05-02T10:27:53.643184Z 19 [ERROR] [MY-013183] [InnoDB] Assertion failure: dict0dict.cc:3525:ret.second thread 140351614412544
InnoDB: We intentionally generate a memory trap.
InnoDB: Submit a detailed bug report to http://bugs.mysql.com.
InnoDB: If you get repeated assertion failures or crashes, even
InnoDB: immediately after the mysqld startup, there may be
InnoDB: corruption in the InnoDB tablespace. Please refer to
InnoDB: http://dev.mysql.com/doc/refman/8.0/en/forcing-innodb-recovery.html
InnoDB: about forcing recovery.
2025-05-02T10:27:53Z UTC - mysqld got signal 6 ;
Most likely, you have hit a bug, but this error can also be caused by malfunctioning hardware.
BuildID[sha1]=14c72e6e8d1dc19793482c6ddaa14e7ac076937a
Thread pointer: 0x7fa5b0000b60
Attempting backtrace. You can use the following information to find out
where mysqld died. If you see no messages after this, something went
terribly wrong...
stack_bottom = 7fa6281edc10 thread_stack 0x100000
/usr/sbin/mysqld(my_print_stacktrace(unsigned char const*, unsigned long)+0x41) [0x556e59446951]
/usr/sbin/mysqld(print_fatal_signal(int)+0x39b) [0x556e582b258b]
/usr/sbin/mysqld(my_server_abort()+0x76) [0x556e582b26d6]
/usr/sbin/mysqld(my_abort()+0xe) [0x556e594408ce]
/usr/sbin/mysqld(ut_dbg_assertion_failed(char const*, char const*, unsigned long)+0x349) [0x556e596e9829]
/usr/sbin/mysqld(dict_foreign_add_to_cache(dict_foreign_t*, char const**, bool, bool, dict_err_ignore_t)+0x425) [0x556e597fb9d5]
/usr/sbin/mysqld(dd_table_check_for_child(dd::cache::Dictionary_client*, char const*, char const**, dict_table_t*, bool, dict_err_ignore_t, std::deque > >*)+0xd3e) [0x556e598250ae]
/usr/sbin/mysqld(dict_table_t* dd_open_table_one(dd::cache::Dictionary_client*, TABLE const*, char const*, dd::Table const*, THD*, std::deque > >&)+0x25f8) [0x556e59827c48]
/usr/sbin/mysqld(+0x270514e) [0x556e5982914e]
/usr/sbin/mysqld(dd_open_fk_tables(std::deque > >&, bool, THD*)+0x53) [0x556e598292e3]
/usr/sbin/mysqld(dict_table_t* dd_open_table(dd::cache::Dictionary_client*, TABLE const*, char const*, dd::Table const*, THD*)+0xe4) [0x556e59829484]
/usr/sbin/mysqld(ha_innobase::open(char const*, int, unsigned int, dd::Table const*)+0x14fb) [0x556e594a403b]
/usr/sbin/mysqld(handler::ha_open(TABLE*, char const*, int, int, dd::Table const*)+0x59) [0x556e583c4179]
/usr/sbin/mysqld(open_table_from_share(THD*, TABLE_SHARE*, char const*, unsigned int, unsigned int, unsigned int, TABLE*, bool, dd::Table const*)+0x1165) [0x556e5825c1c5]
/usr/sbin/mysqld(open_table(THD*, Table_ref*, Open_table_context*)+0x121f) [0x556e5809dbff]
/usr/sbin/mysqld(open_tables(THD*, Table_ref**, unsigned int*, unsigned int, Prelocking_strategy*)+0x3cf) [0x556e5809f52f]
/usr/sbin/mysqld(open_tables_for_query(THD*, Table_ref*, unsigned int)+0x93) [0x556e580a0933]
/usr/sbin/mysqld(Sql_cmd_dml::prepare(THD*)+0x104) [0x556e5819cac4]
/usr/sbin/mysqld(Prepared_statement::prepare_query(THD*)+0x150) [0x556e58175810]
/usr/sbin/mysqld(Prepared_statement::prepare(THD*, char const*, unsigned long, Item_param**)+0x835) [0x556e58176845]
/usr/sbin/mysqld(mysqld_stmt_prepare(THD*, char const*, unsigned int, Prepared_statement*)+0x98) [0x556e58177038]
/usr/sbin/mysqld(dispatch_command(THD*, COM_DATA const*, enum_server_command)+0x2426) [0x556e58149476]
/usr/sbin/mysqld(do_command(THD*)+0x226) [0x556e5814a2d6]
/usr/sbin/mysqld(+0x117f1b8) [0x556e582a31b8]
/usr/sbin/mysqld(+0x28c029d) [0x556e599e429d]
/lib/x86_64-linux-gnu/libpthread.so.0(+0x8609) [0x7fa642429609]
/lib/x86_64-linux-gnu/libc.so.6(clone+0x43) [0x7fa641ffa163]

Trying to get some variables.
Some pointers may be invalid and cause the dump to abort.
Query (7fa5b0012b20): select * from `language`
Connection ID (thread ID): 19
Status: NOT_KILLED

The manual page at http://dev.mysql.com/doc/mysql/en/crashing.html contains
information that should help you find out what is causing the crash.

How to repeat:
Unclear
[5 May 2025 11:30] MySQL Verification Team
Hi,

I cannot reproduce this. I would suggest you rebuild tables in question (ALTER TABLE t1 ENGINE = InnoDB;) to see if that helps.

Portions of this website are copyright © 2001, 2002 The PHP Group

Page generated in 0.049 sec. using MySQL 8.4.7-u6-cloud

Timestamp references displayed by the system are UTC.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.