Tons of emails in 2 days with the "ERROR 2002 (HY000)"

Hi, guys, what could go wrong in your opinion?
The situation: I haven`t changed anything at the server settings or panel settings but since 31.09 I’ve been receiving emails with ERROR 2002. It goes with intervals from hours to 5-20 minutes:

Can’t connect to MySQL localhost ERROR 2002 (HY000): Can’t connect to local server through socket ‘/run/mysqld/mysqld.sock’ (111)

I checked the MariaDB status and the service was up at the moment when I received the messages. How to stop massaging and then how to debug the issue?

Hi @butsro,

Show the ouput of these commands:

systemctl status mysqld
ls -l /run/mysqld/

Hi @sahsanu , thanks for response

systemctl status output looks good but you didn’t show the output of ls command.

Also, do you have any error using this?

mysql -uroot
show databases;

I haven’t tried this before

What is interesting is at the hestiapanel I can see for example uptime MariaDB server a hour, but during this hour I receiving a 2-3 massages with 2002 error

I see no problem, you can connect to mysql, maybe it is a ram/cpu issue… but no idea.

perhaps, you may suggest how to turn off those notifications to email? Thank you

What is sending those messages?

If it is wordpress, check if you have enabled WP_DEBUG in your wp-config.php file and set it to false instead of true.

Edit, maybe you should also enable this constant WP_DISABLE_FATAL_ERROR_HANDLER