Description:
Version: '5.7.10-debug' socket: '/dev/shm/1453361979/socket.sock' port: 39846 MySQL Community Server (GPL)
mysqld: /sda/mysql-server_dbg/sql/field.cc:1615: type_conversion_status Field::check_constraints(int): Assertion `type() != MYSQL_TYPE_TIMESTAMP' failed.
09:36:10 UTC - mysqld got signal 6 ;
#0 0x00007f20d753d741 in pthread_kill () from /lib64/libpthread.so.0
#1 0x00000000017ef51c in my_write_core (sig=6) at /sda/mysql-server_dbg/mysys/stacktrace.c:247
#2 0x0000000000e583e4 in handle_fatal_signal (sig=6) at /sda/mysql-server_dbg/sql/signal_handler.cc:220
#3 <signal handler called>
#4 0x00007f20d56ca5f7 in raise () from /lib64/libc.so.6
#5 0x00007f20d56cbce8 in abort () from /lib64/libc.so.6
#6 0x00007f20d56c3566 in __assert_fail_base () from /lib64/libc.so.6
#7 0x00007f20d56c3612 in __assert_fail () from /lib64/libc.so.6
#8 0x0000000000e95b21 in Field::check_constraints (this=0x7f209a4aa340, mysql_errno=1048) at /sda/mysql-server_dbg/sql/field.cc:1615
#9 0x000000000146ba7b in check_record (thd=0x7f209a419000, ptr=0x7f209a4aa338) at /sda/mysql-server_dbg/sql/sql_base.cc:9246
#10 0x000000000146c23a in fill_record_n_invoke_before_triggers (thd=0x7f209a419000, ptr=0x7f209a4aa330, values=..., table=0x7f209a45c420, event=TRG_EVENT_INSERT, num_fields=1) at /sda/mysql-server_dbg/sql/sql_base.cc:9543
#11 0x00000000016e2200 in Sql_cmd_insert::mysql_insert (this=0x7f209a42c3d8, thd=0x7f209a419000, table_list=0x7f209a42be48) at /sda/mysql-server_dbg/sql/sql_insert.cc:762
#12 0x00000000016e88f6 in Sql_cmd_insert::execute (this=0x7f209a42c3d8, thd=0x7f209a419000) at /sda/mysql-server_dbg/sql/sql_insert.cc:3082
#13 0x00000000014e5b7f in mysql_execute_command (thd=0x7f209a419000, first_level=true) at /sda/mysql-server_dbg/sql/sql_parse.cc:3510
#14 0x00000000014eb3dd in mysql_parse (thd=0x7f209a419000, parser_state=0x7f20d7af3560) at /sda/mysql-server_dbg/sql/sql_parse.cc:5508
#15 0x00000000014e0d17 in dispatch_command (thd=0x7f209a419000, com_data=0x7f20d7af3cb0, command=COM_QUERY) at /sda/mysql-server_dbg/sql/sql_parse.cc:1425
#16 0x00000000014dfbe1 in do_command (thd=0x7f209a419000) at /sda/mysql-server_dbg/sql/sql_parse.cc:993
#17 0x000000000160adc7 in handle_connection (arg=0x7f20c4bfce00) at /sda/mysql-server_dbg/sql/conn_handler/connection_handler_per_thread.cc:301
#18 0x000000000188e1b8 in pfs_spawn_thread (arg=0x7f20b4fef120) at /sda/mysql-server_dbg/storage/perfschema/pfs.cc:2192
#19 0x00007f20d7538dc5 in start_thread () from /lib64/libpthread.so.0
#20 0x00007f20d578b21d in clone () from /lib64/libc.so.6
How to repeat:
Testcase
DROP DATABASE test;CREATE DATABASE test;USE test;
set session explicit_defaults_for_timestamp=true;
CREATE TABLE t1(a TIMESTAMP NOT NULL);
CREATE TRIGGER t1_au AFTER UPDATE ON t1 FOR EACH ROW SET @x=5/0;
create temporary TABLE t1(f int);
DROP TABLE t1;
insert INTO t1 values(null),(null),(null),(null);
The attached tarball (1453361979_bug_bundle.tar.gz) gives the testcase as an exact match of our system, including some handy utilities
$ vi 1453361979_mybase # STEP1: Update the base path in this file (usually the only change required!). If you use a non-binary distribution, please update SOURCE_DIR location also
$ ./1453361979_init # STEP2: Initializes the data dir
$ ./1453361979_start # STEP3: Starts mysqld
$ ./1453361979_cl # STEP4: To check mysqld is up
$ ./1453361979_run_pquery # STEP5: Run the testcase with the pquery binary
$ ./1453361979_run # OPTIONAL: Run the testcase with the mysql CLI (may not reproduce the issue, as the pquery binary was used for the original testcase reduction)
$ vi /dev/shm/1453361979/error.log.out # STEP6: Verify the error log
$ ./1453361979_gdb # OPTIONAL: Brings you to a gdb prompt with gdb attached to the used mysqld and attached to the generated core
$ ./1453361979_parse_core # STEP7: Creates 1453361979_STD.gdb and 1453361979_FULL.gdb; standard and full variables gdb stack traces