Bug #77520 handle_fatal_signal (sig11) at ha_check_and_coalesce_trx_read_only in handler.cc

Submitted: 28 Jun 2015 23:07 Modified: 29 Jun 2015 9:27
Reporter: Roel Van de Paar Email Updates:
Status: Can't repeat Impact on me:
None 
Category:MySQL Server: Replication Severity:S1 (Critical)
Version:5.7.7 RC OS:Any
Assigned to: CPU Architecture:Any

[28 Jun 2015 23:07] Roel Van de Paar
Description:
+bt
#0  0x00007fbb747d4771 in __pthread_kill (threadid=<optimized out>, signo=11) at ../nptl/sysdeps/unix/sysv/linux/pthread_kill.c:61
#1  0x0000000000737304 in handle_fatal_signal (sig=11) at /export/home/pb2/build/sb_0-14853600-1427719770.96/mysql-5.7.7-rc/sql/signal_handler.cc:220
#2  <signal handler called>
#3  ha_check_and_coalesce_trx_read_only (all=<optimized out>, ha_list=<optimized out>, thd=<optimized out>) at /export/home/pb2/build/sb_0-14853600-1427719770.96/mysql-5.7.7-rc/sql/handler.cc:1448
#4  ha_commit_trans (thd=0x7fbadac18000, all=false, ignore_global_read_lock=false) at /export/home/pb2/build/sb_0-14853600-1427719770.96/mysql-5.7.7-rc/sql/handler.cc:1564
#5  0x0000000000d3514e in trans_commit_stmt (thd=0x0) at /export/home/pb2/build/sb_0-14853600-1427719770.96/mysql-5.7.7-rc/sql/transaction.cc:395
#6  0x0000000000c86c2c in mysql_execute_command (thd=0x7fbadac18000) at /export/home/pb2/build/sb_0-14853600-1427719770.96/mysql-5.7.7-rc/sql/sql_parse.cc:4591
#7  0x0000000000c89010 in mysql_parse (thd=0x7fbadac18000, parser_state=<optimized out>) at /export/home/pb2/build/sb_0-14853600-1427719770.96/mysql-5.7.7-rc/sql/sql_parse.cc:5159
#8  0x0000000000c8a5d8 in dispatch_command (command=COM_QUERY, thd=0x7fbadac18000, packet=<optimized out>, packet_length=<optimized out>) at /export/home/pb2/build/sb_0-14853600-1427719770.96/mysql-5.7.7-rc/sql/sql_parse.cc:1249
#9  0x0000000000d4fa14 in handle_connection (arg=<optimized out>) at /export/home/pb2/build/sb_0-14853600-1427719770.96/mysql-5.7.7-rc/sql/conn_handler/connection_handler_per_thread.cc:298
#10 0x000000000113cbda in pfs_spawn_thread (arg=<optimized out>) at /export/home/pb2/build/sb_0-14853600-1427719770.96/mysql-5.7.7-rc/storage/perfschema/pfs.cc:2147
#11 0x00007fbb747cfdf3 in start_thread (arg=0x7fbb74dcd700) at pthread_create.c:308
#12 0x00007fbb734991ad in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:113

How to repeat:
DROP DATABASE test;CREATE DATABASE test;USE test;
set global gtid_mode=OFF_PERMISSIVE;
CREATE TABLE t1(pk int key,a3 int,b3 int,c3 int,d3 CHAR (1)) ENGINE=INNODB;
SET SESSION GTID_NEXT='11111111-AAAA-2222-BBBB-111111111111:1';
explain select * FROM t1 union select * FROM t1;
[28 Jun 2015 23:14] Roel Van de Paar
May be related to bug #77521
[29 Jun 2015 9:27] MySQL Verification Team
Hello Roel,

Thank you for the report and test case.
I'm not seeing this issue on latest builds with the provided test case(release/debug and valgrind) and most likely fixed in 5.7.8.

// build

commit: 5646b91dc9980ceb88b41913304b8530a24538ab
date: 2015-06-26 15:14:51 +0200
build-date: 2015-06-26 18:02:46 +0200
short: 5646b91
branch: mysql-5.7

MySQL source 5.7.8

// release build

