MySQL always crashes
First you should try to find out whether the mysqld daemon is dead or whether your problem is related to your customer. You can use Mysqladmin version to check how long your MYSQLD server has been performing properly, and if Mysqld is dead, you can find its cause in the file "mysql-data-directory/' hostname '. Err".
Some common errors when using MySQL
The common cause of MySQL server has gone away is that the server timed out and closed the connection. By default, if nothing happens, the server closes the connection after 8 hours. You can change the time limit by setting the Wait_timeout variable when you start Mysqld.
If the mysqld gets a packet that is too large or unhealthy, it thinks the customer is wrong and closes the connection.
Can ' t connect to [local] MySQL server
Usually means that no MySQL server is running on the system or when trying to connect to the MYSQLD server, you are using an incorrect socket file or TCP/IP port.
Check (using PS) if there is a process on the server named MySQL database D started
If a mysqld process is running, you can check the server by trying these different connections
shell> mysqladmin version shell> mysqladmin variables shell> mysqladmin-h ' hostname ' version variables shell> Mysqladmin-h ' hostname '--port=3306 version shell> mysqladmin-h ' IP for your host ' version shell> mysqladmin--so Cket=/tmp/mysql.sock version Note the hostname command uses the inverse quotation mark "'" instead of the positive quotation mark "'", which causes the hostname output (that is, the current hostname) to be substituted into the mysqladmin command.
Host ' ... ' is blocked error
Host ' hostname ' is blocked because of many connection errors. Unblock with ' mysqladmin flush-hosts ' This means that mysqld has got a large number (max_connect_errors) of hosts ' hostname ' in the middle of a connection request that was interrupted. After max_connect_errors a failed request, MYSQLD identified an error (like a hacker attack) and blocked further connections to the site until someone executed the command mysqladmin flush-hosts.
by default, mysqld blocks a host after 10 connection errors. You can easily tune by starting the server like this!