Archive:Delay VSS backups started in a taskgroup by Sesam Pre-process

From SEPsesam
Icon archived docs.png THE CONTENT OF THIS PAGE IS OUTDATED
SEP AG has discontinued support for obsolete SEP sesam versions. Instructions are still available for these SEP sesam products, however, SEP AG accepts no responsibility or liability for any errors or inaccuracies in the instructions or for the incorrect operation of obsolete SEP sesam software. It is strongly recommended that you update your SEP sesam software to the latest version. For the latest version of SEP sesam documentation, see documentation home.

Copyright © SEP AG 1999-2024. All rights reserved.

Any form of reproduction of the contents or parts of this manual is allowed only with the express written permission from SEP AG. When compiling and designing user documentation SEP AG uses great diligence and attempts to deliver accurate and correct information. However, SEP AG cannot issue a guarantee for the contents of this manual.


Introduction

Thanks for the idea to Volker Kieselbach (Winkler & Dünnebier AG)'

If more than one backup task on one Windows partition is configured and these tasks are combined in one task group or started by the same schedule, you will get VSS snapshot errors at the execution. The problem is, on every initiated backup on the same Windows server on the same partition try to create a partition snapshot multiple at the same time. The goal is to separate the jobs by time offeset by using the Sesam Pre execution for every task.

Example

There is a Windows server (w2k3server) with a huge data partition (i.e. D:). The idea is to split the whole data into multiple data sources (D:\data1 to D:\data6) that more backup tasks can run at the same time. Problem is create more than one Windows VSS snapshot at the same time. For every data source a separate task will be created (i.e. w2k3server_d_data1 and so on). These 6 tasks will be combined in one task group. The backup of this task group will be initiated by a Sesam schedule. To avoid simultaneous VSS snapshot processes, a pre execution is executed for every single task.

Set up the pre-interface

The definition of the pre- and post-process are done via a script with the special name sbc_pre.cmd on the sesam client which performs the backups. In this case it is a Windows server. Therefore on the Windows server (backup client), the interface template sbc_pre.cmd from directory C:\Program Files\skel\templates have to be copied to C:\Program Files\bin\sesam and edited accordingly .

In the Windows ressource kit there is an executable named sleep.exe. To prepare the function, copy this executable to the .\bin\sesam directory of the backup client where the script should run.

Edit the pre-script like the source sniplet below. Then activate the checkbox Execute pre in the task definition on page options 1 in Pre/Post section for every task in the task group.

Source code

Following the key excerpt from the source code of the sbc_pre.cmd file.

...
rem === please insert here your specific actions before backup ===================

rem ###################################
echo start
echo %date% %time%

echo warten mit vss
echo %date% %time%
if %source% == w2k3server_d_data1 "c:\program files\sepsesam\bin\sesam\sleep.exe 45"
if %source% == w2k3server_d_data2 "c:\program files\sepsesam\bin\sesam\sleep.exe 90"
if %source% == w2k3server_d_data3 "c:\program files\sepsesam\bin\sesam\sleep.exe 135"
if %source% == w2k3server_d_data4 "c:\program files\sepsesam\bin\sesam\sleep.exe 180"
if %source% == w2k3server_d_data5 "c:\program files\sepsesam\bin\sesam\sleep.exe 225"
if %source% == w2k3server_d_data6 "c:\program files\sepsesam\bin\sesam\sleep.exe 270"
echo %date% %time%
echo stop


rem ###################################

if not %PRE_ERROR% == 0 goto failed

echo STATUS:OK
exit 0
...

It is also poosible to use the function by Windows Powershell in a similar way. Maybe by using the switch command as jump distributor. The pre-interface (sbc_pre.ps1) is also available in the Sesam's templates directory.