[umshastr@hod03]/export/umesh/server/binaries/mysql-5.7.8: bin/mysql -uroot -S /tmp/mysql_ushastry.sock
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 4
Server version: 5.7.8-rc-enterprise-commercial-advanced-log MySQL Enterprise Server - Advanced Edition (Commercial)

Copyright (c) 2000, 2015, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql>
mysql> DROP DATABASE test;CREATE DATABASE test;USE test;
set global gtid_mode=OFF_PERMISSIVE;
Query OK, 2 rows affected (0.12 sec)

Query OK, 1 row affected (0.00 sec)

Database changed
mysql> set global gtid_mode=OFF_PERMISSIVE;
Query OK, 0 rows affected (0.00 sec)

mysql> CREATE TABLE t1(pk int key,a3 int,b3 int,c3 int,d3 CHAR (1)) ENGINE=INNODB;
Query OK, 0 rows affected (0.00 sec)

mysql> SET SESSION GTID_NEXT='11111111-AAAA-2222-BBBB-111111111111:1';
Query OK, 0 rows affected (0.00 sec)

mysql> explain select * FROM t1 union select * FROM t1;
+----+--------------+------------+------------+------+---------------+------+---------+------+------+----------+-----------------+
| id | select_type  | table      | partitions | type | possible_keys | key  | key_len | ref  | rows | filtered | Extra           |
+----+--------------+------------+------------+------+---------------+------+---------+------+------+----------+-----------------+
|  1 | PRIMARY      | t1         | NULL       | ALL  | NULL          | NULL | NULL    | NULL |    1 |   100.00 | NULL            |
|  2 | UNION        | t1         | NULL       | ALL  | NULL          | NULL | NULL    | NULL |    1 |   100.00 | NULL            |
| NULL | UNION RESULT | <union1,2> | NULL       | ALL  | NULL          | NULL | NULL    | NULL | NULL |     NULL | Using temporary |
+----+--------------+------------+------------+------+---------------+------+---------+------+------+----------+-----------------+
3 rows in set, 1 warning (0.00 sec)

## debug builds

[umshastr@hod03]/export/umesh/server/binaries/mysql-5.7.8: bin/mysql -uroot -S /tmp/mysql_ushastry.sock
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 3
Server version: 5.7.8-rc-enterprise-commercial-advanced-debug-log MySQL Enterprise Server - Advanced Edition Debug (Commercial)

Copyright (c) 2000, 2015, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql> DROP DATABASE test;CREATE DATABASE test;USE test;
set global gtid_mode=OFF_PERMISSIVE;
Query OK, 1 row affected (0.01 sec)

Query OK, 1 row affected (0.00 sec)

Database changed
mysql> set global gtid_mode=OFF_PERMISSIVE;
Query OK, 0 rows affected (0.00 sec)

mysql> CREATE TABLE t1(pk int key,a3 int,b3 int,c3 int,d3 CHAR (1)) ENGINE=INNODB;
Query OK, 0 rows affected (0.00 sec)

mysql> SET SESSION GTID_NEXT='11111111-AAAA-2222-BBBB-111111111111:1';
Query OK, 0 rows affected (0.00 sec)

mysql> explain select * FROM t1 union select * FROM t1;
+----+--------------+------------+------------+------+---------------+------+---------+------+------+----------+-----------------+
| id | select_type  | table      | partitions | type | possible_keys | key  | key_len | ref  | rows | filtered | Extra           |
+----+--------------+------------+------------+------+---------------+------+---------+------+------+----------+-----------------+
|  1 | PRIMARY      | t1         | NULL       | ALL  | NULL          | NULL | NULL    | NULL |    1 |   100.00 | NULL            |
|  2 | UNION        | t1         | NULL       | ALL  | NULL          | NULL | NULL    | NULL |    1 |   100.00 | NULL            |
| NULL | UNION RESULT | <union1,2> | NULL       | ALL  | NULL          | NULL | NULL    | NULL | NULL |     NULL | Using temporary |
+----+--------------+------------+------------+------+---------------+------+---------+------+------+----------+-----------------+
3 rows in set, 1 warning (0.01 sec)

mysql>

Thanks,
Umesh

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

Page generated in 0.052 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.