Update 200+ Autosys Jobs
search cancel

Update 200+ Autosys Jobs

book

Article ID: 43574

calendar_today

Updated On:

Products

CA Workload Automation AE - Business Agents (AutoSys) CA Workload Automation AE - Scheduler (AutoSys) Workload Automation Agent

Issue/Introduction

Issue:

We have a need to update a large number of job definitions, 200+.  What is the quickest way to make bulk changes?

For example, modify the job definitions so they run on host2 instead of host1.

 

 

Environment:  

CA workload Automation AE 11.3.x

Platform - ANY

Database -ANY

 

Resolution

Most clients if they need to perform a mass change autorep the job definitions out to a file, modify the file contents and then jil the jobs back into Workload Automation AE (AutoSys).

 

Example:

autorep -q -J MARK* > Mark_jil_file.txt

Edit the file Mark_jil_file.txt

Globally search and replace "machine: host1" with "machine: host2" 

Globally search and replace "insert_job:" with "update_job:"

Save the file.

Then jil the file back in 

 jil < Marks_jil_file.txt

 

 

--- sample before contents ---

insert_job: MARK123 job_type: CMD

command: sleep 30

machine: host1

owner: root

 

--- sample after contents ---

update_job: MARK123 job_type: CMD

command: sleep 30

machine: host2

owner: root

 

Environment

Release: ATSYHA99000-11.3.6-Workload Automation AE-High Availability Option
Component: