Next revision | Previous revision |
doku:sge [2015/04/09 13:29] – created ir | doku:sge [2016/06/21 11:31] (current) – ir |
---|
===== Quick Start ===== | ====== Submitting batch jobs ====== |
| |
[[doku:win2vsc|How to connect from Windows?]] | ===== Sun grid engine (SGE) ===== |
| ==== The job script ==== |
| It is recommended to write the job script using a [[doku:win2vsc&#the_job_filetext_editors_on_the_cluster|text editors]] on the VSC //Linux// cluster. |
| Editors in //Windows// may add additional invisible characters to the job file which render it unreadable and, thus, it is not executed. |
| |
==== Login ==== | === A - the header of the job script === |
| |
- Log in to your university's designated login server via SSH: <code># Uni Wien | |
ssh <username>@vsc2.univie.ac.at | |
# TU Wien | |
ssh <username>@vsc2.tuwien.ac.at | |
# Boku Wien | |
ssh <username>@vsc2.boku.ac.at | |
</code> | |
| |
- Transfer your programs and data/input files to your home directory. <code> scp <filename> <username>@vsc.univie.ac.at:~/ | |
</code> | |
- (Re-)Compile your application. Please use the latest "Intel" MPI-Environment as described in [[doku:mpi|MPI Environment]]. | |
| |
==== The job script ==== | |
=== header === | |
<code>#$ -N <job_name> | <code>#$ -N <job_name> |
#$ -pe mpich <slots> | #$ -pe mpich <slots> |
#$ -m beas # all job events sent via email </code> | #$ -m beas # all job events sent via email </code> |
- "<job_name>" is a freely chosen descriptive name, | - "<job_name>" is a freely chosen descriptive name, |
- "<slots>" is the number of processor cores that you want to use for the calculation. To ensure exclusive reservation of the compute nodes for your job, the value for "<slots>" has to be a multiple of 8. | - "<slots>" is the number of processor cores that you want to use for the calculation. The compute nodes are always reserved for your job, exclusively. If the value for "<slots>" is no integral multiple of 16, it is corrected to the next larger integral multiple of 16. |
- "-V" declares that all environment variables in the qsub command's environment are to be exported to the batch job. | - "-V" declares that all environment variables in the qsub command's environment are to be exported to the batch job. |
- "-l" specifies the job's runtime. This explicit specification is in particular advisable for jobs with short run times, i.e., several hours or even minutes. In order to **reduce the time in the queue**, see also the section on [[doku:runtime|maximum runtime specification.]] | - "-l" specifies the job's runtime. This explicit specification is in particular advisable for jobs with short run times, i.e., several hours or even minutes. In order to **reduce the time in the queue**, see also the section on [[doku:runtime|maximum runtime specification.]] |
- "-M <email address>; -m beas" request E-Mail notifications concerning job events (b .. beginning, e .. end, a .. abort or reschedule, s .. suspend). | - "-M <email address>; -m beas" request E-Mail notifications concerning job events (b .. beginning, e .. end, a .. abort or reschedule, s .. suspend). |
| |
=== run executable === | === B - run executable === |
The job can be started in several ways, | The job can be started in several ways, |
- as single core job on one core (no MPI) task <code>./<executable></code> | - as single core job on one core (no MPI) task <code>./<executable></code> |
| |
| |
==== example ==== | ==== Example ==== |
Here is an example job-script, requesting 32 processor cores, which will run for a maximum of 3 hours and sends emails at the beginning and at the end of the job: <code> | Here is an example job-script, requesting 32 processor cores, which will run for a maximum of 3 hours and sends emails at the beginning and at the end of the job: <code> |
#$ -N hitchhiker | #$ -N hitchhiker |
- View all jobs in the queue: <code>$ qstat -u \*</code> | - View all jobs in the queue: <code>$ qstat -u \*</code> |
| |
For advanced topics see also [[doku:advanced_topics|Sun grid engine (SGE)]]. | ==== Advanced topics ==== |
| |
| *[[doku:runtime|Faster job execution by runtime specification]] |
| *[[doku:epilog|Epilog scripts: copying back data after job termination ]] |
| *[[doku:job_chains|Job chains]] |
| *[[doku:job_arrays|Job arrays]] |
| *[[doku:ompmpi|Hybrid OpenMP/MPI jobs ]] |
| *[[doku:memory_running_jobs|Find out memory usage of running jobs]] |
| *[[doku:copy|Start copying process]] |
| *[[doku:tight_integration|Tight integration]] |
| *[[doku:foreingprojectjob|Using Resources of foreign Projects]] |
| *[[doku:chge_parameters|Changing job parameters of already submitted jobs (qalter)]] |
| *[[doku:miscellaneous|Miscellaneous]] |
| |
| |