Site Tools


howtouseslurm_004

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
howtouseslurm_004 [2020/12/17 11:08] tmatejukhowtouseslurm_004 [2023/08/01 01:08] (current) – external edit 127.0.0.1
Line 1: Line 1:
 +**Using dependencies in Slurm**
 +
 +Slurm has a fairly robust set of dependencies you can use.  These are set when you submit the job and can be used for setting up pipelines.  A job can depend on more than one other job as well.
 +
 +To use dependencies, submit the job with the following switch.  If using multiple dependency types, they should be comma seperated:
 +<code>
 +-d, --dependency=<dependency_list>
 +</code>
 +
 +----
 +
 You may want to run a set of jobs sequentially, so that the second job runs only after the first one has completed. This can be accomplished using Slurm's job dependencies options. For example, if you have two jobs, ''job1.batch'' and ''job2.batch'', you can utilize job dependencies as in the example below : You may want to run a set of jobs sequentially, so that the second job runs only after the first one has completed. This can be accomplished using Slurm's job dependencies options. For example, if you have two jobs, ''job1.batch'' and ''job2.batch'', you can utilize job dependencies as in the example below :
  
Line 23: Line 34:
 </code> </code>
  
 +----
  
 Making a job depend on the completion of several other jobs: example below :  Making a job depend on the completion of several other jobs: example below : 
Line 41: Line 53:
 203          job3.batch      PD   afterany:201,afterany:202  203          job3.batch      PD   afterany:201,afterany:202 
 </code>  </code>
 +
 +----
 +
  
  
-*) see more at [[https://hpc.nih.gov/docs/job_dependencies.html]]+*) [[https://hpc.nih.gov/docs/job_dependencies.html]] \\ 
 +*) [[http://www.hpc.caltech.edu/documentation/faq/dependencies-and-pipelines]]
  
howtouseslurm_004.1608199691.txt.gz · Last modified: 2023/08/01 06:38 (external edit)