Comments - Missing mysqld.sock file?

12 years, 10 months ago David Myers

Hello all,

I first encountered the same problem when I installed drupal onto a mysql 5.0 instance.

The standard instal (which for me was in fact an install from source) of MySQL places the mysqld.sock file in the tmp directory. It seems that often, other software expects to see it in the /var/run/mysqld folder.

The solution is to either change the setting in the my.cnf file

socket = /tmp/mysql.sock

or to create the required symlink.

ln -s /tmp/mysql.sock /var/run/mysqld/mysql.sock

[you will need to be root, so use sudo on debian based systems]

I use the second solution as it enables you to be place a link to the file wherever a bit of software is expecting it to be.

 
Content reproduced on this site is the property of its respective owners, and this content is not reviewed in advance by MariaDB. The views, information and opinions expressed by this content do not necessarily represent those of MariaDB or any other party.