0

I am new to MySQL.

I naively tried to uninstall my MySQL from by Ubuntu 20.04 before attempting to reinstall it again.

In order to do this, I followed the instructions listed in the accepted answer in this post.

Alas, upon reinstallation, trying to run sudo mysql returned ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)

I checked out /var/run/ and it contains no mysqld folder...

How can "recreate" the mysqld socket? Any help will be appreciated!

Sheldon
  • 101
  • Are you sure the service is actually running? please [edit] your question to include the output of systemctl status mysql.service – steeldriver Nov 13 '20 at 21:41
  • Telling us which remote procedure (RP) you "followed" doesn't help us help you for N reasons: 1) It's remote. Will the link exist tomorrow? 2) Reading the RP doesn't tell us how accurately you "followed" it. Did you suffer typos or missed lines? We have. 3) Reading the RP omits the error messages you got on your system. These error messages (and the commands that caused them) are key elements in any diagnosis. – waltinator Nov 13 '20 at 23:09
  • Thanks for your answers, both of you. Apparently, my problem was that I had not uninstalled all versions of mysql. Running dpkg -l mysql * revealed that version 8.0 was still installed. Purging it and reinstalling mysql-server did the trick for me. – Sheldon Nov 14 '20 at 09:46

0 Answers0