mysql ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2)
解决办法:
less /etc/my.cnf|grep sock

socket = .....

vi /etc/my.cnf
socket = /tmp/mysql.sock  #添加该行
重启

2.Starting MySQL. ERROR! The server quit without updating PID file (/data/mysql/localhost.localdomain.pid).
解决办法:
chown -R mysql.mysql /data/
/etc/init.d/mysqld start
Starting MySQL.. SUCCESS!