Bug #83481 Crash on Field_temporal_with_date::store_time(st_mysql_time*, unsigned char)
Submitted: 22 Oct 2016 3:09 Modified: 22 Nov 2016 14:56
Reporter: Jericho Rivera Email Updates:
Status: No Feedback Impact on me:
None 
Category:MySQL Server: DML Severity:S3 (Non-critical)
Version:5.7.15 OS:Linux
Assigned to: CPU Architecture:Any

[22 Oct 2016 3:09] Jericho Rivera
Description:
22:34:24 UTC - 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.
Attempting to collect some information that could help diagnose the problem.
As this is a crash and something is definitely wrong, the information
collection process might fail.
Please help us make Percona Server better by reporting any
bugs at http://bugs.percona.com/

key_buffer_size=8388608
read_buffer_size=131072
max_used_connections=8
max_threads=501
thread_count=7
connection_count=7
It is possible that mysqld could use up to 
key_buffer_size + (read_buffer_size + sort_buffer_size)*max_threads = 207225 K  bytes of memory
Hope that's ok; if not, decrease some variables in the equation.

Thread pointer: 0x7efcd907e000
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 = 7eff9c4e7ce0 thread_stack 0x40000
/u1/mysql/bin/mysqld(my_print_stacktrace+0x2c)[0xec6b8c]
/u1/mysql/bin/mysqld(handle_fatal_signal+0x461)[0x79dba1]
/lib64/libpthread.so.0[0x3b9160f7e0]
/u1/mysql/bin/mysqld(check_date+0x45)[0xd6a725]
/u1/mysql/bin/mysqld(_ZN24Field_temporal_with_date10store_timeEP13st_mysql_timeh+0x159)[0x7e5369]
/u1/mysql/bin/mysqld[0xdaaa31]
/u1/mysql/bin/mysqld(_ZN10Copy_field14invoke_do_copyEPS_+0x15)[0xdab445]
/u1/mysql/bin/mysqld(_ZN15store_key_field10copy_innerEv+0x18)[0xcecc38]
/u1/mysql/bin/mysqld(_Z18cp_buffer_from_refP3THDP5TABLEP12st_table_ref+0x8b)[0xc7899b]
/u1/mysql/bin/mysqld(_Z24get_quick_select_for_refP3THDP5TABLEP12st_table_refy+0xdf)[0xdde9ff]
/u1/mysql/bin/mysqld(_ZN4JOIN20add_sorting_to_tableEjPNS_14ORDER_with_srcE+0x124)[0xce9cc4]
/u1/mysql/bin/mysqld(_ZN4JOIN20make_tmp_tables_infoEv+0xb54)[0xcea854]
/u1/mysql/bin/mysqld(_ZN4JOIN8optimizeEv+0x1b85)[0xca00b5]
/u1/mysql/bin/mysqld(_ZN13st_select_lex8optimizeEP3THD+0x685)[0xce5895]
/u1/mysql/bin/mysqld(_ZN18st_select_lex_unit8optimizeEP3THD+0xa2)[0xd2a992]
/u1/mysql/bin/mysqld(_ZN13st_select_lex8optimizeEP3THD+0x6b1)[0xce58c1]
/u1/mysql/bin/mysqld(_Z12handle_queryP3THDP3LEXP12Query_resultyy+0x155)[0xce5a75]
/u1/mysql/bin/mysqld[0x75d171]
/u1/mysql/bin/mysqld(_Z21mysql_execute_commandP3THDb+0x4375)[0xca8a25]
/u1/mysql/bin/mysqld(_Z11mysql_parseP3THDP12Parser_state+0x5d5)[0xcabeb5]
/u1/mysql/bin/mysqld(_Z16dispatch_commandP3THDPK8COM_DATA19enum_server_command+0x92f)[0xcac86f]
/u1/mysql/bin/mysqld(_Z10do_commandP3THD+0x1b7)[0xcae207]
/u1/mysql/bin/mysqld(handle_connection+0x2a0)[0xd6fd00]
/u1/mysql/bin/mysqld(pfs_spawn_thread+0x1b4)[0xef6704]
/lib64/libpthread.so.0[0x3b91607aa1]
/lib64/libc.so.6(clone+0x6d)[0x3b912e8aad]

Trying to get some variables.
Some pointers may be invalid and cause the dump to abort.
Query (7efcd9090030): is an invalid pointer
Connection ID (thread ID): 5
Status: NOT_KILLED

