You are on page 1of 4

$# = Stores the number of command-line arguments that were passed to the shell p

rogram.
$? = Stores the exit value of the last command that was executed.
$0 = Stores the first word of the entered command (the name of the shell program
).
$* = Stores all the arguments that were entered on the command line ($1 $2 ...).
"$@" = Stores all the arguments that were entered on the command line, individua
lly quoted ("$1" "$2" ...).
-- -----------------------------------------------------------------------------
-------
http://www.bestitdocuments.com/Samples/
http://www.bestitdocuments.com/Samples/Autosys_R113_5x/
http://www.bestitdocuments.com/Samples/Autosys_R113_5x/Workload%20Automantion%20
AE%20Reference%20Guide.pdf
-- -----------------------------------------------------------------------------
-------
http://eco-tone.com/ops/content-software_vendors/platinum/autosys/manuals/atsugu
.pdf
http://www.krishnatraining.com/upload/Autosys-Job-Management-Unix-User-Guide%20%
281%29.pdf
http://unixautosys-refrence.blogspot.com/2008/04/unix-shell-scripting.html
http://support.ca.com/phpdocs/0/common/impcd/r11/troubleshooting/doc/DSM_Adv_top
ics_r11.pdf
http://www.authorstream.com/Presentation/vin_taurus-241754-autosys-job-schedulin
g-vinil-gopalkrishnan-scheduling1-science-technology-ppt-powerpoint/
http://autosys-tutorials.blogspot.com/2011/04/autosys-quick-reference.html
site:wordpress.com autosys .pdf
http://autosys-tutorials.blogspot.com/2011/04/autosys-quick-reference.html
http://writetrends.files.wordpress.com/2009/09/autosys-edk2uaj45cie.pdf
http://writetrends.files.wordpress.com/2009/09/autosys-edk2uaj45cie.pdf
http://support.ca.com/phpdocs/0/common/impcd/r11/troubleshooting/doc/autsys_diag
_tips_110607.pdf
https://support.ca.com/phpdocs/0/7833/TEC510954.pdf
http://www.oit.umn.edu/prod/groups/oit/@pub/@oit/@web/@peoplesoft/documents/cont
ent/oit_content_451314.pdf
http://autosys-tutorials.blogspot.com/
http://datastagetutorialsandtraining.blogspot.com/2012/05/autosys-guide.html
http://supportconnectw.ca.com/public/autosys/infodocs/autosys_cheatsheet.asp
AutoSys commands like "sendevent" and "autorep"?
-- ---------------------------------------------------
# Send Event
alias -x se='sendevent -E'
# Start Job
alias -x fsj='sendevent -E FORCE_STARTJOB -J'
alias -x sj='sendevent -E STARTJOB -J'
# Job Report
ar='autorep -w -J '
fsj='sendevent -E FORCE_STARTJOB -J'
hold='sendevent -E JOB_ON_HOLD -J '
ice='sendevent -E JOB_ON_ICE -J '
jd='job_depends -c -w -J '
killjob='sendevent -E KILLJOB -J '
offhold='sendevent -E JOB_OFF_HOLD -J '
office='sendevent -E JOB_OFF_ICE -J '
se='sendevent -E'
sj='sendevent -E STARTJOB -J'
success='sendevent -E CHANGE_STATUS -s SUCCESS -J '
terminate='sendevent -E CHANGE_STATUS -s TERMINATED -J '
Display JIL (Job Instruction Language):
autorep -w -J <jobname> -q
Load JIL:
jil < JIL_source
Find unique commands currently being used:
autorep -J PARTIALJOBNAME% -q | grep "command:" | awk -F: '{print $2}'|awk '{pri
nt $1}' | sort -u > /tmp/cmds.txt
Meaning of AutoSys status:
STATUS AUTOSTATUS Meaning
RU RUNNING Running
ST STARTING Starting
SU SUCCESS Success
FA FAILURE Failure
TE TERMINATED Terminated
OI ON_ICE On Ice
IN INACTIVE Inactive
AC ACTIVATED Activated
RE RESTART Restart
OH ON_HOLD On Hold
QW QUE_WAIT Queue Wait
RD Refresh Dependencies
RF Refresh Filewatcher
Forecast report from date to infinity:
Code:
job_depends -t -J ALL -F "mm/dd/yyyy"
Display all jobs scheduled to run between these two dates:
Code:
job_depends -t -J ALL -F:06/01/2008 -T:06/30/2008
check if the event procesor is up and running
Code:
chk_auto_up
Display list of available timezones:
Code:
autotimezone -l
Get version information:
Code:
autoflags -a
View Remote Agent log:
Code:
autosyslog -J jobname
AutoSys Unix xwindows GUI control panel
Code:
autosc &
Check Database connections:
Code:
autoping -m machinename -D
-- ------------------------------------
How to list the Autosys jobs thats in failure status using Shell Script
-- --------------
count=`autorep -J jobname | cut -c108-109|grep "FA" |wc -l`
if [ $count -gt 0 ]
then
mailx -s "job failed" a@b.com < sample.txt
fi
-- --------------
Please check the batch file whether it is sending "exit 0" immediately after sub
mitting the backup command.
-- --------------
module load 3rd/autosys/SSS
JOBNAME=$1;
for i in `autorep -j $JOBNAME | grep -v bx`
do
autorep -j $i awk '{
if ($6 = SU)
sendevent -E FORCE_STARTJOB `$i | awk '{print $1}'`
autorep -j `$i | awk '{print $1}'`;
fi
}'
echo `$!`;
done
-- ----------------
autorep -w -J $JOBNAME | awk 'NR>4{print $1}' | while read jobname; do sendevent
-E FORCE_STARTJOB "$jobname"; done
-- ----------------
http://www.unix.com/shell-programming-and-scripting/195143-please-help-me-develo
p-script-autosys-job.html
-- ----------------
#!/bin/bash -p
java dothestuff
rc=$?
if [ $rc -eq 130 ]; then
echo "Killed by SIGINT"
exit 0
fi
exit $rc
-- ------------------

You might also like