Skip navigation links

User Comments

Posted by Francisco de Jesus Orozco Ruiz on October 5 2004 10:58pm[Delete] [Edit]

Problem: I cannot start mysql an it stops and no messages in any log!

Solution:
I had a very stubborn problem starting mysqld_safe or mysqld; the server refused to keep running and simply got suspended. I tried to start the server right after installing the initial databases with mysql_install_db. The commands used as root to start the server were:

cd /usr/local/mysql
./bin/mysql_safe --user=mysql &

and the shell reported simply:

[1]+ Stopped ./bin/mysql_safe --user=mysql

The process was stuck, and I had to do a killall -9 mysql_safe to free it.

I couldn't find any error in var/(server).err or in the system logs. I discovered that redirecting the output of the server to the null device solved the problem:

./bin/mysql_safe --user=mysql > /dev/null &

The REAL solution:
The real cause was this: I was using the subshell of the Midnight Commander to test the starting of the server, and I guess this subshell did not assign a real tty device to the process, so it got deadlocked trying to write to stdout the "mysql started" message. Leaving the subshell and exiting MC proved that in normal shell everyting goes as the manual says.

This note has the goal of avoid someone else the loss of the three hours I spent solving this simple installation! :)

Posted by Kenan Bektas on December 12 2004 1:32am[Delete] [Edit]

Also, make sure the directory (Slackware Users, from source)
/var/run/mysql/
exists and owned by mysql user.

Regards,

-Kenan Bektas

Posted by Nick Wood on April 3 2006 8:10pm[Delete] [Edit]

The error message "Bind on TCP/IP port: Address already in use..." can also be caused by having an invalid/wrong IP address for a bind-address directive in your my.cnf configuration file.