./mysqld --version
./mysqld  Ver 5.7.15 for linux-glibc2.5 on x86_64 (MySQL Community Server (GPL))

How to repeat:
Customer is able to repeat in their environment. If allowed we may be able to share the relevant files in private.
[22 Oct 2016 14:56] MySQL Verification Team
Thank you for the bug report. WE need a repeatable test case (create table, insert data scripts and configuration file you can provide them as private if you wish). Thanks in advance.
[23 Nov 2016 1: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".
[23 Jan 2021 13:22] andy zhang
Jericho, we met the crash with the similar stack. But we can't re-produce the problem anymore. Do you mind sharing your steps to re-produce the stack?
[23 Jan 2021 15:28] MySQL Verification Team
We need to know the query that crashed,  and the table structures involved.
[14 Mar 2023 6:33] zhijun long
MySQL 8.0 has a similar problem

we're sending the information to the erro
r-log instead: MY-001158 - Got an error reading communication packets
00:35:45 UTC - mysqld got signal 11 ;
Most likely, you have hit a bug, but this error can also be caused by malfunctioning hardware.
Thread pointer: 0x7f0123c80000
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 = 7f0136c6d4a8 thread_stack 0x46000
/usr/local/engine/bin/mysqld(my_print_stacktrace(unsigned char const*, unsigned long)+0x3d) [0x16725dd]
/usr/local/engine/bin/mysqld(handle_fatal_signal+0x171) [0xe1ddb6]
/lib64/libpthread.so.0(+0xf700) [0x7f19be36d700]
/usr/local/engine/bin/mysqld(check_date(MYSQL_TIME const&, bool, unsigned int, int*)+0x44) [0x1fc55f4]
/usr/local/engine/bin/mysqld(Field_temporal_with_date::store_time(MYSQL_TIME*, unsigned char)+0x7e) [0x1d6fd7e]
/usr/local/engine/bin/mysqld() [0x1d76a90]
/usr/local/engine/bin/mysqld(Copy_field::invoke_do_copy2(Field const*, Field*)+0xaf) [0x1bcd28f]
/usr/local/engine/bin/mysqld(Copy_field::invoke_do_copy(bool)+0x21) [0x1bccfb1]
/usr/local/engine/bin/mysqld(copy_fields(Temp_table_param*, THD const*, bool)+0x8b) [0x1b9cfbb]
/usr/local/engine/bin/mysqld(copy_fields_and_funcs(Temp_table_param*, THD const*, Copy_func_type)+0x1e) [0x1b9cefe]
/usr/local/engine/bin/mysqld(MaterializeIterator::MaterializeQueryBlock(MaterializeIterator::QueryBlock const&, unsigned long long*)+0x13c) [0x1bc7b6c]
/usr/local/engine/bin/mysqld(MaterializeIterator::Init()+0xfe) [0x1d65a2e]
/usr/local/engine/bin/mysqld(NestedLoopIterator::Init()+0x16) [0x1d65cb6]
/usr/local/engine/bin/mysqld(AggregateIterator::Init()+0x24) [0x1d650b4]
/usr/local/engine/bin/mysqld(SELECT_LEX_UNIT::ExecuteIteratorQuery(THD*)+0x1de) [0x1baea7e]
/usr/local/engine/bin/mysqld(SELECT_LEX_UNIT::execute(THD*)+0x26) [0x1d207e6]
/usr/local/engine/bin/mysqld(Sql_cmd_dml::execute_inner(THD*)+0x176) [0x1cfff76]
/usr/local/engine/bin/mysqld(Sql_cmd_dml::execute(THD*)+0x59e) [0x1bac06e]
/usr/local/engine/bin/mysqld(mysql_execute_command(THD*, bool)+0xbf1) [0x1ba3081]
/usr/local/engine/bin/mysqld(mysql_parse(THD*, Parser_state*)+0x3da) [0x1ba710a]
/usr/local/engine/bin/mysqld(dispatch_command(THD*, COM_DATA const*, enum_server_command)+0xe7a) [0x1ba85fa]
/usr/local/engine/bin/mysqld(do_command(THD*)+0x114) [0x1ba7574]
/usr/local/engine/bin/mysqld(threadpool_process_request(THD*)+0x45) [0x193a91e]
/usr/local/engine/bin/mysqld() [0x193ba15]
/usr/local/engine/bin/mysqld() [0x1f7a13e]
/lib64/libpthread.so.0(+0x7e15) [0x7f19be365e15]
/lib64/libc.so.6(clone+0x6d) [0x7f19bce1df9d]