/usr/bin/mysqladmin: connect to server at 'localhost' failed error: 'Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2) Check that mysqld is running and that the socket: '/var/run/mysqld/mysqld.sock' exists 我修改文件/etc/mysql/my.cnf,然后重启mysql的时候,发生了上面这个错误 解决方法:从一台mysql好用的电脑里,复制了一个新的my.cnf文件解决了这个问题