Question
Problem with mysql database after migrating my wordpress website
- I have lamp stack droplet
- I created 2 wordpress website and they were working fine
- I installed the wordpress and made a virtual host to another wordpress website , I completed the the wordpress installation and I installed this plugin (All-in-One WP Migration ) to migrate my working wordpress website which is currently hosted on another shared hosting
- I migrated the website successfully from the shred hosting to my droplet using the wordpress plugin (All-in-One WP Migration )
- I changed the dns to point to DO servers
- All websites crashed and I get the “Error establishing a database connection”
- I tried to access the mysql root using this command : “$ mysql -u root -p” but I got this message : “ERROR 2002 (HY000): Can’t connect to local MySQL server through socket ’/var/run/mysqld/mysqld.sock’ (2)”
- I used this guide to install wordpress like I did with the first 2 websites : https://www.digitalocean.com/community/tutorials/how-to-install-wordpress-with-lamp-on-ubuntu-16-04 and I’m pretty sure some steps in this guide is conflicting the migration process and causing the websites crash. Please help me to fix it ?
These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.
×
Update :