AutoSys Training
AutoSys Training
AutoSys Training
AUTOSYS
AUTOSYS
AUTOSYS
AUTOSYS
AUTOSYS
EVENT SERVER
The event server or AutoSys database (the RDBMS) is the data
repository for all system information and events as well as all
job, monitor, and report definitions.Event server refers to the
database where all the AutoSys information, events,and job
definitions are stored.AutoSys can be configured to run using
two databases, or dual-event servers.This feature provides
complete redundancy. Therefore, if you lose one event server due
to hardware, software, or network problems, AutoSys operations
can continue on the second event server without loss of
information or functionality.
6
AUTOSYS
AUTOSYS
REMOTE AGENT
On a UNIX machine, the remote agent is a temporary process
started by the event processor to perform a specific task on a
remote (client) machine. On a Windows machine, the remote
agent is a Windows service running on a remote (client) machine
that is directed by the event processor to perform specific tasks.
The remote agent starts the command specified for a given job,
sends running and completion information about a task to the
event server, then exits. If the remote agent is unable to transfer
the information, it waits and tries again until it can successfully
communicate with the database.
8
AUTOSYS
9
AUTOSYS
AUTOSYS
AutoSys Instance
An AutoSys instance is one licensed version of AutoSys software running as
an AutoSys server with one or more clients, on a single machine or on
multiple machines. An AutoSys instance is defined by the instance ID, which
is a capitalized three-letter identifier defined by the $AUTOSERV
environment variable. An instance uses its own event server and event
processor and operates independently of other AutoSys instances.
You may want to install multiple AutoSys instances. For example, you may
want to have one instance for production and another for development.
Multiple instances can run on the same machine, and can schedule jobs on the
same machines without interfering or affecting the other instances.
11
AUTOSYS
Job types:
File Watcher Jobs - A file watcher job is similar to a command job. However, instead of
starting a user-specified command on a client machine, it starts a process that monitors for the
existence and size of a specific operating system file. When that file reaches a certain minimum
size, and is no longer growing in size, the file watcher job completes successfully, indicating that
the file has arrived.
Command Jobs – The command can be a shell script or an executable program. When this
type of job is run, the result is the execution of a specified command on a client machine.
Box Jobs - In the Autosys environment, the box job (or box) is a container of other jobs. A box
job can be used to organize and control process flow. The box itself performs no actions,
although it can trigger other jobs to run. An important feature of this type of job is that boxes can
be put inside of other boxes.
12
AUTOSYS
Job Attributes:
Command Job Attributes : Job Name, Command, Machine name, Starting Conditions.
File Watcher Job Attributes : Job Name, File Name to Watch For, Machine Name, Starting
Conditions
AUTOSYS
Job States:
Job State Status
INACTIVE The job has not yet been processed. Either the job has never been run, or its
status was intentionally altered to “turn off”its previous completion status
ACTIVATED The top-level box that this job is in is now in the RUNNING state, but the job
itself has not started yet.
STARTING The event processor has initiated the start job procedure with the RA
(Resource Allocation).
RUNNING The job is running. If the job is a box job, this value simply means that the
jobs within the box may be started (other conditions permitting). If it is a
command or file watcher job,the value means that the process is actually running
on the remote machine.
SUCCESS The job exited with an exit code equal to or less than the“maximum exit code
for success.”
FAILURE The job exited with an exit code greater than the “maximum exit code for
success.”
14
AUTOSYS
Job States:
Job State Status
TERMINATED The job terminated while in the RUNNING state. A job can be terminated if a
user sends a KILLJOB event or if it was defined to terminate if the box it is in
failed.
RESTART The job was unable to start due to hardware or application problems, and has
been scheduled to restart.
QUE_WAITThe job can logically run (that is, all the starting conditions have been met), but there
are not enough machine resources available.
ON_HOLD This job is on hold and will not be run until it receives the JOB_OFF_HOLD
event.
ON_ICE This job is removed from all conditions and logic, but is still defined to
Autosys. Operationally, this condition is like deactivating the job. It will remain
on ice until it receives the JOB_OFF_ICE event.
15
AUTOSYS
ON HOLD ON ICE
AUTOSYS
Command Job
insert_job: eedhnonemplc job_type: c
command: echo adding jobs into box job
machine: UPCLT2D08
owner: 100790@GECISCGW
description: ‘our first autosys job’
permission:
std_out_file: c\:\temp\stdoutfile.txt
std_err_file: c\:\temp\stderrfile.txt
alarm_if_fail: 1
17
AUTOSYS
insert_job: training_box_1 job_type: b
Box Jobs
owner: 100790@GECISCGW
description: “our first box job"
alarm_if_fail: 1
training_box_1
insert_job: cmd_job1 job_type: c
box_name: training_box_1
command: echo cmd_job1 inside the box
machine: UPCLT2D08
owner: 100790@GECISCGW
cmd_job1
alarm_if_fail: 1
AUTOSYS
insert_job: EOD_watch
job_type: f
machine: tibet
watch_file: /tmp/EOD_trans_file
watch_interval: 60
watch_file_min_size: 50000
19
AUTOSYS
JIL Sub-commands
AUTOSYS
Calendars:
Calendars are defined using the Calendar defn
Window from the Unix GUI. It looks something
like shown here.
insert_job: eedhpittoic
type : c
command: /usr/home/something.bat
start_times: ‘10:00, 18:00, 23:00’
run_calendar: ‘working_days’
exclude_calendar: ‘gecis_holidays’
Std_out_file: /usr/home/log/eedhpittoic.out
Std_err_file: /usr/home/log/eedhpittoic.err
21
AUTOSYS
Autosys Commands
gcoasys01:autocorp:COP $ autoflags -a
_G3 SOLAR ORA 4.0 _0208 831256fa gcoasys01
AUTOSYS
Autosys Commands
autorep - One of the most important commands. Reports information about a
job, jobs within boxes, machines, and machine status. Also
reports information about job overrides and global variables.
autorep –j epy08b444s01 –r –1 –d
autorep –j epy08b444s01 –r –2 –d
autorep –j epy08b444s01
23
AUTOSYS
Autosys Commands
autorep - Also used for seeing the JIL of a job.
autorep –j jobname –q
autorep –j ALL –q
jil <file1.jil
24
AUTOSYS
Autosys Commands
autosyslog -Displays the Event Processor and Remote Agent Log Files
autosyslog -e
tail -f $AUTOUSER/out/event_demon.$AUTOSERV
*** To break out type control-c (^c) ***
AUTOSYS
Autosys Commands
chase - Chase checks if the jobs and remote agents are still running.
E.g chase –A –E
AUTOSYS
Autosys Commands
eventor –f -q
AUTOSYS
Autosys Commands
job_depends –c –d -t –J jobname
AUTOSYS
Autosys Commands
AUTOSYS
AUTOSYS
Thank You.