I've tried install LAMP to my Mac using this tutorial . I've installed MySQL from official site to my Mac (OS X El Capitan 10.11.3). I've written aliases for mysql and mysqladmin in .bash_profile. So when I try type mysql command it responses me with
error: Can't connect to local MySQL server through socket '/tmp/mysql.sock' (38)
.
I've typed perror 38 and got next: Socket operation on non-socket. What's wrong?
I think mysql server is not running. Start it by
sudo /usr/local/mysql/support-files/mysql.server start
and try again.
Make sure it is running by (sometimes mysqld will get killed if there is any error)
ps aux | grep mysql
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.