 |
SoftTree Technologies
Technical Support Forums
|
|
Author |
Message |
k140926
Joined: 18 Nov 2008 Posts: 9 Country: United States |
|
24x7 job abort email |
|
I have 24x7 setup to send me an email when a job aborts. For some reason i keep getting these job abort emails, but when i check the job has sucessfully run. The email keeps getting triggered right when the job starts. I cant figure out what is causing it to think the job has aborted. Any suggestions?
|
|
Tue Nov 18, 2008 3:46 pm |
|
 |
SysOp
Site Admin
Joined: 26 Nov 2006 Posts: 7949
|
|
|
|
Please change the asynchronous job mode to synchronous. That's the way it is supposed to run.
PS. Async. mode is a special thing not used for regular jobs.
|
|
Tue Nov 18, 2008 4:54 pm |
|
 |
k140926
Joined: 18 Nov 2008 Posts: 9 Country: United States |
|
|
|
thats not the problem. It seems to be a problem with the script. It doesn't seem like the RunAndWait command is returning a value (PID variable). when i ran the debug the PID varaible never returned a value, see below: It skips after the RunAndWait command to SETFAIL:
Dim fail, boolean, false
Dim MainFilePath, string, "D:\\Batch Files\\Scheduled Tasks\\"
Dim FullCmd, string
Dim RunPath, string
Dim PID, number
Dim ExitCode, number
dim User, string, "vdr_service_admin"
dim pwd, string, "*******"
dim domain, string, "VDRPROD-CPF"
OnErrorGoto SetFail
Concatex("\"",MainFilePath, SubFolder, "\\", FileName, "\"", FullCmd)
Concatex("\"", MainFilePath, Subfolder, "\"", RunPath)
RunAndWait(FullCmd, RunPath, WaitInSec, PID)
ProcessGetExitCode(ExitCode)
NotEqual(ExitCode, 0, fail)
IfThen(Fail, SetFail)
set fail, false
Goto ReturnResult
SETFAIL:
OnErrorStop
Set fail, true
GoTo ReturnResult
RETURNRESULT:
Return fail
|
|
Thu Nov 20, 2008 6:14 pm |
|
 |
SysOp
Site Admin
Joined: 26 Nov 2006 Posts: 7949
|
|
|
|
I don't buy this argument. You have some problem with the command you start via RunAndWait. It skips to SETFAIL because you told it so "OnErrorGoto SetFail" meaning that in case of an error it need to jump to SETFAIL label where you have your error handler and it does just that.
|
|
Thu Nov 20, 2008 6:17 pm |
|
 |
SysOp
Site Admin
Joined: 26 Nov 2006 Posts: 7949
|
|
|
|
By the way, I edited your post and masked password just in case. You never know who is reading pages here, could be some of your coworkers whom you don't trust.
|
|
Thu Nov 20, 2008 6:19 pm |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|
|