Bug #20118 Fails to boot on system start up - but can be started manually
Submitted: 29 May 2006 8:51 Modified: 14 Jun 2006 13:03
Reporter: Miles Barry Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server Severity:S3 (Non-critical)
Version:5.0.21-1 (x86 and x86-64) OS:Linux (SLES9 (SP3 and All Updates))
Assigned to: Valeriy Kravchuk CPU Architecture:Any

[29 May 2006 8:51] Miles Barry
Description:
After the MySQL-client-standard-5.0.21-1.sles9.xxxx.rpm is installed, after restarting the box, and every time there after, the mysql server daemon does not start.

Once the box has finished booting, logging in a rcmysql start will sucessfully start the daemon.

One of the errors I have seen is:

060529 09:36:14  mysqld started
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=0
read_buffer_size=131072
max_used_connections=0
max_connections=100
threads_connected=0
It is possible that mysqld could use up to
key_buffer_size + (read_buffer_size +
sort_buffer_size)*max_connections = 217599 K
bytes of memory
Hope that's ok; if not, decrease some variables in the equation.

This crash occured while the server was calling initgroups(). This is
often due to the use of a mysqld that is statically linked against glibc
and configured to use LDAP in /etc/nsswitch.conf. You will need to either
upgrade to a version of glibc that does not have this problem (2.3.4 or
later when used with nscd), disable LDAP in your nsswitch.conf, or use a
mysqld that is not statically linked.
060529 09:36:15  mysqld ended

060529 09:49:38  mysqld started
060529  9:49:38  InnoDB: Started; log sequence number 0 43655
060529  9:49:39 [Note] /usr/sbin/mysqld: ready for connections.
Version: '5.0.21-standard'  socket: '/var/lib/mysql/mysql.sock'  port:
3306  MySQL Community Edition - Standard (GPL)

^^^ from a x86-64 HP Proliant server

---------------------

060529 10:39:26  mysqld started
mysqld: socket_wrapper.cpp:114: uint yaSSL::Socket::send(const byte*, unsigned int, int) const: Assertion `socket_ != INVALID_SOCKET' failed.
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.
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=0
read_buffer_size=131072
max_used_connections=0
max_connections=100
threads_connected=0
It is possible that mysqld could use up to
key_buffer_size + (read_buffer_size + sort_buffer_size)*max_connections = 217599 K
bytes of memory
Hope that's ok; if not, decrease some variables in the equation.

thd=(nil)
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...
Cannot determine thread, fp=0xbfffe98c, backtrace may not be correct.
Stack range sanity check OK, backtrace follows:
0x8183f80
0xffffe420
(nil)
0x400c8c03
0x84038a1
0x83f8961
0x840327d
0x83ed313
0x4020f2d9
0x4020f5b8
0x401cfa7c
0x401d1671
0x401c87b1
0x401c8ca6
0x4012dcaf
0x4012deea
0x8185faf
0x818699f
0x400bd210
0x80fcf21
New value of fp=(nil) failed sanity check, terminating stack trace!
Please read http://dev.mysql.com/doc/mysql/en/Using_stack_trace.html and follow instructions on how to resolve the stack trace. Resolved
stack trace is much more helpful in diagnosing the problem, so please do resolve it
The manual page at http://www.mysql.com/doc/en/Crashing.html contains
information that should help you find out what is causing the crash.

This crash occured while the server was calling initgroups(). This is
often due to the use of a mysqld that is statically linked against glibc
and configured to use LDAP in /etc/nsswitch.conf. You will need to either
upgrade to a version of glibc that does not have this problem (2.3.4 or
later when used with nscd), disable LDAP in your nsswitch.conf, or use a
mysqld that is not statically linked.
060529 10:39:29  mysqld ended

^^^^^From x86 in vmware

How to repeat:
Start / Restart the box.

Suggested fix:
No Idea
[29 May 2006 21:53] Valeriy Kravchuk
Thank you for a problem report. Looks similar to known bug #18810 for me. At least, may have the same reason. Please, check.
[13 Jun 2006 7:16] Miles Barry
Checked the ypbind, but is not in SLES9 (SP3) thus is not the cause of this problem
[14 Jun 2006 11:08] Miles Barry
After some testing with Lenz, we've found that it is caused when MySQL is started before "nscd". To confirm this we stopped nscd and attempted to restart MySQL. It failed. Enable nscd and restart mysql, works.

As a tempory fix I have moved /etc/init.d/s12mysql to /etc/init.d/s14mysql

Now the boot log shows:

<notice>start services (smbfs nscd mysql hwscan cron)

and machine and mysql boot 100%
[14 Jun 2006 11:17] Lenz Grimmer
Thanks for your help in investigating this, Miles! So Valeriy was right in his assumption, that there is a relevance to BUG#18810 - in addition to "ypbind", we should also add "nscd" to the "Should-Start:" services (and probably "ldap" too, just to be safe)

Please close this one as a duplicate of BUG#18810 then - I will add a comment to the other bug report about this. Thanks!
[14 Jun 2006 13:03] Miles Barry
Ok closed.
[14 Jun 2006 14:55] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/7637