On current cooker and 9.0 (at least, don't have 8.2 or 8.1 boxes around
any more, but 8.0 is not affected), mysql won't start up when
/etc/nsswitch.conf has 'ldap' in the group line:

[bgmilne:~]# grep ^group /etc/nsswitch.conf
group:      files ldap nisplus nis winbind3
[bgmilne:~]# service mysql start
Starting MySQL Server                                           [  OK  ]
[bgmilne:~]# service mysql status
mysqld is stopped
[bgmilne:~]# mysql
ERROR 2002: Can't connect to local MySQL server through socket
'/var/lib/mysql/mysql.sock' (2)



After removing the ldap entry from the group line in nsswitch.conf:

[bgmilne:~]# grep ^group /etc/nsswitch.conf
group:      files nisplus nis winbind3
[bgmilne:~]# service mysql start
Starting MySQL Server                                           [  OK  ]
[bgmilne:~]# service mysql status
mysqld (pid 10153) is running...
10152 (pid 10151) is running...
[bgmilne:~]# mysql
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 1 to server version: 3.23.54

Type 'help;' or '\h' for help. Type '\c' to clear the buffer.

mysql> Bye




If you su to mysql , you can manually start safe_mysqld even if you use
nss_ldap for groups:

[bgmilne:~]# service mysql status
mysqld is stopped
[bgmilne:~]# su - mysql
-bash-2.05b$ grep ^group /etc/nsswitch.conf
group:      files ldap nisplus nis winbind3
-bash-2.05b$ safe_mysqld &
[1] 9773
-bash-2.05b$ Starting mysqld daemon with databases from /var/lib/mysql

-bash-2.05b$ mysql
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 1 to server version: 3.23.54

Type 'help;' or '\h' for help. Type '\c' to clear the buffer.

mysql> Bye
-bash-2.05b$ logout
[bgmilne:~]# service mysql status
mysqld (pid 9782) is running...
9781 (pid 9780) is running...
[bgmilne:~]#
[bgmilne@bgmilne bgmilne]$ mysql
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 2 to server version: 3.23.54

Type 'help;' or '\h' for help. Type '\c' to clear the buffer.

mysql> Bye
[bgmilne@bgmilne bgmilne]$

I tried to use "su - mysql -c '(existing safe_mysqld command)'" in the
init script, but that didn't work.

Any ideas?


-- 
|--------------Another happy Mandrake Club member--------------|
Buchan Milne                Mechanical Engineer, Network Manager
Cellphone * Work            +27 82 472 2231 * +27 21 8828820x121
Stellenbosch Automotive Engineering         http://www.cae.co.za
GPG Key                   http://ranger.dnsalias.com/bgmilne.asc
1024D/60D204A7 2919 E232 5610 A038 87B1 72D6 AC92 BA50 60D2 04A7


Reply via email to