ah, panic mode at 7am this morning, when a bunch of wordpress sites i host with a digital ocean droplet are all suddenly down, only to be presented with the infamous wordpress database error being displayed in the browser;error establishing a database connection.
i quickly go to access the phpmyadmin login (which is up), enter my login credentials, followed by amysql error 2002greeting. i can’t log in… huh?!
surely not, but perhaps the mysql server isn’t running! so i ssh into the box, and run:
service mysql status
only to find out that indeed,mysql server is not running!
simple fix – start up the mysql server again:
service mysql start
and everything went back to normal once more. apparently if there’s a sudden spike in cpu memory usage it can take down the mysql server… something to look into if it keeps reoccurring i guess.