An error was encountered

Error: Unable to connect to MySQL and select database. MySQL reported: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2 "No such file or directory").