Bug #60670 MySQL crashed while parsing a SQL query (yacc)
Submitted: 28 Mar 2011 8:00 Modified: 22 Jun 2011 16:33
Reporter: Arnaud Adant Email Updates:
Status: No Feedback Impact on me:
Category:MySQL Server: Parser Severity:S1 (Critical)
Version:5.1.49 OS:Any
Assigned to: CPU Architecture:Any
Tags: crash, parser, yacc

[28 Mar 2011 8:00] Arnaud Adant
110309 14:07:27 - mysqld got signal 11 ;
This could be because you hit a bug. It is also possible that this binary
or one of the libraries it was linked against is corrupt, improperly built,
or misconfigured. This error can also be caused by malfunctioning hardware.
We will try our best to scrape up some info that will hopefully help diagnose
the problem, but since we have already crashed, something is definitely wrong
and this may fail.

It is possible that mysqld could use up to 
key_buffer_size + (read_buffer_size + sort_buffer_size)*max_threads = 25393322 K
bytes of memory
Hope that's ok; if not, decrease some variables in the equation.

thd: 0x2ab5643f7000
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 = 0x4777ff10 thread_stack 0x40000
Trying to get some variables.
Some pointers may be invalid and cause the dump to abort...
thd->query at 0x2ab5841034c0 is an invalid pointer
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.
mysqld: my_new.cc:51: int __cxa_pure_virtual(): Assertion `! "Aborted: pure virtual method called."' failed.
Fatal signal 6 while backtracing
mysqld: my_new.cc:51: int __cxa_pure_virtual(): Assertion `! "Aborted: pure virtual method called."' failed.
110309 14:07:29 mysqld_safe Number of processes running now: 0
110309 14:07:29 mysqld_safe mysqld restarted

How to repeat:
Impossible to repeat for now.
[28 Mar 2011 8:16] MySQL Verification Team

/usr/sbin/mysqld(parse_sql(THD*, Parser_state*, Object_creation_ctx*)+0x9c)[0x5ca4dc]
/usr/sbin/mysqld(mysql_parse(THD*, char const*, unsigned int, char const**)+0x211)[0x5d5f61]
/usr/sbin/mysqld(dispatch_command(enum_server_command, THD*, char*, unsigned int)+0x585)[0x5d6595]
[22 May 2011 16:33] Valeriy Kravchuk
Do you have any idea on how to repeat or, at least, what exact query leads to this crash?
[26 May 2011 5:16] MySQL Verification Team
Hi!  I got a similar crash yesterday, but in this case mysqld was really out of memory, and writing warnings in the log before:

./mysql-5.1.57-solaris10-x86_64/bin/mysqld:int MYSQLlex(void*,void*)+0x1d8b [ Signal 11 (SEGV)]
./mysql-5.1.57-solaris10-x86_64/bin/mysqld:int MYSQLparse(void*)+0x169
./mysql-5.1.57-solaris10-x86_64/bin/mysqld:bool parse_sql(THD*,Parser_state*,Object_creation_ctx*)+0x6e
./mysql-5.1.57-solaris10-x86_64/bin/mysqld:void mysql_parse(THD*,char*,unsigned,const char**)+0x11d
./mysql-5.1.57-solaris10-x86_64/bin/mysqld:bool dispatch_command(enum_server_command,THD*,char*,unsigned)+0xa69
./mysql-5.1.57-solaris10-x86_64/bin/mysqld:bool do_command(THD*)+0xe2
[22 Jun 2011 23:00] Bugs System
No feedback was provided for this bug for over a month, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".