How does one change the default socket used by mysqladmin?
I don't see a section for [mysqladmin]
in /etc/my.cnf
.
It tries by default to connect to /tmp/mysql.sock
, however, this is not the socket that my MySQL server uses, so I get the error:
error: 'Can't connect to local MySQL server through
socket '/tmp/mysql.sock'
I know you can specify the socket at the command line, such as:
mysqladmin --socket='/some/other/path/mysql.sock'
How do I change the default socket used by mysqladmin so I don't have to specify my non-standard path each time?