Article directory
will get SEOpeople installedVestaCP :
- He added 2 databases and 2 sites.
- Everything looks business as usual today.
Error problem with VestaCP
But today when he tried to add the 3rd database, he got the error:"Error: connection to localhost failed"……
he tries to change/usr/local/vesta/conf/mysql.conf
password in the file.
- Existing database is not running, still cannot add new database.
When restarting the server, this error may appear:Error: connection to localhost failed, connection failed on VestaCP...
certainE-commerceThe site administrator has setMySQL database, but when you want to connect the site,Stumbled upon the same error:
- After doing some research, noticed that the password value was in
/root/.my.cnf
There is no change in. - But when
/usr/local/vesta/conf/mysql.conf
The correct password is displayed, and the content submitted through the panel is sufficient.
Solution
1) ModifyMySQLPassword in default file ▼
vi /usr/local/vesta/conf/mysql.conf
- Change the previous password to your existing password.
2) Restart the MySQL database ▼
service mariadb restart
- Or log in to VestaCP Panel → Server → Restart MySQL.
Extended reading:
Hope Chen Weiliang Blog ( https://www.chenweiliang.com/ ) shared "Solving VestaCP Error: connection to localhost failed", which is helpful to you.
Welcome to share the link of this article:https://www.chenweiliang.com/cwl-1452.html
Welcome to the Telegram channel of Chen Weiliang's blog to get the latest updates!
📚 This guide contains huge value, 🌟This is a rare opportunity, don’t miss it! ⏰⌛💨
Share and like if you like!
Your sharing and likes are our continuous motivation!