Search code examples
autosys

Autosys : Achieve dependency for two jobs in a BOX


Scenario : Two jobs are in a BOX_JOB - JOB_1 and JOB_2 , JOB_2 is dependent on JOB_1 Success and should fail whenever JOB_1 fails.

Observation: Once the BOX_JOB gets activated JOB_1 and JOB_2 both gets activated , but JOB_2 continues to be activated even when JOB_1 has completed as failure

JOB_2 JIL

job_type: cmd

....

condition: s(JOB_1)
box_name: BOX_JOB

Solution

  • Check out the box_terminator attribute. Set box_terminator: 1 (or y) in the JIL for JOB_1 and it will terminate BOX_JOB if JOB_1 fails and JOB_2 should go to INACTIVE.

    Check out page 204 (among others) of the Autosys Reference Guide (pdf) for more.