Hi,
I have about 40 NT backups failing regularly, due to failed objects.
In reality, we have numerous failures that aren't critical, so a message "Failed Objects 53" for example appears in the sysout, and the job is investigated. We close off any cases if the failures are below a threshold (usually 100, dependant on the backup).
I'd like to automate this using the DO commmands - is there anyway of setting something up that essentially says, STATEMENT = "Failed Objects <100" THEN JOB OK ?
I've recently started using the "Steps" tab to improve our batch and still have lots to learn; I can't figure this one out and it would be a huge advantage if it could be used like this.
Thanks
Ross
Maximum number of failed objects in Backup
- Ross_T_Boss
- Nouveau
- Posts: 21
- Joined: 08 Aug 2008 12:00
- Ross_T_Boss
- Nouveau
- Posts: 21
- Joined: 08 Aug 2008 12:00
Thanks for that - I assume you use 'DO' Set-var %%FO = 1 to do that?
It is a little more complicated, but if it is possible I'd like to fail the job dependant on the number.
So for instance:
ANS1802E Incremental backup of 'server1' finished with 4 failed objects - Would be OK
ANS1802E Incremental backup of 'server1' finished with 317 failed objects - Would be NOTOK as >100 failed objects
Is there any of way of having CTM pick up the figure in the log and use it in such a way?
Cheers
Ross
It is a little more complicated, but if it is possible I'd like to fail the job dependant on the number.
So for instance:
ANS1802E Incremental backup of 'server1' finished with 4 failed objects - Would be OK
ANS1802E Incremental backup of 'server1' finished with 317 failed objects - Would be NOTOK as >100 failed objects
Is there any of way of having CTM pick up the figure in the log and use it in such a way?
Cheers
Ross
If I understand:
So, you have a number in one sysout of some job and you want to cut this number and compare it?
In this case i would prefere to use 'copy sysout' to another file/location from this job. Then append special job - script at the end of chain which will cut the number and compare it with your treshold.
FO=`cat $sysout | cut -f8 -d' '`
[ $FO -gt 100 ] && exit 1;
The CM for distributed environment can not parse the sysout and evaluate the parts of it and use it later.
In Mainframe i think there is such 'utility' (control-o??)
So, you have a number in one sysout of some job and you want to cut this number and compare it?
In this case i would prefere to use 'copy sysout' to another file/location from this job. Then append special job - script at the end of chain which will cut the number and compare it with your treshold.
FO=`cat $sysout | cut -f8 -d' '`
[ $FO -gt 100 ] && exit 1;
The CM for distributed environment can not parse the sysout and evaluate the parts of it and use it later.
In Mainframe i think there is such 'utility' (control-o??)