Support » Localhost Installs » Disaster recovery

  • I had a server with a wordpress site but it got hacked. I was able to recover an entire image of the server, and I have a new server, and I would like to restore my site to the new server.

    Given that this is my only backup, is this possible? I’m guessing I should have been backing up the SQL database rather than relying on a server image.

    Many thanks,
    Guy

Viewing 4 replies - 1 through 4 (of 4 total)
  • Moderator Steven Stern (sterndata)

    (@sterndata)

    Forum Moderator & Support Team Volunteer

    The server image should contain the necessary database files (probably in /var/lib/mysql or /var/lib/mariadb) so restoring the server image should restore the database. Do you have any tool that can extract stuff from the image without restoring the whole thing?

    Dion

    (@diondesigns)

    Was the MySQL service stopped when the backup was made? If so, then you should be able to restore the database from the backup image.

    If MySQL was running when the backup was made, then tables that used the MyISAM storage engine can be restored. Restoring tables that used the InnoDB storage engine will be problematic at best and impossible at worst.

    Thread Starter hatcat

    (@hatcat)

    Thanks both.

    The entire filesystem from my Ubuntu server is sitting on a Windows filesystem in my home. I have access to all files.

    I don’t know what the state of the service was. I didn’t personally stop it since it was serving my blog, and it seems unlikely that my host would have stopped it. I expect they simply blocked all ports except ftp.

    I don’t know which storage engine was in use, nor do I know how to find out.

    Many thanks,
    Guy

    Dion

    (@diondesigns)

    Once you find the MySQL files (usually in /var/lib/mysql, as noted), check if there are files with names like ibdata1 or ib_logfile1. If there are, your MySQL installation was using InnoDB, and you’ll likely need help that is well beyond the scope of this site. Even if that were the case, it’s still possible your WP database was not using InnoDB, but determining that is also beyond the scope of this site. Here is a good place to ask questions: https://dba.stackexchange.com/

Viewing 4 replies - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.