/tmp/mysql.sock 없어서 생기는 문제가 아닙니다.
문제는 Mysql 데몬이 떠있지 않아서 생기는 겁니다.
데몬만 다시 띄워주면 됩니다.
아래처럼 실험해 보았습니다.
[root@acro /root]# killall mysqld
[root@acro /root]# cd /usr/local/mysql/
[root@acro mysql]# ./bin/mysql test
ERROR 2002: Can't connect to local MySQL server through socket '/tmp/mysql.sock' (111)
[root@acro mysql]# ./bin/safe_mysqld &
[1] 586
[root@acro mysql]# kill 483: 그런 프로세스가 없음
Starting mysqld daemon with databases from /usr/local/mysql/data
[root@acro mysql]# ./bin/mysql test
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A
Welcome to the MySQL monitor. Commands end with ; or g.
Your MySQL connection id is 1 to server version: 3.22.23b
Type 'help' for help.
mysql>
다시한번 이야기 하면
ERROR 2002: Can't connect to local MySQL server through socket '/tmp/mysql.sock' (111)
이 에러메시지는
"MySQL server가 기동되지 않았습니다" 라는 의미입니다.
피에취피학교에서 가져옴....
killall mysqld 하시구요...
./bin/safe_mysqld & 하세요...
/usr/local/mysql 에서 실행하세요..--저 곳에 서명을 적어주십시오.