Managed Instance takes automatic backups (full backups every week, differential every 12 hours, and log backups every 5-10 min) that you can use to restore a database to some point of time in past within the retention period, restore accidentally deleted database. For more information, see Automated backups. Managed Instance also enables you to restore a database from a backup file placed on Azure Blob Storage, backup a database to Azure Blob Storage. Managed Instance currently does not support backup retention longer than 35 days, but you can use backups to blob storage as an alternative.
If you are experiencing issues with any backup or restore operation, the following troubleshooting steps might help you to identify the issue.
earliest restore time value
. Check that the point-in time that you used is after this time.RESTORE
, check are you using supported syntax in this statementCREDENTIAL
with the name equal to the URL of the blob storage where you want to backup your database.RESTORE FILELISTONLY
statement and check if Managed Instance returns a list of the files in the backup.CREDENTIAL
to SQL Server, and restore a database from Azure Blob Storage account on the SQL Server.SECRET
option of CREATE CREDENTIAL
statement valid. The most common errors in SAS token parameters are:
?
is not removed from the beginning of the SAS token because the Azure portal generates SAS token with the leading ?
. Remove this character if you see it.se
(expiry date) property is set to some value in the past (note that this is UTC time).st
(start date) property is not in the past (note that this is UTC time).sp
(permission) property should allow reading the file on the storage account.sip
(ip range) remove this parameter if it is present in SAS token.Cannot find server certificate with thumbprint ...
and you are trying to restore a backup of a database from another Managed Instance, check if the original database was encrypted with TDE in the past. Follow this procedure to backup a TDE protected database.RESTORE
statement use T-SQL to query Dynamic Management viewsBACKUP
check you are using supported syntax in this statement (for example mandatory COPY_ONLY
option).
Select * from sys.dm_database_encryption_keysYou need to disable TDE protection in order to take a manual backup.
CREDENTIAL
with the name equal to the URL of the blob storage where you want to backup your database.CREDENTIAL
and backup a database from SQL Server to Azure Blob Storage account.SECRET
option of CREATE CREDENTIAL
statement is valid. The most common errors in SAS token parameters are:
?
is left in the beginning of the SAS token that should be removed in the token is generated using the Azure portal.se
(expiry date) property is set to some value in the past (note that this is UTC time).st
(start date) property is not in the past.sp
(permission) property should allow creating and writing the file on the storage account.sip
(ip range) remove this parameter if it is present in SAS token.Write to backup block blob device ... failed. Device has reached its limit of allowed blocks.
or 3202 Write on '...' failed: 1117(The request could not be performed because of an I/O device error.)
add the following options in the BACKUP
statement: MAXTRANSFERSIZE=4194304
, BLOCKSIZE=65536
, and COMPRESS
or use URL striping in the backup command.BACKUP
statement use T-SQL to query Dynamic Management viewssqlserver.backup_restore_progress_trace
event.
Find more troubleshooting steps here.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.