方法: 修改/etc/my.conf: [mysqld] datadir=/usr/local/mysql/data socket=/var/lib/mysql/mysql.sock[mysql.server] user=mysql basedir=/usr/local/mysqlIf there is not currently a section called [client], add one at the bottom of the file and copy the socket= line under the [mysqld] section such as:[client] socket=/var/lib/mysql/mysql.sock
[mysqld] datadir=/var/lib/mysql socket=/var/lib/mysql/mysql.sock user=mysql # Default to using old password format for compatibility with mysql 3.x # clients (those using the mysqlclient10 compatibility package). old_passwords=1[mysqld_safe] log-error=/var/log/mysqld.log pid-file=/var/run/mysqld/mysqld.pid我的是这样的..改了还是不行了...(WWWWb)
[mysqld]
datadir=/usr/local/mysql/data
socket=/var/lib/mysql/mysql.sock[mysql.server]
user=mysql
basedir=/usr/local/mysqlIf there is not currently a section called [client], add one at the bottom of the file and copy the socket= line under the [mysqld] section such as:[client]
socket=/var/lib/mysql/mysql.sock
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
user=mysql
# Default to using old password format for compatibility with mysql 3.x
# clients (those using the mysqlclient10 compatibility package).
old_passwords=1[mysqld_safe]
log-error=/var/log/mysqld.log
pid-file=/var/run/mysqld/mysqld.pid我的是这样的..改了还是不行了...(WWWWb)