SoftTree Technologies SoftTree Technologies
Technical Support Forums
RegisterSearchFAQMemberlistUsergroupsLog in
Job execution errors

 
Reply to topic    SoftTree Technologies Forum Index » 24x7 Scheduler, Event Server, Automation Suite View previous topic
View next topic
Job execution errors
Author Message
Malcolm Wise



Joined: 26 Jan 2000
Posts: 22

Post Job execution errors Reply with quote

I have a .exe program written in PowerBuilder 7 which I am running using 24x7 job type 'program or document file'. I am setting an exit code using the win32 api function ExitProcess in Kernel32.dll. If I return a non-zero value as the exit code, the job log shows that the job 'finished with process exit code error: 1 - Incorrect Function'. I have set the job to run synchronously and to create a semaphore file if a job execution error occurs. 24x7 does not create the semaphore file. What sort of exit code does 24x7 need to regard it as an error serious enough to create my semaphore file? I know I can probably code round this by using 24x7 script, but if you could give me an answer it would be much appreciated!
I'm using 24x7 version 1.6.3 on NT4 SP6

TIA

Wed Mar 15, 2000 8:10 am View user's profile Send private message
SysOp
Site Admin


Joined: 26 Nov 2006
Posts: 6501

Post Re: Job execution errors Reply with quote

24x7 does not consider program return code as a sign of success or error. Many programs return non-zero codes in normal situations.

If you want to capture that error code you can run a .BAT file from which you start your program, then you would use ERRORLEVEL variable to put some more logic into that .BAT file so that it can do something to notify 24x7

Something like the following

del flag.txt
myprogram.exe
if ERRORLEVEL = 0 exit
dir *.* > flag.txt
exit

So 24x7 can check for the presense of flag.txt file after it runs this.BAT
If the file exists then your program returned non-zero code.

: I have a .exe program written in PowerBuilder 7 which I am running using 24x7
: job type 'program or document file'. I am setting an exit code using the
: win32 api function ExitProcess in Kernel32.dll. If I return a non-zero
: value as the exit code, the job log shows that the job 'finished with
: process exit code error: 1 - Incorrect Function'. I have set the job to
: run synchronously and to create a semaphore file if a job execution error
: occurs. 24x7 does not create the semaphore file. What sort of exit code
: does 24x7 need to regard it as an error serious enough to create my
: semaphore file? I know I can probably code round this by using 24x7
: script, but if you could give me an answer it would be much appreciated!
: I'm using 24x7 version 1.6.3 on NT4 SP6

: TIA

Wed Mar 15, 2000 12:08 pm View user's profile Send private message
Display posts from previous:    
Reply to topic    SoftTree Technologies Forum Index » 24x7 Scheduler, Event Server, Automation Suite All times are GMT - 4 Hours
Page 1 of 1

 
Jump to: 
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


 

 

Powered by phpBB © 2001, 2005 phpBB Group
Design by Freestyle XL / Flowers Online.