When your job starts, the script or program specified in the <run>...</run> tags will begin.
It can be any script (e.g. perl, python, bat) or an executable. Commonly a script is used to
handle file copy logistics and start the executable, then clean up after the job is done.
This example is a .bat script.
- set up a temporary directory on the compute node for your files
- copy the files your job needs to the temporary directory
- run your program(s)
- copy the output files back to the CTC fileservers
- delete your files in the temporary directory on the compute node
- end the batch session
REM Create a clean local temp folder, T:\myuserid
call TDirCreate.bat
REM Change the current working directory
cd /d T:\%USERNAME%
REM Copy executable and data files to the current working directory
copy h:\users\%USERNAME%\quick.exe
REM Run the program
quick.exe 1>quick.out2>quick.err
REM Copy results back to fileserver
copy /Y quick.* h:\users\%USERNAME%
REM Delete the local temp folder and everything in it
call TDirDelete.bat
REM Release the nodes and end the job
vsched -cancel
|
More XML and Script Examples