Skip to content
TheChatArchiveThe Chat Archive
vicuna-13b· LMSYSHugging Face Arena Human Preference 55K

How to submit a slurm job s.t. it only starts when another job with given ID has finished?

From a Chatbot Arena battleThe same person sent this prompt to two anonymous models at once. Compare it with koala-13b’s answer.
  1. User

    How to submit a slurm job s.t. it only starts when another job with given ID has finished?

  2. Assistant

    You can use the wait command in Slurm to make sure that a job only starts when another job with a specific ID has finished. The wait command will wait for a specific job or a group of jobs to complete before starting the new job. Here is an example of how you can use the wait command to submit a job that starts when another job with a specific ID has finished:

    # submit the new job
    sbatch myjob
    
    # wait for the other job to finish
    scontrol --wait=123456789
    

    In this example, sbatch myjob will submit the new job and scontrol --wait=123456789 will wait for a job with the ID 123456789 to finish before starting the new job. You can replace 123456789 with the actual ID of the job that you want to wait for.

Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.

Identical first prompt