I am wondering if a VM backup will restore a SQL database with out integrity issues…. Ie… we backup SQL nightly and keep 3 copies, we backup with VM and keep 14 copies…. if we had to restore day 10 from VM would we have any integrity issues, I know we could not do log recovery, but that point in time would be better than nothing. We have completed a test restore and it seemed to work, but I would like the experts answers also. Thanks
SQL Server – Will a VM Backup Work for Database Restoration?
sql server
Related Question
- Sql-server – Restoring Database, creating new copy and use existing transaction logs for the original backup database to restore the NEW database to be current
- Sql-server – Applying (log backup) LSNs to the secondary node of an Availability Group
- SQL Server – Sudden Log Autogrowth After Database Backup
- SQL Server Backup – Restore to Start or Finish Time?
Best Answer
I've seen database servers go down in flames because the VM backup wasn't database-aware. While it MAY work, you'd best test it first to be sure -- restore the VM as a clone with a different name just to see if the DB comes online. (In disaster recovery, no backup is good unless you've restored it somewhere to prove it is good...)
I recommend you implement a two-stage backup process:
I recommend you do the SQL backups with a tool like the backup scripts in Ola Hallengren's solution.
In my production environments, we back up our database servers (physical and virtual) daily, but we use the Ola Hallengren scripts to backup the databases to a separate file server. We schedule the O. Hallengren jobs such that:
(We also schedule the DBCC and Index jobs those scripts create on a weekly basis.)
This means I can restore any of my databases to any point in time within a rolling two-week window Before I have to go get a tape restore from our backup engineer. Any further back and I can have the engineer restore the appropriate backup files from that file server and then manually restore the database from there -- rather than blowing out an entire server just to get one database (or one table on one database, Cthulhu-forbid...)
And I have two scripts (based on this) that build the series of restore database statements needed to recover via the files this produces. One just dumps all the full backups in the file share, then all the Diff backups, then all the log backups. The other is a bit smarter, in that it gets the most recent full, the most recent diff, and then the log files more current than that diff. This way, if I have to recover a crashed database or clone a database to another server, I just fire off those scripts, create the "Move X to path" statements since our system engineers never assign the same drive letters when deploying new servers (sigh), and I'm done.
Also, always remember to set your backup strategy to meet your company's RPO and RTO goals.
I also feel a need to reference the "Bad Backup Schedule" list, since it specifically mentions VSS snapshots.