Database Missing after Restore from Snapshot

August 9, 2014 5.3k views

I needed to restore my droplet from a snapshot after a problem. But now my WordPress database seems to be inaccessible or missing. Doesn't restore from snapshot restore all data and files?

1 comment
  • Log in as super user or use sudo
    Open /etc/mysql/my.cnf using gedit
    Find bind-address, and change its value to the database server host machine's IP address. For me, it was localhost or
    Save and close the file.
    Come back to terminal and execute sudo service mysql start

    And it worked for me.

4 Answers

One cause might the change of the IP address. Check the mysql configuration file.

sudo nano /etc/mysql/my.cnf

Scroll down to "bind-address = ", and update the IP number with the new IP of your droplet.

bind-address        = XX.XXX.XXX.XX

Save the changes of the file and do restart.

sudo service mysql restart


Snapshots take a full system image. All files, including your MySql database, will be present when you restore from a snapshot.

Are you seeing error messages when you attempt to connect to the database? What is the output of:

mysqladmin -u root -p status

Is there anything in the error log? Run:

tail /var/log/mysql/error.log

hello, i have the same problem, resized from snapshot and nothing is working, no mail, no web, no ssh
i am very preoccupied

yes, i meet this error also. After restore a snapshot, i can not connect to any database. Whats wrong here?

Have another answer? Share your knowledge.