linux安装MySQL后输入mysql显示 ERROR 2002 (HY000): Can't connect to local MySQL server through socket
程序员文章站
2022-06-29 07:54:16
我是小白,大佬勿喷 linux安装MySQL后输入 显示 解决办法 输入 然后输入 问题解决 ......
我是小白,大佬勿喷
***
linux安装mysql后输入mysql
显示
error 2002 (hy000): can't connect to local mysql server through socket
解决办法
输入service mysql restart
root@des:/# service mysql restart * stopping mysql database server mysqld [ ok ] * starting mysql database server mysqld no directory, logging in with home=/ [ ok ]
然后输入mysql
root@des:/# mysql welcome to the mysql monitor. commands end with ; or \g. your mysql connection id is 4 server version: 5.7.26-0ubuntu0.18.04.1 (ubuntu) copyright (c) 2000, 2019, oracle and/or its affiliates. all rights reserved. oracle is a registered trademark of oracle corporation and/or its affiliates. other names may be trademarks of their respective owners. type 'help;' or '\h' for help. type '\c' to clear the current input statement. mysql>
问题解决
推荐阅读
-
MySQL错误 ERROR 2002 (HY000): Can't connect to local MySQL server through socket 的解决办法
-
linux安装MySQL后输入mysql显示 ERROR 2002 (HY000): Can't connect to local MySQL server through socket
-
ERROR 2002 (HY000): Can't connect to local MySQL server thro
-
ERROR 2002 (HY000): Can’t connect to local MySQL server through socket ‘/var mys
-
ERROR 2002 (HY000): Can’t connect to local MySQL server through socket ‘/var mys
-
ERROR 2002 (HY000): Can't connect to local MySQL server thr_MySQL
-
ERROR 2002 (HY000): Can't connect to local MySQL server thr_MySQL
-
mac下安装mysql报Can't connect to local MySQL server through socket '/tmp/mysql.sock' brew
-
ERROR 2002 (HY000): Cant connect to local MySQL server through socket /var/run/mysqld/mysqld.sock
-
更换mysql数据目录后出现ERROR 2002 (HY000): Can't connect to local My