且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

无法通过 socket '/tmp/mysql.sock' 连接到本地 MySQL 服务器 (2)

更新时间:2023-02-04 21:43:25

您需要按照说明安装并启动服务器.

You need to follow the directions to install and start the server.

命令因您安装 MySQL 的方式而异.先试试这个:

The command varies depending on how you installed MySQL. Try this first:

sudo/Library/StartupItems/MySQLCOM/MySQLCOM start

sudo /Library/StartupItems/MySQLCOM/MySQLCOM start

如果失败:

cd/usr/local/mysql
须藤./bin/mysqld_safe
(如有必要,请输入您的密码)
(按 Control-Z)
背景

cd /usr/local/mysql
sudo ./bin/mysqld_safe
(Enter your password, if necessary)
(Press Control-Z)
bg