How to use RETRY option in Symantec NetBackup for SQL Server

While working with Symantec NetBackup utility for SQL Server came across Retry option, this helps in reducing manual effort spend in retrying failed backups, but in some scenarios there is certain overhead as well, below is brief info about this option,


How Retry Parameter works for SQL Server Backups


If you like to setup NetBackup to retry failed backups automatically then you can use following three parameters along with other,

RETRYTYPE AUTO        #This parameter tells that Failed backups will be retried automatically

NUMRETRIES 2        #This parameter tells that how many times failed backups needs to be retried

RETRYWAITSECONDS 60    #This parameter tell that how long it need to wait before starting retry


These parameters needs to be added only once in overall script and they work differently depending upon type of backup,


In case of Full and Differential Backup, only failed database backup will be retried to complete backup

In case of T-log backup,
irrespective of which database backup failed, all databases t-log backup will be retried again (this behavior incorporated since version 6.5.2)

Ref. Link: Automatic retry behavior has been changed in NetBackup 6.5.2 and higher versions of NetBackup for Microsoft SQL Server agent



Known Issues with RETRY option


1. Now if you already have retry enabled, you may still see BACKUP FAILURE status i.e. EXIT STATUS 1. The purpose of an exit status 1 under these circumstances is to alert the administrator that there was a potential issue with the overall backup, even though the end result was success. The administrator may choose to ignore the exit status 1, if the cause of the retry is acceptable in that particular backup environment.

Ref. Link: The SQL-Server automatic backup job completes with status 1 even though all the application backup jobs were successful upon retry


2. Suppose a DB backup failed and when it retries for backup again then backup may get successful but you will also see following ERR message logged in the VERBOSE logs,


ERR – Error in RegCreateKeyEx, opening <SOFTWARE\Veritas\NetBackup\NetBackup for Microsoft SQL Server\> key: 1018. The text follows:

CONTINUATION: – Illegal operation attempted on a registry key that has been marked for deletion.

ERR – Error in CryptAcquireContext : 2.

CONTINUATION: – The system cannot find the file specified.


This happens if you have configured backup using a service account and through a scheduler service (Task Schedule, SQL Agent, Autosys, etc. etc.), basically when first time backup runs then as soon as it completes, it logs how many backup succeeded and how many failed, if there are NO failures then it return with EXIT CODE 0 marking scheduler job successful, but when any backup fails then it return the EXIT CODE 1 irrespective that RETRY is enabled and going to retry but actually speaking the scheduler has already received the EXIT CODE and it marked task as success/fail based on first exit code, now it will not hear again for any further EXIT CODE, means the user under which job started logically has been logged off and thus the error about registry starting coming in on RETRY. No need to worry as it won’t hamper the backups and you can live with it, if in case you want to fix it then follow the Workaround/Fix provided by Microsoft at following link (I have not tested it, so do it at your will)

Ref. Link: A COM+ application may stop working on Windows 2008 When a User Logs Off

Download PDF

About the Author: Nitin G

Indian born, trekker, biker, photographer, lover of monsoons. I've been working full time with SQL Server since year 2005 and blogs to post the content aquired during my research on new topics or fixing issues faced by me as a DBA while working in different kind of projects, hope some of my posts may helps others in SQLDBA community. Everything you read on my blog is my own personal opinion and any code is provided "AS-IS" with no warranties!

Leave a comment

Subscribe to this blog via Email

Enter your email address to subscribe to this blog and receive notifications of new posts by email.

Join 263 other subscribers

Translate this blog!



December 2020
« Nov    

View Post by Categories

%d bloggers like this: