Recent Changes - Search:


Code:


Social:


My journals will take the place of a blog. They have moved to https://goo.gl/JyZbSK


Sites I take responsibility for

Documents

Technical

General

Me

Living

Places I frequent

Hobbies

Humor

Items for sale:


Clipboard

edit SideBar

My journal entry for 2015-02-07 Saturday - MySQL crash

Synopsis:

It seems back on January 28 when performing Gentoo updates (emerge -auvDN world) I was upgraded to MySQL 5.6 from 5.5. I failed to follow the advice left in the message after the emerge:

"If you are upgrading major versions, you should run the

 * mysql_upgrade tool."

Mainly because I failed to notice I was upgrading major versions. Mea culpa. Hopefully this journal entry will get picked up by Google and will help someone else who falls into the same pit.

I had this problem with MySQL crashing when I attempted to connect with it. The crash message is below. I am running 5.6.22. I was starting to recompile MySQL with debug options when I came across this post which lead to this bug report.

Steps to correct:

1. Login as root and modify you main my.cnf file (located in /etc/mysql usually) and add the following line under the section for the server "[mysqld]".

(:code:) [mysqld] skip-grant-tables (:codeend:)

2. Restart MySQL server ( /etc/init.d/mysql restart typically)

3. Next run command mysql_upgrade -u root -p

4. Now restart the mysql server again (see Step 3 2)

5. Test access from the client

(:code:) $ mysql -u root -p Enter password: Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 1 Server version: 5.6.22-log Source distribution

Copyright (c) 2000, 2014, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its affiliates. Other names may be trademarks of their respective owners.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql> status


mysql Ver 14.14 Distrib 5.6.22, for Linux (x86_64) using EditLine wrapper

Connection id: 1 Current database: Current user: root@localhost SSL: Not in use Current pager: /usr/bin/less Using outfile: '' Using delimiter: ; Server version: 5.6.22-log Source distribution Protocol version: 10 Connection: Localhost via UNIX socket Server characterset: utf8 Db characterset: utf8 Client characterset: utf8 Conn. characterset: utf8 UNIX socket: /var/run/mysqld/mysqld.sock Uptime: 19 sec

Threads: 1 Questions: 5 Slow queries: 0 Opens: 70 Flush tables: 1

  Open tables: 63  Queries per second avg: 0.263

(:codeend:)


Crash I was seeing in the MySQL error log:

(:code:) 15:47:03 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. 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.

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

Thread pointer: 0x31698e0 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 = 7fff4d9d6c08 thread_stack 0x40000 /usr/sbin/mysqld(my_print_stacktrace+0x20)[0x83f5a0] /usr/sbin/mysqld(handle_fatal_signal+0x34d)[0x61fc9d] /lib64/libpthread.so.0(+0xfeb0)[0x7f66eeac3eb0] /usr/sbin/mysqld(_Z9get_fieldP11st_mem_rootP5Field+0x22)[0x6fdcd2] /usr/sbin/mysqld(_Z10acl_reloadP3THD+0x1006)[0x633466] /usr/sbin/mysqld(_Z8acl_initb+0x102)[0x634652] /usr/sbin/mysqld(_Z11mysqld_mainiPPc+0x13c2)[0x577d92] /lib64/libc.so.6(__libc_start_main+0xf5)[0x7f66ee12aa65] /usr/sbin/mysqld[0x56c9c5]

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

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. (:codeend:)

Edit - History - Print - Recent Changes - Search
Page last modified on February 07, 2015, at 05:11 PM EST