Sqlserver-dba.com

SQL Server - Backup data is incorrectly formatted

I tried to complete a SQL server 2005 database Restore from disk,this information message was displayed in the error logs:

The backup data at the end of "K:\backups\mybackup.bak" is incorrectly formatted. Backup sets on the media might be damaged and unusable. To determine the backup sets on the media, use RESTORE HEADERONLY. To determine the usability of the backup sets, run RESTORE VERIFYONLY. If all of the backup sets are incomplete, reformat the media using BACKUP WITH FORMAT, which destroys all the backup sets.

I ran this command:

RESTORE VERIFYONLY
FROM DISK='K:\backups\mybackup.bak'

after 1 hr there were still no response - on a 20 GB database.

As a way of troubleshooting - I issued the BACKUP DATABASE command again , with the the FORMAT option . This time , I issued the RESTORE VERIFYONLY   and got a positive response within a short while. I was able to complete the RESTORE.

The important point here was that the initial backup was reported as successfull , in the Logs, but then failed on the RESTORE. This indicates a  filemark in the backup device could not be read.With some research the most likely reason for the initial RESTORE failure was that SQL server reported the BACKUP as OK - even though a IO write failed.

Source:Jack Vamvas (http://www.sqlserver-dba.com)
Author: Jack Vamvas (http://www.sqlserver-dba.com)

Verify your Comment

Previewing your Comment

This is only a preview. Your comment has not yet been posted.

Working...
Your comment could not be posted. Error type:
Your comment has been posted. Post another comment

The letters and numbers you entered did not match the image. Please try again.

As a final step before posting your comment, enter the letters and numbers you see in the image below. This prevents automated programs from posting comments.

Having trouble reading this image? View an alternate.

Working...

Post a comment


sqlserver-dba.com | SQL Server Performance Tuning | SQL Server DBA:Everything | FAQ | Contact