mysql_secure_installation does not work with socket locations other than /tmp/mysql.sock
The only information I could find on this is a MySQL bug report dating back to 2009: http://bugs.mysql.com/bug.php?id=46842
I've tried passing the basedir to mysql_secure_installation as well as --defaults-file and --socket but it refuses to look anywhere but /tmp/mysql.sock.
I'm running MariaDB in userland and except for this script everything is working fine. My socket file is in /mariadb/mysql/run/mysql.sock. Mediawiki has no problem connecting to it using localhost when it's set as the default socket in php.ini. I have network connections disabled in my.cnf to only allowed Unix socket connections. I've tried to fix it myself but I've exhausted my command line scripting knowledge.
Can someone please help me get this script working again?
Answer
It's a bug (even reported to MySQL in 2009, but not fixed yet).
MariaDB bug tracker is at http://mariadb.org/jira
If you report the bug there, you can expect it to be fixed in the next release.