abort in ha_partition::end_bulk_insert | sql/ha_partition.cc:4438: virtual int ha_partition::end_bulk_insert(): Assertion `0' failed. (sig6)

Bug #1204871 reported by Roel Van de Paar on 2013-07-25
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
MySQL Server
Unknown
Unknown
Percona Server
Status tracked in 5.6
5.1
Undecided
Laurynas Biveinis
5.5
Undecided
Laurynas Biveinis
5.6
High
Laurynas Biveinis

Bug Description

Thread 4 (LWP 18362):
+bt
#0 0x000000340cc0c69c in pthread_kill () from /lib64/libpthread.so.0
#1 0x00000000006ecc9d in handle_fatal_signal (sig=6) at /bzr/5.6_val/Percona-Server-5.6.12-rc60.4/sql/signal_handler.cc:251
#2 <signal handler called>
#3 0x000000340c4328a5 in raise () from /lib64/libc.so.6
#4 0x000000340c434085 in abort () from /lib64/libc.so.6
#5 0x000000340c42ba1e in __assert_fail_base () from /lib64/libc.so.6
#6 0x000000340c42bae0 in __assert_fail () from /lib64/libc.so.6
#7 0x0000000000c3c5dc in ha_partition::end_bulk_insert (this=0x19b2c3a0) at /bzr/5.6_val/Percona-Server-5.6.12-rc60.4/sql/ha_partition.cc:4438
#8 0x000000000063b717 in handler::ha_end_bulk_insert (this=0x19b2c3a0) at /bzr/5.6_val/Percona-Server-5.6.12-rc60.4/sql/handler.cc:4148
#9 0x000000000075b119 in select_insert::abort_result_set (this=0x217b5d20) at /bzr/5.6_val/Percona-Server-5.6.12-rc60.4/sql/sql_insert.cc:3837
#10 0x00000000007a0005 in handle_select (thd=0x20362340, result=0x217b5d20, setup_tables_done_option=1073741824) at /bzr/5.6_val/Percona-Server-5.6.12-rc60.4/sql/sql_select.cc:117
#11 0x000000000077b283 in mysql_execute_command (thd=0x20362428) at /bzr/5.6_val/Percona-Server-5.6.12-rc60.4/sql/sql_parse.cc:3727
#12 0x000000000077bc88 in mysql_parse (thd=0x20362340, rawbuf=0x20362348 "\340cA\001", length=<optimized out>, parser_state=<optimized out>) at /bzr/5.6_val/Percona-Server-5.6.12-rc60.4/sql/sql_parse.cc:6477
#13 0x000000000077c81f in dispatch_command (command=<optimized out>, thd=0x20362340, packet=<optimized out>, packet_length=561729512) at /bzr/5.6_val/Percona-Server-5.6.12-rc60.4/sql/sql_parse.cc:1374
#14 0x000000000077d4f5 in do_command (thd=0x20362340) at /bzr/5.6_val/Percona-Server-5.6.12-rc60.4/sql/sql_parse.cc:1049
#15 0x0000000000746ecf in do_handle_one_connection (thd_arg=<optimized out>) at /bzr/5.6_val/Percona-Server-5.6.12-rc60.4/sql/sql_connect.cc:1615
#16 0x0000000000746f90 in handle_one_connection (arg=<optimized out>) at /bzr/5.6_val/Percona-Server-5.6.12-rc60.4/sql/sql_connect.cc:1526
#17 0x00000000009e4ce9 in pfs_spawn_thread (arg=0x198d5c60) at /bzr/5.6_val/Percona-Server-5.6.12-rc60.4/storage/perfschema/pfs.cc:1855
#18 0x000000340cc07851 in start_thread () from /lib64/libpthread.so.0
#19 0x000000340c4e890d in clone () from /lib64/libc.so.6

2013-07-20 15:52:08 17093 [Warning] Warning: Enabling keys got errno 137 on query018293.t1, retrying
2013-07-20 15:52:08 17093 [Warning] Warning: Enabling keys got errno 137 on query018293.t1, retrying
2013-07-20 15:52:08 17093 [Warning] Warning: Enabling keys got errno 137 on query018293.t1, retrying
2013-07-20 15:52:08 17093 [Warning] Warning: Enabling keys got errno 137 on query018293.t1, retrying
2013-07-20 15:52:08 17093 [Warning] Warning: Enabling keys got errno 137 on query018293.t1, retrying
2013-07-20 15:52:08 17093 [Warning] Warning: Enabling keys got errno 137 on query018293.t1, retrying
2013-07-20 15:52:08 17093 [Warning] Warning: Enabling keys got errno 137 on query018293.t1, retrying
2013-07-20 15:52:08 17093 [Warning] Warning: Enabling keys got errno 137 on query018293.t1, retrying
2013-07-20 15:52:08 17093 [Warning] Warning: Enabling keys got errno 137 on query018293.t1, retrying
mysqld: /bzr/5.6_val/Percona-Server-5.6.12-rc60.4/sql/ha_partition.cc:4438: virtual int ha_partition::end_bulk_insert(): Assertion `0' failed.
12:52:08 UTC - mysqld got signal 6 ;
[...]
Query (217b4fb0): INSERT INTO query018293 . t1 SELECT * FROM test . `PP_B`

