I need to create an autosys job that run on Saturday and Sunday only at Noon and 11:00 p.m. CST below is the script that I wrote based on what I saw online.
I'm new to this , can someone else please check and confirm if there's any other thing that I'm missing that can cause some issue?
insert_job: name job_type: CMD
command: /directory/zzz/xxx.ksh /directory/xxx/xxx
machine: ZZZ
owner: user
permission:
date_conditions: 1
days_of_week: sa,su
start_mins: 5,20,35,50
run_window: "12:00 , 23:00"
condition: s(XXX_XXX_CONTROL)
description: "pull xxx files"
std_out_file: $dummy.out
std_err_file: $dummy.err
alarm_if_fail: 1
profile: /directory/directory.profile
Your block for determining which days your jobs will run looks correct:
date_conditions: 1
days_of_week: sa,su
But your block for determining when on those days your job runs is off:
start_mins: 5,20,35,50 # specifies how many minutes after the top of an hour a job starts
run_window: "12:00 , 23:00"
As your JIL is now, the job will run 4 times an hour for 11 hours:
12:05, 12:20, 12:35, 12:50, 13:05, 13:20, ..., 22:35, and 22:50
You most likely want specific start_times:
start_times: "12:00, 23:00"
start_times and start_mins can't be defined in the same JIL, and run_window would be extraneous here, so it can be omitted along with start_mins.
You can also take a look at the must_start_times attribute if you want an alarm if your jobs didn't start on time.