Description of problem: The startup configuration of mysqld continues to be a clusterfuck. While this is going on, awaiting efforts from Sun maybe, we shall endeavour to keep entropy down: In /etc/rc.d/init.d/mysqld, we see that: 1) datadir is not passed to mysql_install_db even though it might have been set in this script 2) socketfile is not passed to mysqladmin even though it might have been set in this script 3) user can be configured in /etc/my.cnf, which is useless/dangerous because the mysql user is hardcoded in the rc.d script and there is no possibility to actually change it from outside. Thus we should pass the "user" argument, too. Tentative diff attached, haven't yet tested it myself. Version-Release number of selected component (if applicable): mysql-server-5.0.45-7.el5
Created attachment 308469 [details] unified diff on /etc/rc.d/init.d/mysqld
This bug is more serious than first reported. The init.d/mysqld script is fundamentally broken as it calls /usr/bin/my_print_defaults without passing the required first parameter (path to config file). This causes the function get_mysql_option() to return no results, so the defaults specified later in the file are always used. This bug should be upgraded to high - it caused my MySQL server to fail to start after upgrading from 5.0 to 5.1.
Apologies - typo in my previous comment. This bug caused my MySQL server to fail to start after upgrading from 5.1 to 5.2.
David: agreed on (1); (2) was done already; and as for (3), shouldn't we pull the user option from the config file and use that instead of having a hardwired user name? Sam: what in the world are you talking about? my_print_defaults doesn't have a "required first parameter", and indeed the whole point of using it is to not have this script wire in knowledge about where the config file(s) are.
My apologies... A total red herring. (I have a complicated MySQL config with multiple instances and multiple config files. Sorry for the confusion.)
An advisory has been issued which should help the problem described in this bug report. This report is therefore being closed with a resolution of ERRATA. For more information on therefore solution and/or where to find the updated files, please follow the link below. You may reopen this bug report if the solution does not work for you. http://rhn.redhat.com/errata/RHSA-2009-1289.html