[slurm-dev] difference between sbatch and srun -b

1 view
Skip to first unread message

Peter Kjellstrom

unread,
Jul 30, 2007, 11:46:02 AM7/30/07
to slur...@lists.llnl.gov
Hello people,

I was under the impression that srun -b was "the old" way of doing sbatch and
that two could be used equally.

However, as I tried to get an example from the ICLC 2006 tutorial (doc section
on the web page) to work I found out that it's not at all the same thing. I
was trying to get slurm to accept options using #SLURM opt=val lines in
the .sh file i sent to sbatch. This turned out only to work with srun -b
though...

Can anyone clarify this, what's supposed to work and what's the "right" way to
do it.

If I can chose I'd much rather give my users sbatch, srun and salloc (not
srun -b, -A ..) since I anticipate some confusion...

I'm running slurm version 1.2.11.

Tia,
Peter

signature.asc

jet...@llnl.gov

unread,
Jul 30, 2007, 7:55:00 PM7/30/07
to slur...@lists.llnl.gov, Peter Kjellstrom
>Content-Type: application/pgp-signature; name=signature.asc
>Content-Description: This is a digitally signed message part.
>
>Attachment converted: Macintosh HD:signature.asc ( / ) (00761FEA)


If you look closely at the srun and sbatch options you will notice
some subtle differences. We felt the least confusing option was
to require that sbatch options in the script be preceded with
"#SBATCH" rather than "#SLURM". Since you are just starting to
use slurm, please use the sbatch command and "#SBATCH" options
in the script.

The ICLC materials were prepared before slurm version 1.2 was
available, so they do not include the very latest information.
--
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Morris "Moe" Jette jet...@llnl.gov 925-423-4856
Integrated Computational Resource Management Group fax 925-423-6961
Livermore Computing Lawrence Livermore National Laboratory
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Peter Kjellstrom

unread,
Jul 31, 2007, 3:11:38 AM7/31/07
to slur...@lists.llnl.gov, jet...@llnl.gov
On Tuesday 31 July 2007, jet...@llnl.gov wrote:
...

> > same thing. I was trying to get slurm to accept options using #SLURM
> > opt=val lines in the .sh file i sent to sbatch. This turned out only to
> > work with srun -b though...
...

> If you look closely at the srun and sbatch options you will notice
> some subtle differences. We felt the least confusing option was
> to require that sbatch options in the script be preceded with
> "#SBATCH" rather than "#SLURM". Since you are just starting to
> use slurm, please use the sbatch command and "#SBATCH" options
> in the script.
>
> The ICLC materials were prepared before slurm version 1.2 was
> available, so they do not include the very latest information.

I fully understand if that tutorial is outdated. But since this information is
neither in the sbatch man-page, the quickstart guide nor the FAQ...

When information is that hard to find it often means that you're trying to do
something other people consider "wrong" or unimportant. For us this may very
well be _the_ typical use case (a batch script with node/core and walltime
specification). So obviously we want to get it right from the beginning
(still setting things up and writing the user documentation).

/Peter

signature.asc
Reply all
Reply to author
Forward
0 new messages