Hp XC System 2.x Software Manuel d'utilisateur Page 73

  • Télécharger
  • Ajouter à mon manuel
  • Imprimer
  • Page
    / 154
  • Table des matières
  • MARQUE LIVRES
  • Noté. / 5. Basé sur avis des utilisateurs
Vue de la page 72
6.4.1.1 srun Roles
srun options allow y ou submit a job by:
Specifying the parallel enviro nm ent for your job, such as the number of nodes to use,
partition, distribution of processes among nodes, and max im um time.
Controlling the behav ior of your parallel job as it r uns, such as by redirecting or labeling its
output, sending it signals, or specifying its reporting verbosity.
6.4.1.2 srun Modes
Because srun performs several different roles, it has five distinct ways, or modes,inwhich
it can be used:
Simple Mode
In simple mode, srun submits your job to th e local SLURM job
controller, initiates all processes on the specified nodes, and blocks
until needed resources are free to run the job if necessary. M any
control options can change the details of this general pattern.
The s implest way to use the srun command is to dis
tribute the
execution of a serial program (such as a LINUX ut
ility) across a
specified number or ran ge of compute nodes. For
example:
$ srun -N 8 cp ~/data1 /var/tmp/data1
This com m and copies (CP) file data1 from your common h om e
directory into local disk space on each of eight compute n odes. This
is sim il a r to runn ing simple programs in parallel.
Batch Mode
srun can also directly submit complex scripts to the job queue(s)
managed by SLURM for later execution when needed resources
become available and when no higher priority jobs a re pending.
For example:
$ srun -N 16 -b myscript.sh
This command uses the srun -b optiontoplacemyscript.sh
into the batch queue to run later on 16 nodes. Scripts in turn
normally contain either MPI programs, or o ther simple invocat ions
of srun itself (as shown above). The srun -b option s upports
basic, local batch service.
Allocate Mode
When you need to comb ine the job complexity of scripts with
the immediacy of interactive execution, y ou can use the allocate
mode. For example:
$ srun -A -N 4 myscript.sh
This command uses the srun -A option t o allocate specified
resources (four nodes in the above example), spawn a subshell with
access to those resources, and then run multiple jobs using simple
srun commands within the specified script (myscript.sh in the
above example) that t he subshell immediately starts to execute. T his
is similar to allo catin g resources by setting environm ent variables at
the beginning of a script, and then using them for scripted tasks.
No job queues are involved.
Attach
You can monitor or intervene in an already running srun job,
either batch (started with -b), or interactive (allocated - started
with -A), by executing srun again and attaching (-a)tothat
job. For example:
$ srun -a 6543 -j
Using SLURM 6-3
Vue de la page 72
1 2 ... 68 69 70 71 72 73 74 75 76 77 78 ... 153 154

Commentaires sur ces manuels

Pas de commentaire