Ticket #85 (new enhancement)

Opened 5 years ago

Last modified 5 years ago

allow use of "launcher" config file

Reported by: mmckerns Owned by: mmckerns
Priority: minor Milestone: pathos-0.4a
Component: pyina Keywords:
Cc:

Description

allow use of "launcher" config file...

  • thus mpi-config "script" file can be used
  • ... other uses?

Change History

comment:1 Changed 5 years ago by mmckerns

both reading config from file (instead of passing with keywords), and for writing to config file (to save config)

comment:2 Changed 5 years ago by mmckerns

Here's an example...

To do batch requests for X nodes, each with 4 cores
   qsub -l nodes=X:core4:ppn=4 -l walltime=h:m:s   myscript.pbs
To do batch request for X nodes, each with 8 cores
   qsub -l nodes=X:core8:ppn=8 -l walltime=h:m:s   myscript.pbs

Your myscript.pbs can figure out how many cores you've allocated via
---------myscript.pbs-----------
#!/bin/bash -f
# comments are on a line with a # sign followed by a space
# PBS commands have PBS immediately following the # sign
# accounting group set to shc-support, change as needed
#PBS -A shc-support
# put the walltime for your job here, or on the qsub line before batch script name
# PBS -l walltime=0:20:00
#
# Move to the directory from which qsub was run
cd $PBS_O_WORKDIR
#
# how many cores, spread across perhaps more than one node, do I have?
NUMBEROFCORES=`cat $PBS_NODEFILE | wc -l`
# let's run one hello_world MPI task on each core!
mpirun -np $NUMBEROFCORES ./hello_world >> hello_world_out
# if a sequential run on the resources allocated we'd do this. All threads
# would end up on the same (proxy) node, listed first in PBS_NODEFILE
# /hello_world >> hello_world_out
Note: See TracTickets for help on using tickets.