ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2)

Hi

Do you start the mysql server before trying to access it from the mysql client program?

I guess you have a systemd service file to accomplish this:

e.g. starting it manually until shutdown:

systemctl start mysqld

or to start the service at each of the following boots:

systemctl enable mysqld

Max