mysql 啟動報錯Can't connect to local MySQL server through socket '/data/mysql/mysql/mysql.sock'(111)

項羽齊發表於2019-01-04

1:首先mysql本地連線報錯:

  Can't connect to local MySQL server through socket '/data/mysql/mysql/mysql.sock'(111)

  解決:

    1:刪除 檔案:/data/mysql/mysql/mysql.sock

  此時又會報錯:Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2)

  進入到目錄:/data/mysql2/bin/

    使用命令:mysqld start

    此時報錯:[ERROR] Too many arguments (first extra is 'start')

    於是將命令修改:mysqld --user=mysql

感謝:

  https://www.cnblogs.com/invban/p/5824796.html

  https://blog.csdn.net/u010416101/article/details/80490536

 

 

 

相關文章