[MDEV-11622] Mariadb= 10.1.17-MariaDB get crashed after disabling query_cache_type on fly Created: 2016-12-21  Updated: 2021-04-28  Resolved: 2021-04-28

Status: Closed
Project: MariaDB Server
Component/s: Query Cache
Affects Version/s: 10.1
Fix Version/s: N/A

Type: Bug Priority: Major
Reporter: suraj chauhan Assignee: Unassigned
Resolution: Duplicate Votes: 0
Labels: None
Environment:

Red Hat Enterprise Linux Server release 7.1 (M


Issue Links:
Duplicate
is duplicated by MDEV-10826 Assertion `thd->get_stmt_da()->is_eof... Confirmed
Relates
relates to MDEV-10498 10.1.9-MariaDB-log MariaDB Server cr... Closed
relates to MDEV-12156 10.1.21 crash Closed

 Description   

One of our production database having mariadb 1.17.xx got crashed during disabling query_cache_type.

As per documentation it is dynamic variables and can be changed on fly.
Find the attached recent error logs.

161221 15:58:45 [ERROR] 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.
 
To report this bug, see https://mariadb.com/kb/en/reporting-bugs
 
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.
 
Server version: 10.1.17-MariaDB
key_buffer_size=16777216
read_buffer_size=2097152
max_used_connections=352
max_threads=2511
thread_count=107
It is possible that mysqld could use up to
key_buffer_size + (read_buffer_size + sort_buffer_size)*max_threads = 10352993 K  bytes of memory
Hope that's ok; if not, decrease some variables in the equation.
 
Thread pointer: 0x0x7f635b338008
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 = 0x7f6c4b4b0288 thread_stack 0x48400
/opt/mariadb/bin/mysqld(my_print_stacktrace+0x2e)[0xc0717e]
/opt/mariadb/bin/mysqld(handle_fatal_signal+0x4ba)[0x7667ea]
/lib64/libpthread.so.0(+0xf130)[0x7f88c9916130]
/lib64/libc.so.6(+0x14eaa2)[0x7f88c8846aa2]
/opt/mariadb/bin/mysqld(_ZN11Query_cache17write_result_dataEPP17Query_cache_blockmPhS1_NS0_10block_typeE+0x128)[0x576198]
/opt/mariadb/bin/mysqld(_ZN11Query_cache18append_result_dataEPP17Query_cache_blockmPhS1_+0x201)[0x576441]
/opt/mariadb/bin/mysqld(_ZN11Query_cache6insertEP3THDP15Query_cache_tlsPKcmj+0xeb)[0x57656b]
/opt/mariadb/bin/mysqld(net_real_write+0x45)[0x523935]
/opt/mariadb/bin/mysqld(net_flush+0x23)[0x523dc3]
/opt/mariadb/bin/mysqld(_ZN8Protocol8send_eofEjj+0xb9)[0x529329]
/opt/mariadb/bin/mysqld(_ZN8Protocol13end_statementEv+0x87)[0x5280b7]
/opt/mariadb/bin/mysqld(_Z16dispatch_command19enum_server_commandP3THDPcj+0x468)[0x5bbd38]
/opt/mariadb/bin/mysqld(_Z10do_commandP3THD+0x2a7)[0x5be087]
/opt/mariadb/bin/mysqld(_Z24do_handle_one_connectionP3THD+0x183)[0x68d2f3]
/opt/mariadb/bin/mysqld(handle_one_connection+0x42)[0x68d512]
/lib64/libpthread.so.0(+0x7df5)[0x7f88c990edf5]
/lib64/libc.so.6(clone+0x6d)[0x7f88c87ee1ad]
 
Trying to get some variables.
Some pointers may be invalid and cause the dump to abort.
Query (0x7f5ebeced020): is an invalid pointer
Connection ID (thread ID): 15374349
Status: NOT_KILLED
 
Optimizer switch: index_merge=on,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on,index_merge_sort_intersection=off,engine_condition_pushdown=off,index_condition_pushdown=on,derived_merge=on,derived_with_keys=on,firstmatch=on,loosescan=on,materialization=on,in_to_exists=on,semijoin=on,partial_match_rowid_merge=on,partial_match_table_scan=on,subquery_cache=on,mrr=on,mrr_cost_based=off,mrr_sort_keys=on,outer_join_with_cache=on,semijoin_with_cache=on,join_cache_incremental=on,join_cache_hashed=on,join_cache_bka=on,optimize_join_buffer_size=off,table_elimination=on,extended_keys=on,exists_to_in=on,orderby_uses_equalities=off
 
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.
 
We think the query pointer is invalid, but we will try to print it anyway.
Query: select ABIBNAME, ABICPFNAME, ABIUBIRFNUM, ABICNDTRANTY, ABITYPROPDEAL, ABIPROJCURNT, ABIAUTHAGENTOF, ABIPROJHAND, ABIBSITE, ABIDISCP, ABIBRIEFDISCP, ABIMODERRESULT , AGENTISVERIFIED, ABICNDOPERSIN, ABICPPHOTO, CPPHMODERRESULT, ABIBLOGO, LOGOMODERRESULT from TPABI where ABIUBIRFNUM='7113829'
 
161221 15:59:38 mysqld_safe Number of processes running now: 0
161221 15:59:38 mysqld_safe mysqld restarted



 Comments   
Comment by Elena Stepanova [ 2016-12-25 ]

Did you disable the cache by setting query_cache_type=OFF or by setting query_cache_size=0?
It is bug either way, but the difference for us is that we can get a crash with query_cache_type, but so far we haven't been able to reproduce it with query_cache_size, even though we've had several reports about it.

Comment by suraj chauhan [ 2016-12-26 ]

by setting query_cache_size=0;
Mariadb got crashed twice as soon as above command executed.
Database should not be crashed as we have large bunch of MySQL Production server where we do disable query cache such way many time on running server.

Is this Bug in Mariadb? Any solution in upcoming releases?

Comment by Elena Stepanova [ 2021-04-28 ]

With the lack of other options, we'll consider it a duplicate of MDEV-10826 which features the same stack trace among numerous comments.

Generated at Thu Feb 08 07:51:23 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.