Report this

What is the reason for this report?

MYSQL Error 2002 cant connect to localhost through socket

Posted on January 17, 2017

Running a 1GB Droplet with Apache2 installed. I installed MYSQL but keep getting this error: ERROR 2002 (HY000): Can’t connect to local MySQL server through socket ‘/var/run/mysqld/mysqld.sock’ (2)

been running though forums and stackoverflow but cannot seem to fix it. amongst trying to fix it i also seem to no longer be able to access sites through /var/www/sitename although ip_address brings up the apache 2 default page settings.

The developer cloud

Scale up as you grow — whether you're running one virtual machine or ten thousand.

Start building today

From GPU-powered inference and Kubernetes to managed databases and storage, get everything you need to build, scale, and deploy intelligent applications.