Article 1108971 has an article that should prove useful to you: http://www-1.ibm.com/support/entdocview.wss?uid=swg21108971. While this article discusses the problem in the context of PRESCHEDULECMD/POSTSCHEDULECMD, the same principles apply to schedules where the ACTION is COMMAND.
Alternatively you can see http://msgs.adsm.org/cgi-bin/get/adsm0407/154/1.html. Attached is a copy of the sample script. Regards, Andy Andy Raibeck IBM Software Group Tivoli Storage Manager Client Development Internal Notes e-mail: Andrew Raibeck/Tucson/[EMAIL PROTECTED] Internet e-mail: [EMAIL PROTECTED] The only dumb question is the one that goes unasked. The command line is your friend. "Good enough" is the enemy of excellence. "ADSM: Dist Stor Manager" <[EMAIL PROTECTED]> wrote on 08/10/2004 07:34:51: > Hi listers, > > I've installed TSM DP for MS-Exchange V5.2.1.0 on a Windows 2003 MSCS > cluster. > My TSM server V5.2.2.5 runs under Windows 2003 native. > > But the client schedule for the DP backup fails with ANR2579E/ANR1512E > with Return Code = 1. > > Running the cmd file on the cluster the backup works fine, only the > schedule isn't working. > > Does anybody can help me o fix that. > > > Thanks > Ronald
@echo off REM This script is a sample only, and is provided on REM an "as is" basis, without warranty of any kind. set HIGHRC=0 set OUTFILE=C:\MyScript.txt set SVC1="service1" set SVC2="service2" set SVC3="service3" if exist %OUTFILE% del %OUTFILE% echo ---------------------------------------------------------------------- >> %OUTFILE% 2>&1 echo %date% %time% - Stopping %SVC1% >> %OUTFILE% 2>&1 echo ---------------------------------------------------------------------- >> %OUTFILE% 2>&1 net stop %SVC1% >> %OUTFILE% 2>&1 set LASTRC=%errorlevel% if %LASTRC% gtr %HIGHRC% set HIGHRC=%LASTRC% if %LASTRC% equ 0 ( echo net stop for %SVC1% complete >> %OUTFILE% 2>&1 ) else ( echo net stop for %SVC1% failed, rc=%LASTRC% >> %OUTFILE% 2>&1 ) echo ---------------------------------------------------------------------- >> %OUTFILE% 2>&1 echo %date% %time% - Stopping %SVC2% >> %OUTFILE% 2>&1 echo ---------------------------------------------------------------------- >> %OUTFILE% 2>&1 net stop %SVC2% >> %OUTFILE% 2>&1 set LASTRC=%errorlevel% if %LASTRC% gtr %HIGHRC% set HIGHRC=%LASTRC% if %LASTRC% equ 0 ( echo net stop for %SVC2% complete >> %OUTFILE% 2>&1 ) else ( echo net stop for %SVC2% failed, rc=%LASTRC% >> %OUTFILE% 2>&1 ) echo ---------------------------------------------------------------------- >> %OUTFILE% 2>&1 echo %date% %time% - Stopping %SVC3% >> %OUTFILE% 2>&1 echo ---------------------------------------------------------------------- >> %OUTFILE% 2>&1 net stop %SVC3% >> %OUTFILE% 2>&1 set LASTRC=%errorlevel% if %LASTRC% gtr %HIGHRC% set HIGHRC=%LASTRC% if %LASTRC% equ 0 ( echo net stop for %SVC3% complete >> %OUTFILE% 2>&1 ) else ( echo net stop for %SVC3% failed, rc=%LASTRC% >> %OUTFILE% 2>&1 ) echo ---------------------------------------------------------------------- >> %OUTFILE% 2>&1 echo %date% %time% - exiting script with highest rc=%HIGHRC% >> %OUTFILE% 2>&1 echo ---------------------------------------------------------------------- >> %OUTFILE% 2>&1 exit %HIGHRC%
