Date: Fri, 29 Mar 2024 05:57:11 +0000 (GMT) Message-ID: <1036345618.571.1711691831677@ip-172-31-38-4.eu-west-1.compute.internal> Subject: Exported From Confluence MIME-Version: 1.0 Content-Type: multipart/related; boundary="----=_Part_570_1597197224.1711691831671" ------=_Part_570_1597197224.1711691831671 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Content-Location: file:///C:/exported.html
Backup or restore operations may take longer than expected. This= may be caused by a number of processes run by SQL Backup or by the SQL Ser= ver.
To check the progress of any SQL Backup backup or restore operations cur= rently executing on a SQL Server, run the sqbstatus extended = stored procedure against the master database:
exceute = master..sqbstatus
The results are listed per database:
If sqbstatus reports 0 bytes, this indicates that= SQL Server is performing tasks that must be completed before the backup or= restore operation can begin, and is not currently able to accept data from= SQL Backup. For information on identifying the tasks SQL Server is perform= ing, see SQL = Server processes below.
If you include the ERASEFILES
, ERASEFILES_A=
TSTART
or ERASEFILES_REMOTE
option in a&=
nbsp;BACKUP
command, or select the option to Delete existing backup files in this folder for selected database in the Back Up or Schedule Backup Jobs wizard, SQL Backup delete=
s backups of the same database and type from the backup folder as part of t=
he backup operation. To identify the files to delete, SQL Backup reads the =
headers of all the files in the backup folder. The larger the number of fil=
es stored in the folder, the longer it will take SQL Backup to read all of =
the file headers.
To reduce the number of file headers SQL Backup has to read each time, s= tore backups in folders according to database name and backup type. You can= do this automatically, by including the <DATABASE> and <TYPE> = tags in folder paths. For example, the following command will create f= ull backups of Database 1, Database 2 and Database 3 in= C:\Backups\Database 1\Full, C:\Backups\Database 2\F= ull and C:\Backups\Database 3\Full respectivel= y:
"BACKUP = DATABASES [Database 1, Database 2, Database 3] TO DISK =3D 'C:\Backups= \<DATABASE>\<TYPE>\<DATETIME ddmmyy>.sqb' WITH ERASEFILES= =3D 7"
The backup file names are based on the date and time of the backup
To avoid having to write out the tags each time, you can include tags in=
the default backup location used by SQL Backup, then use the <AUTO> =
tag in the BACKUP
command. When using the Back Up or=
Schedule Backup Jobs wizard, the backup location is populated with the def=
ault location.
If you have selected the option to Delete all backup and restore= history older than <n Days | Hours> (available from Tools > Server Options > File Mana= gement), SQL Backup uses the stored procedure msdb..sp_de= lete_backuphistory to del= ete history from the msdb= database when the graphical user i= nterface is running. For more information about this option, see= File management options.
If the msdb datab= ase contains a lot of history, or if multiple SQL Backup jobs are completin= g at the same time, deleting the history can slow down backup and restore o= perations. You may find= it helpful to add indexes to the backup and restore history tables in the&= nbsp;msdb database. For more information, refer to your= SQL Server documentation. = Alternatively, clear this option an= d run the stored procedure manually at a convenient time or as a scheduled = task. For more information, see Deleting backup and restore history= manually.
To find out which processes are being run by SQL Server as part of a bac= kup or restore, and how long those processes take, set a trace flag on the = SQL Server master database:
DBCC TRA= CEON (3004, 3605, -1)
Setting the trace flag causes additional information to be written to th= e SQL Server logs. To view the logs, open SQL Server Management Studio and = in Object Explorer open Management > <= strong>SQL Server Logs > Current.