Optional.
The job executes this command just before the job is removed.
Rush guarantees no frames are still running.
Use this command to run cleanup commands for the job.
(New in rush 102.40f and up)
The option -nolog can be specified to disable the
creation of the 'jobdumpcommand.log' file. This is useful
to prevent 'file in use' errors on Windows if you want the
command to remove the entire logdir as part of a cleanup operation.
While the command is running, the job will show a status of 'DumpCmd'
in 'rush -lj' and 'rush -laj' reports. The command will be passed the
jobid in the RUSH_JOBID environment variable, so it's possible for the
script to use rush commands to query the job.
The JobDumpCommand should not run any rush command that requeues
frames, or re-starts the job, to avoid confusing the user. Otherwise
you might make it seem impossible for the user to dump the job.
Exit codes are currently ignored. The stdout and stderr output from the
command is written to a file called 'jobdumpcommand.log' in the
LogDir. This can be disabled if LogDir
is disabled, or if the jobdumpcommand's '-nolog' option is specified,
Here's a state diagram showing the various states the job status transitions through:

Click on the image to see a larger version.
|
JobDumpCommand Examples
|
jobdumpcommand perl //server/share/bin/jobdump.pl
|
Sets command to run a perl script
|
jobdumpcommand -nolog perl //server/share/bin/cleanup.pl
|
Disables the logging to 'jobdumpcommand.log',
so cleanup avoids Windows 'file in use' errors.
|
jobdumpcommand -
|
Disables the jobdumpcommand (Default)
|
Here's an example JobDumpCommand script that pipes the framelist through
a script that generates a web page report, and emails it to the job's owner.
 |
 |
 |
 |
#!/bin/csh -f
# EXAMPLE 'JobDumpCommand' SCRIPT
set $wwwreport = /somewhere/MYPROJECT/html/`logname`/jobreport.html
# CREATE A CUSTOMIZED WEBPAGE REPORT
set logdir = `dirname $RUSH_LOGFILE`
cat $logdir/framelist | \
my_report_generator > $wwwreport
# MAIL THE REPORT TO SOMEONE
Mail -s "$RUSH_JOBID Html Report" `logname` < $wwwreport
|
|
|
 |
 |
 |
 |
The JobDumpCommand should avoid doing anything to the job that might
make it continue running (eg. 'rush -cont'). Though possible, this would
confuse someone manually trying to dump the job, only to find it restarting
itself.