Running RQG outer_join test leads to crash
| Affects | Status | Importance | Assigned to | Milestone | |
|---|---|---|---|---|---|
| MariaDB |
Fix Released
|
High
|
Sergey Petrunia | ||
Bug Description
Running RQG outer_join test crashes MariaDB. The crash happens on Linux 64-bit and Mac OS X Intel 64-bit. This crash happens with the patch for fixing Bug LP#523593
I attached the full stack trace from a Linux run.
How to repeat
* Get latest Random Query Generator from lp:randgen
* Get latest MariaDB from lp:maria
I tested with revno: 2818, timestamp: Wed 2010-02-17 21:10:02 +0100
* Compile MariaDB with BUILD/compile-
* Run the RQG test like
time perl runall.pl \
--basedir=
--gendata=
--grammar=
--queries=1000000 \
--threads=1
Stack trace on Mac OS X
Hope that's ok; if not, decrease some variables in the equation.
thd: 0x11261d590
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...
# 20:42:09 datadir is /Users/
# 20:42:09 binary is /Users/
# 20:42:09 bindir is /Users/
# 20:42:09 core is /cores/core.68773
# 20:42:13 Reading symbols for shared libraries .... done
# 20:42:13 Reading symbols for shared libraries . done
# 20:42:13 Reading symbols for shared libraries .... done
# 20:42:13 #0 0x00007fff86e8e9e2 in select$DARWIN_EXTSN ()
# 20:42:13 #0 0x00007fff86e8e9e2 in select$DARWIN_EXTSN ()
# 20:42:13 #1 0x00000001000f8522 in handle_
# 20:42:13 #2 0x00000001000f936f in main (argc=<value temporarily unavailable, due to optimizations>, argv=<value temporarily unavailable, due to optimizations>) at mysqld.cc:4668
Previous frame inner to this frame (gdb could not unwind past this frame)
# 20:42:16 Reading symbols for shared libraries .... done
# 20:42:16 Reading symbols for shared libraries . done
# 20:42:16 Reading symbols for shared libraries .... done
# 20:42:16 #0 0x00007fff86e8e9e2 in select$DARWIN_EXTSN ()
# 20:42:16
# 20:42:16 Thread 24 (core thread 23):
# 20:42:16 #0 0x00007fff86e8c250 in pthread_
# 20:42:16 #1 0x00007fff86ebe9c1 in backtrace ()
# 20:42:16 #2 0x00007fff86ebe967 in backtrace ()
# 20:42:16 #3 0x00000001004f7809 in my_print_stacktrace (stack_bottom=0x1 <Address 0x1 out of bounds>, thread_
# 20:42:16 #4 0x00000001000f24e2 in handle_segfault (sig=11) at mysqld.cc:2584
# 20:42:16 #5 <signal handler called>
# 20:42:16 #6 set_position (join=0x106056618, idx=<value temporarily unavailable, due to optimizations>, table=0x1063c1dd0, key=<value temporarily unavailable, due to optimizations>) at sql_select.cc:4150
# 20:42:16 #7 0x000000010028964f in eliminate_
# 20:42:16 #8 0x0000000100171ff1 in make_join_
# 20:42:16 #9 0x00000001150f1ef0 in ?? ()
# 20:42:16
| Changed in maria: | |
| status: | In Progress → Fix Committed |

Query that causes the crash:
SELECT col_int_ key AS field3, col_varchar_ 1024_latin1_ key = table5. col_varchar_ 10_utf8_ key col_varchar_ 10_latin1 = table5. col_varchar_ 1024_latin1_ key col_int_ key < table2.pk
table3.col_int AS field1,
table1.col_int AS field2,
table1.
table1.pk AS field4,
table1.col_int AS field5,
table2.col_int AS field6
FROM
CC AS table1
LEFT OUTER JOIN
K AS table2
LEFT JOIN Z AS table3
RIGHT JOIN H AS table4
LEFT JOIN M AS table5 ON table4.pk = table5.pk
LEFT JOIN A AS table6 ON table5.col_int_key = table6.pk
ON table3.col_int_key = table5.pk
ON table2.
LEFT JOIN O AS table7 ON table2.pk = table7.col_int
ON table1.
LEFT JOIN E AS table8 ON table3.col_int = table8.col_int
WHERE
table1.
HAVING
field4 != 6