There's seems to be a lot of these sort of questions, all with varying error messages, but I seem to have found a relatively new one. There is a bug report here, https://bugs.launchpad.net/percona-server/+bug/1652698, but no one responded and it's been a few months. My MySQL version is 5.7.18 on Debian 4.3.5-1 hosted on a AWS EC2.

I can't imagine this error is related to memory, since the server has 16GB of RAM and a 32GB swap file (with the swap enabled), and my InnoDB buffer pool size is set to 11GB. Here is the actual output from the crash (roughly the same output each time)

2017-05-09 10:30:35 0x7f3dc65d5700 InnoDB: Assertion failure in thread 139903297738496 in file trx0trx.ic line 213 InnoDB: Failing assertion: !trx->has_search_latch InnoDB: We intentionally generate a memory trap. InnoDB: Submit a detailed bug report to http://bugs.mysql.com. InnoDB: If you get repeated assertion failures or crashes, even InnoDB: immediately after the mysqld startup, there may be InnoDB: corruption in the InnoDB tablespace. Please refer to InnoDB: http://dev.mysql.com/doc/refman/5.7/en/forcing-innodb-recovery.html InnoDB: about forcing recovery. 14:30:35 UTC - mysqld got signal 6 ; 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.

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

Thread pointer: 0x7f3d3c045ca0 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 = 7f3dc65d4e80 thread_stack 0x40000 /usr/sbin/mysqld(my_print_stacktrace+0x2c)[0xe81c7c] /usr/sbin/mysqld(handle_fatal_signal+0x459)[0x7aa4c9] /lib/x86_64-linux-gnu/libpthread.so.0(+0x110c0)[0x7f40b82830c0] /lib/x86_64-linux-gnu/libc.so.6(gsignal+0xcf)[0x7f40b6c18fcf] /lib/x86_64-linux-gnu/libc.so.6(abort+0x16a)[0x7f40b6c1a3fa] /usr/sbin/mysqld[0x780c0b] /usr/sbin/mysqld[0xf678ac] /usr/sbin/mysqld[0xf787e5] /usr/sbin/mysqld(_Z18close_thread_tableP3THDPP5TABLE+0x281)[0xbfcec1] /usr/sbin/mysqld(_Z19close_thread_tablesP3THD+0x32b)[0xbfd58b] /usr/sbin/mysqld(_ZN18Prepared_statement7prepareEPKcm+0x68e)[0xc8254e] /usr/sbin/mysqld(_Z19mysqld_stmt_prepareP3THDPKcj+0x10e)[0xc8360e] /usr/sbin/mysqld(_Z16dispatch_commandP3THDPK8COM_DATA19enum_server_command+0x142f)[0xc59fff] /usr/sbin/mysqld(_Z10do_commandP3THD+0x18f)[0xc5ad1f] /usr/sbin/mysqld(handle_connection+0x270)[0xd18190] /usr/sbin/mysqld(pfs_spawn_thread+0x1b4)[0xe996d4] /lib/x86_64-linux-gnu/libpthread.so.0(+0x7494)[0x7f40b8279494] /lib/x86_64-linux-gnu/libc.so.6(clone+0x3f)[0x7f40b6cce93f]

Trying to get some variables. Some pointers may be invalid and cause the dump to abort. Query (7f3d3d788778): selectstufffromtableswherevalue=1; Connection ID (thread ID): 4599255 Status: NOT_KILLED

And here is my my.cnf

port            = 3306
socket          = /var/run/mysqld/mysqld.sock
default-character-set = utf8mb4

default-character-set = utf8mb4

pid-file        = /var/run/mysqld/mysqld.pid
socket          = /var/run/mysqld/mysqld.sock
nice            = 0

user            = mysql
pid-file        = /var/run/mysqld/mysqld.pid
socket          = /var/run/mysqld/mysqld.sock
port            = 3306
basedir         = /usr
datadir         = /var/lib/mysql
tmpdir          = /tmp
lc-messages-dir = /usr/share/mysql

log-error       = /var/log/mysql/error.log

# Disabling symbolic-links is recommended to prevent assorted security risks

max-allowed-packet             = 16M
max-connect-errors             = 1000000

tmp-table-size                 = 32M
max-heap-table-size            = 32M
query-cache-type               = 0
query-cache-size               = 0
max-connections                = 500
thread-cache-size              = 50
open-files-limit               = 65535
table-definition-cache         = 4096
table-open-cache               = 4096

innodb-flush-method            = O_DIRECT
innodb-log-files-in-group      = 2
innodb-log-file-size           = 256M
innodb-flush-log-at-trx-commit = 1
innodb-file-per-table          = 1
innodb-buffer-pool-size        = 11G

character-set-client-handshake = FALSE

After each crash I've run:

mysqlcheck -u root -p --auto-repair --check --all-databases

But I never get any errors about any of my tables, so what other steps can I take to mitigate these crashes?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.