When I am invoking the file mysql_secure_installation
I get an error like
[mysqk123@InstallZeMo bin]$ ./mysql_secure_installation
NOTE: RUNNING ALL PARTS OF THIS SCRIPT IS RECOMMENDED FOR ALL MySQL
SERVERS IN PRODUCTION USE! PLEASE READ EACH STEP CAREFULLY!
In order to log into MySQL to secure it, we'll need the current
password for the root user. If you've just installed MySQL, and
you haven't set the root password yet, the password will be blank,
so you should just press enter here.
Enter current password for root (enter for none):
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2)
Enter current password for root (enter for none):
but the given sock file in my.cnf file is /home/mysqk123/tmp/mysql.sock and I am using redhat linux 5.3 and mysql 5.1.47
I know that the tasks performed by mysql_secure_installation script can be performed manually but here I have to run the script [ not allowed to do the task manually ]
mysql_secure_installation.sh
will be replaced by a binary that accepts options on the command line, in particular--socket=path
. I haven't tested it yet, but I will update the answer when I know more about it. – Luke