Related branches

lp:~laurynas-biveinis/percona-server/bug1204871
Vlad Lesin: Approve (g2) on 2014-01-13
Roel Van de Paar (roel11) wrote :
Roel Van de Paar (roel11) wrote :
Roel Van de Paar (roel11) wrote :
Roel Van de Paar (roel11) wrote :

ps -ef | grep 'cmdrun_161' | grep -v grep | awk '{print $2}' | xargs sudo kill -9
rm -Rf /ssd/209184/cmdrun_161
mkdir /ssd/209184/cmdrun_161
cd /ssd/randgen
bash -c "set -o pipefail; perl /ssd/randgen/runall.pl --queries=100000000 --seed=8432 --duration=300 --querytimeout=60 --reporter=Shutdown,Backtrace,QueryTimeout,ErrorLog,ErrorLogAlarm --mysqld=--log-output=none --mysqld=--sql_mode=ONLY_FULL_GROUP_BY --mysqld=--slow_query_log --mysqld=--userstat --threads=25 --mysqld=--innodb_file_per_table=1 --validator=Transformer --basedir=/ssd/Percona-Server-5.6.12-rc60.4-405-debug-valgrind.Linux.x86_64 --valgrind --reporter=ValgrindErrors --validator=MarkErrorLog --grammar=/tmp/976291/90.yy --gendata=/ssd/randgen/conf/partitioning/partition_pruning.zz --mtr-build-thread=746 --mask=43953 --vardir1=/ssd/209184/cmdrun_161 > /ssd/209184/cmdrun161.log 2>&1"

Roel Van de Paar (roel11) wrote :

99% upstream.

tags: added: upstream
Roel Van de Paar (roel11) wrote :

Laurynas, feel free to remove 56qual tag if this bug is "as good as certain" upstream.

tags: added: 56qual
tags: removed: 56qual

Unable to reproduce with current lp:randgen (rev 946) and lp:percona-server (rev 524) using the provided runall command (with and without Valgrind options) and the yy file. Moreover, the runall command produces many errors that look like internal RQG errors on the way.

Although http://bugs.mysql.com/bug.php?id=71270 fails with the same assert, the underlying cause cannot be the same as for this bug.

My previous comment is wrong as I failed to consider MyISAM, which is tested in this RQG setup, and this indeed appears to be upstream 71270 in combination with too small myisam_sort_buffer_size.

2013-07-20 15:52:08 17093 [Warning] Warning: Enabling keys got errno 137 on query018293.t1, retrying
2013-07-20 15:52:08 17093 [Warning] Warning: Enabling keys got errno 137 on query018293.t1, retrying
2013-07-20 15:52:08 17093 [Warning] Warning: Enabling keys got errno 137 on query018293.t1, retrying
2013-07-20 15:52:08 17093 [Warning] Warning: Enabling keys got errno 137 on query018293.t1, retrying
2013-07-20 15:52:08 17093 [Warning] Warning: Enabling keys got errno 137 on query018293.t1, retrying
2013-07-20 15:52:08 17093 [Warning] Warning: Enabling keys got errno 137 on query018293.t1, retrying
2013-07-20 15:52:08 17093 [Warning] Warning: Enabling keys got errno 137 on query018293.t1, retrying
2013-07-20 15:52:08 17093 [Warning] Warning: Enabling keys got errno 137 on query018293.t1, retrying
2013-07-20 15:52:08 17093 [Warning] Warning: Enabling keys got errno 137 on query018293.t1, retrying
mysqld: /bzr/5.6_val/Percona-Server-5.6.12-rc60.4/sql/ha_partition.cc:4438: virtual int ha_partition::end_bulk_insert(): Assertion `0' failed.

which is consistent with MyISAM end bulk insert implementation:

int ha_myisam::end_bulk_insert()
{
...
      if (((err= enable_indexes(HA_KEY_SWITCH_NONUNIQ_SAVE)) != 0) &&
                                                  current_thd->killed)
...
  return err;
}

returning handler error and hitting 71270.

tags: added: tokudb
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.