Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase 12»»

Differential backups rendered useless by backup device Expand / Collapse
Author
Message
Posted Tuesday, July 10, 2012 9:46 AM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Tuesday, March 25, 2014 10:26 AM
Points: 6, Visits: 61
This is my situation. Hope someone can give some advice.
I created a maintenance plan for a production database that takes full backup once a week and differential backups every 4 hours. There is also a "snapshotting" device in the network that takes an image of the server at 11:30 pm daily. SQL is interpreting this as a snapshot backup and recording it in the backupset table.

So, my differential backups are really "differential" from these nightly snapshots and NOT from the actual full backup that i have from the previous weekend.

What can be done so that the diff backups ignore the snapshots and treat the full backup as their checkpoint? I tried manually marking the snapshot entries as 'is_copy_only'=1 in backupset. But that didn't seem to help.

Any pointers? Thank you!
Post #1327711
Posted Tuesday, July 10, 2012 12:42 PM


SSCrazy

SSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazy

Group: General Forum Members
Last Login: Friday, April 11, 2014 7:37 AM
Points: 2,673, Visits: 3,325
I would check with the company that makes said "snapshot" device and find out why they are writing to the database or exactly what they are doing with SQL Server.

Thanks,

Jared
SQL Know-It-All

How to post data/code on a forum to get the best help - Jeff Moden
Post #1327814
Posted Tuesday, July 10, 2012 2:10 PM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Tuesday, March 25, 2014 10:26 AM
Points: 6, Visits: 61
Jared,
Thanks for the reply. Apparently, some backup devices use sql VSS writer to inform sql server that the disk is being backed up, which is recorded as a snapshot backup.
I don't know if this can be avoided (except by turning off the vss writer).
i was wondering if the backup history itself could be manipulated somehow, so that the snapshot backup is not treated as a differential base.
Post #1327885
Posted Tuesday, July 10, 2012 2:15 PM


SSCrazy

SSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazy

Group: General Forum Members
Last Login: Friday, April 11, 2014 7:37 AM
Points: 2,673, Visits: 3,325
Hmm... Not completely sure, but I would personally not be altering backup related tables. Maybe someone else will have some input.

Thanks,

Jared
SQL Know-It-All

How to post data/code on a forum to get the best help - Jeff Moden
Post #1327887
Posted Tuesday, July 10, 2012 2:15 PM


SSC-Forever

SSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-Forever

Group: General Forum Members
Last Login: Today @ 11:47 AM
Points: 41,525, Visits: 34,442
sqlskj4000 (7/10/2012)
What can be done so that the diff backups ignore the snapshots and treat the full backup as their checkpoint?


Ask the people running the snapshot backups to please not snapshot the databases. That's about the only option.

I tried manually marking the snapshot entries as 'is_copy_only'=1 in backupset. But that didn't seem to help.


No it won't. Changing the history record doesn't change the properties of the backup. It just changes the history in the table and makes it incorrect.
That's like updating a shop's inventory list and marking chicken as a vegetable.



Gail Shaw
Microsoft Certified Master: SQL Server 2008, MVP
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

We walk in the dark places no others will enter
We stand on the bridge and no one may pass

Post #1327888
Posted Tuesday, July 10, 2012 2:36 PM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Tuesday, March 25, 2014 10:26 AM
Points: 6, Visits: 61
gotcha. i'll find out from the network guys if the backup device properties can be adjusted to not talk to sql.
Thanks!
Post #1327902
Posted Tuesday, July 10, 2012 8:18 PM
Old Hand

Old HandOld HandOld HandOld HandOld HandOld HandOld HandOld Hand

Group: General Forum Members
Last Login: Monday, February 24, 2014 1:04 PM
Points: 383, Visits: 2,351
sqlskj4000 (7/10/2012)
gotcha. i'll find out from the network guys if the backup device properties can be adjusted to not talk to sql.
Thanks!


Please keep us posted with your findings. This is interesting to know the outcome.

Thanks,
TA


Regards,
SQLisAwe5oMe.
Post #1328010
Posted Tuesday, February 19, 2013 2:48 PM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Wednesday, April 02, 2014 3:04 PM
Points: 9, Visits: 109
I have the same exact problem. The suggestions in the thread are not viable. You see, there is a reason for us to be doing a snapshot of the DB machine. We WANT the snapshot to happen. Doing away with it is not an option. Also, it is not anybody's fault by Microsoft, apparently. Check Knowledge base article 951288. It is a problem with Microsoft's VSS itself. This is really annoying and dangerous. All differential backups do work, but they are nearly useless, since they are based on a "full" backup that does actually exist. The alternative is to restore from the snapshot, and then use the differentials to bring the DB up to date. Not a good option for us.

So, in short:
1- We need to maintain the snapshots
2- Is seems to be a Microsoft issue
3- We need to prevent SQL from registering the snapshots as viable, valid full DB backups
OR
4- We need SQL to ignore the snapshots when doing transaction log and differential backups

Help appreciated. Raphael
Post #1421864
Posted Tuesday, February 19, 2013 2:59 PM


SSC-Forever

SSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-Forever

Group: General Forum Members
Last Login: Today @ 11:47 AM
Points: 41,525, Visits: 34,442
The only real solutions here are:
Set the backup app to snapshot the machine but exclude the databases. Some tools can, some can't. If you have a good SQL backup strategy, as it sounds like you have, then there isn't a need to snapshot the databases as well.
Set the backup app to do a 'copy only' snapshot. Probably won't be an option, haven't seen that as a setting in many tools.
Change the backup strategy to be a mix of full and log backups. If you're not doing differentials then the additional full backups won't have any effect on restoring. Not the best option, probably the last option if nothing else is possible

As soon as a full backup is taken without the copy only option, it becomes the differential base for the next full backups, regardless of how that full backup was taken. The full backup however has no effect on log backups, regardless of options or how they were taken.



Gail Shaw
Microsoft Certified Master: SQL Server 2008, MVP
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

We walk in the dark places no others will enter
We stand on the bridge and no one may pass

Post #1421866
Posted Wednesday, February 20, 2013 12:26 PM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Wednesday, April 02, 2014 3:04 PM
Points: 9, Visits: 109
I'm coming to the conclusion that my best option is to reschedule my full backups to happen exactly after the snapshot is taken.

Now, is that retarded of Microsoft or what? :)

Let me put this another way: Is there any valid reason for Microsoft not to fix this? After all, if we look at both KB articles 951288 and 903643, the issue has been around in a form or another for quite a while. Do they have this scheduled for a fix any time soon?

Additional question:

Is there a way I can setup a trigger to fire my full backup right after the snapshot? This way I can be certain that even if someone creates and unscheduled, ad-hoc snapshot I will not have the problem. What I have in mind is:

1-Setup a trigger on the server to watch for snapshots.

2-On successful snapshot, right after, fire off a full "proper" DB backup.

Is this possible? Is there an after_successful_snapshot trigger somewhere, or something similar that I can use?

Much appreciate the help,

Raphael
Post #1422244
« Prev Topic | Next Topic »

Add to briefcase 12»»

Permissions Expand / Collapse