Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

allow for more than one partition in SLURM #271

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

aaronpeikert
Copy link

See documentation https://slurm.schedmd.com/sbatch.html:

If the job can use more than one partition, specify their names in a comma separate list and the one offering earliest initiation will be used with no regard given to the partition name ordering (although higher priority partitions will be considered first).

The current behaviour works, however, it is surprising (only the first partition gets used):

resources <- list(partition = c("short", "long"))
# old, string gets repeated, slurm uses only first
sprintf(paste0("#SBATCH --partition='", resources$partition, "'"))
#> [1] "#SBATCH --partition='short'" "#SBATCH --partition='long'"
# new, comma seperated list
sprintf(paste0("#SBATCH --partition='", paste(resources$partition, collapse = ","), "'"))
#> [1] "#SBATCH --partition='short,long'"

Created on 2021-04-09 by the reprex package (v1.0.0)

See documentation https://slurm.schedmd.com/sbatch.html:
> If the job can use more than one partition, specify their names in a comma separate list and the one offering earliest initiation will be used with no regard given to the partition name ordering (although higher priority partitions will be considered first).
@aaronpeikert aaronpeikert changed the title allow for more than one partition allow for more than one partition in SLURM Apr 9, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant