How can you determine whether a database backup was effective? (4 posts)

  1. eveums
    Posted 9 years ago #

    I back up my MySQL db about once a month or so according to the Codex instructions. I was wondering if there was any way for me to verify that my backups are correct and not corrupted and basically OK. Is there a simple way to do this? Or should I stop being so paranoid since I'm following the directions to a 't'?? :) Thanks!

  2. Mark (podz)
    Support Maven
    Posted 9 years ago #

    I create a new blog and restore into that.
    That said, I have xampp on my machine so doing that takes all of 3 minutes to do. It's the only way to be certain.

  3. skippy
    Posted 9 years ago #

    Once you have a known good backup, you can also use that to compare new backups.

    Assuming you're on a UNIX-like system (GNU/Linux or Mac OSX), you can use the diff command to compare two text files, and see the differences.

    Unzip your backup files into a temporary directory, then do this:
    diff good_backup.sql new_backup.sql
    using the real file names, obviously. This will show you what's different between the two. You should be able to visually scan for obvious anomolies.

  4. eveums
    Posted 9 years ago #

    Thanks for the info!

Topic Closed

This topic has been closed to new replies.

About this Topic