This shows you the differences between two versions of the page.
| Both sides previous revision Previous revision Next revision | Previous revision | ||
|
guide:moab [2011/09/30 14:39] kevin |
guide:moab [2021/12/09 16:42] (current) |
||
|---|---|---|---|
| Line 1: | Line 1: | ||
| ======A Guide to the Moab Job Scheduler at the CHPC====== | ======A Guide to the Moab Job Scheduler at the CHPC====== | ||
| + | |||
| + | To submit jobs to run on CHPC systems, you must write a shell script that will run your job, and then use '' | ||
| ====SUN HYBRID SYSTEM==== | ====SUN HYBRID SYSTEM==== | ||
| Line 7: | Line 9: | ||
| The Sun system is divided into // | The Sun system is divided into // | ||
| - | - '' | + | - '' |
| + | - '' | ||
| - '' | - '' | ||
| - '' | - '' | ||
| - '' | - '' | ||
| - '' | - '' | ||
| - | - '' | + | - '' |
| - | Users can specify different cluster partitions by adding a '' | + | Users can specify different cluster partitions by adding a '' |
| - | msub -l partition=nehalem | + | msub -l feature=nehalem |
| You are able to choose more than one partition, provided, of course, your code can execute on the requested hardware. The syntax looks like: | You are able to choose more than one partition, provided, of course, your code can execute on the requested hardware. The syntax looks like: | ||
| - | msub -l partition=nehalem|harpertown | + | msub -l feature=nehalem|harpertown |
| to use both '' | to use both '' | ||
| - | ===NEW! Westmere | + | ===Sun and Dell Westmere |
| - | The new **Westmere** | + | The new **Westmere** |
| - | Please note that each node of // | + | **NB:** The new Dell cluster runs a different O/S from the Sun clusters. |
| + | |||
| + | Please note that each node of Westmere | ||
| - | To run on the Westmere | + | To run on one of the Westmere |
| For example, in your script | For example, in your script | ||
| - | #MSUB -l partition=westemere | + | #MSUB -l feature=westmere |
| #MSUB -l nodes=1: | #MSUB -l nodes=1: | ||
| Or on the command line | Or on the command line | ||
| - | msub -l partition=westmere -l nodes=1: | + | msub -l feature=westmere -l nodes=1: |
| + | |||
| + | See the **// | ||
| ===QUEUES=== | ===QUEUES=== | ||
| Line 62: | Line 69: | ||
| ===MPI job=== | ===MPI job=== | ||
| - | Edit the file with, eg, | + | Edit the file with, for example, '' |
| + | <file bash mpi.job> | ||
| + | #/bin/sh | ||
| + | #MSUB -l nodes=1: | ||
| + | #MSUB -l feature=nehalem|harpertown | ||
| + | #MSUB -l walltime=3: | ||
| + | #MSUB -m be | ||
| + | #MSUB -V | ||
| + | #MSUB -o / | ||
| + | #MSUB -e / | ||
| + | #MSUB -d / | ||
| + | #MSUB -mb | ||
| + | ##### Running commands | ||
| + | exe=/ | ||
| + | nproc=`cat $PBS_NODEFILE | wc -l` | ||
| + | mpirun -np $nproc -machinefile $PBS_NODEFILE $exe > users.out | ||
| + | </ | ||
| - | vi mpi.job | ||
| - | |||
| - | --------------- | ||
| - | |||
| - | #/bin/sh | ||
| - | #MSUB -l nodes=1: | ||
| - | #MSUB -l partition=nehalem|harpertown | ||
| - | #MSUB -l walltime=3: | ||
| - | #MSUB -m be | ||
| - | #MSUB -V | ||
| - | #MSUB -o / | ||
| - | #MSUB -e / | ||
| - | #MSUB -d / | ||
| - | #MSUB -mb | ||
| - | ##### Running commands | ||
| - | exe=/ | ||
| - | nproc=`cat $PBS_NODEFILE | wc -l` | ||
| - | mpirun -np $nproc -machinefile $PBS_NODEFILE $exe > users.out | ||
| - | |||
| - | |||
| - | ---------------------------- | ||
| To submit this job (the '' | To submit this job (the '' | ||
| Line 90: | Line 92: | ||
| msub mpi.job | msub mpi.job | ||
| - | by default the job will be submitted to small queue since it only requests 8 processors. | + | By default the job will be submitted to small queue since it only requests 8 processors. |
| + | |||
| + | **NB:** Your job MUST be located on the scratch partition, otherwise it will fail to run. | ||
| ===Interactive job=== | ===Interactive job=== | ||
| - | You have to specify '' | + | You have to specify '' |
| msub -I | msub -I | ||
| + | There will be a delay while the scheduler allocates and logs you into a free compute node. You can target | ||
| + | a specific free node: | ||
| + | |||
| + | msub -I -l nodes=cnode-9-23 | ||
| - | ===Test | + | ===Test |
| Users can use the same script and just change the walltime to 10 minutes or less and then change | Users can use the same script and just change the walltime to 10 minutes or less and then change | ||
| - | #MSUB -l partition=nehalem|harpertown | + | #MSUB -l feature=nehalem|harpertown |
| to | to | ||
| - | #MSUB -l partition=test | + | #MSUB -l feature=test |
| in the job script. | in the job script. | ||
| Line 111: | Line 119: | ||
| ===PARTITIONS=== | ===PARTITIONS=== | ||
| - | - //C2070// (8 of these Nvidia GPU cards are available) | + | - //C2070// (8 of these Nvidia |
| - | - //C1060// (12 of these Nvidia GPU cards are available) | + | - //C1060// (12 of these Nvidia |
| - | Note that GPU cluster has 5 compute nodes and each node has 16 processors and 4 GPUs | + | Note that GPU cluster has 5 compute nodes and each node has 16 processors and 4 GPUs. In addition the head node (login node) has one each of C2070 and C1060 GPU cards. |
| ===Job script example:=== | ===Job script example:=== | ||
| Line 121: | Line 129: | ||
| Edit with '' | Edit with '' | ||
| + | <file bash mpi.job> | ||
| + | ###These lines are for Moab | ||
| + | #MSUB -l nodes=2: | ||
| + | #MSUB -l feature=c2070 | ||
| + | #MSUB -l walltime=168: | ||
| + | #MSUB -m be | ||
| + | #MSUB -V | ||
| + | #MSUB -o / | ||
| + | #MSUB -e / | ||
| + | #MSUB -d / | ||
| + | #MSUB -mb | ||
| + | ##### Running commands | ||
| + | echo " | ||
| + | echo " | ||
| + | cat $PBS_NODEFILE | ||
| + | echo " | ||
| + | cat $PBS_NODEFILE|sed -e ' | ||
| + | echo " | ||
| + | echo " | ||
| + | cat $PBS_STEP_OUT.hostfile | ||
| + | exe=location of the executable | ||
| + | nproc=`cat $PBS_NODEFILE | wc -l` | ||
| + | cd / | ||
| + | mpirun $nproc $exe > / | ||
| + | </ | ||
| - | -------------------------------------------------- | ||
| - | |||
| - | ###These lines are for Moab | ||
| - | #MSUB -l nodes=2: | ||
| - | #MSUB -l partition=c2070 | ||
| - | #MSUB -l walltime=168: | ||
| - | #MSUB -m be | ||
| - | #MSUB -V | ||
| - | #MSUB -o / | ||
| - | #MSUB -e / | ||
| - | #MSUB -d / | ||
| - | #MSUB -mb | ||
| - | ##### Running commands | ||
| - | echo " | ||
| - | echo " | ||
| - | cat $PBS_NODEFILE | ||
| - | echo " | ||
| - | cat $PBS_NODEFILE|sed -e ' | ||
| - | echo " | ||
| - | echo " | ||
| - | cat $PBS_STEP_OUT.hostfile | ||
| - | exe=location of the executable | ||
| - | nproc=`cat $PBS_NODEFILE | wc -l` | ||
| - | cd / | ||
| - | mpirun $nproc $exe > / | ||
| - | |||
| - | ------------------------------------------------------- | ||
| Type '' | Type '' | ||
| Line 154: | Line 160: | ||
| In this example we have requested four C2070 GPUs and 32 processors | In this example we have requested four C2070 GPUs and 32 processors | ||
| - | ====BlueGene/ | + | ====(Obsolete) |
| + | |||
| + | The BlueGene has been decommissioned and is no longer available. | ||
| Users can only use 32, 64, 128, 256 or 512 processors ('' | Users can only use 32, 64, 128, 256 or 512 processors ('' | ||
| Line 163: | Line 171: | ||
| The '' | The '' | ||
| - | + | <file bash mpi.job> | |
| - | ------------------------------------------------ | + | ###These lines are for Moab |
| - | + | #MSUB -l ppn=128 | |
| - | | + | #MSUB -l walltime=168: |
| - | #MSUB -l ppn=128 | + | #MSUB -m be |
| - | #MSUB -l walltime=168: | + | #MSUB -V |
| - | #MSUB -m be | + | #MSUB -o / |
| - | #MSUB -V | + | #MSUB -e / |
| - | #MSUB -o / | + | #MSUB -d / |
| - | #MSUB -e / | + | #MSUB -mb |
| - | #MSUB -d / | + | ##### Running commands |
| - | #MSUB -mb | + | / |
| - | ##### Running commands | + | -mode VN -exe LOCATIONOFTHEEXECUTABLE |
| - | / | + | </ |
| - | -mode VN -exe LOCATIONOFTHEEXECUTABLE | + | As before, use '' |
| - | + | ||
| - | + | ||
| - | ------------------------------------- | + | |
| - | + | ||
| - | + | ||
| - | '' | + | |
| - | =====Moab Summary===== | + | ======Moab Summary====== |
| - | ===SUBMITTING A JOB USING MOAB=== | + | ====SUBMITTING A JOB USING MOAB==== |
| Create a test job using a //text// editor: the job script file is a shell script file and should be a plain Ascii text file with Unix style line end characters. | Create a test job using a //text// editor: the job script file is a shell script file and should be a plain Ascii text file with Unix style line end characters. | ||
| Line 198: | Line 200: | ||
| Include the following in your script, for more info check http:// | Include the following in your script, for more info check http:// | ||
| - | To get the definitions, | + | To get the definitions, |
| - | + | <file bash job.msub> | |
| - | ###These lines are for Moab | + | ###These lines are for Moab |
| - | #MSUB -l nodes=4: | + | #MSUB -l nodes=4: |
| - | #MSUB -l walltime=2: | + | #MSUB -l walltime=2: |
| - | #MSUB -m be | + | #MSUB -m be |
| - | #MSUB -o / | + | #MSUB -o / |
| - | #MSUB -e / | + | #MSUB -e / |
| - | #MSUB -d / | + | #MSUB -d / |
| - | #MSUB -mb | + | #MSUB -mb |
| - | #MSUB -M nmonama@csir.co.za | + | #MSUB -M nmonama@csir.co.za |
| | | ||
| - | | + | ##### Running commands |
| - | NP=`cat $PBS_NODEFILE | wc –l` | + | NP=`cat $PBS_NODEFILE | wc –l` |
| - | mpirun –np $NP –machinefile $PBS_NODEFILE DLPOLY_3.07.SPARC.Y | + | mpirun –np $NP –machinefile $PBS_NODEFILE DLPOLY_3.07.SPARC.Y |
| + | </ | ||
| Details of each line of the job script: | Details of each line of the job script: | ||
| Line 242: | Line 244: | ||
| msub test.job | msub test.job | ||
| + | |||
| + | **NB:** Your job should always write its output to scratch. It will be faster if it reads its input from there as well. | ||
| There are various controls of Moab and Loadleveler that can help you to manage your job: | There are various controls of Moab and Loadleveler that can help you to manage your job: | ||
| Line 253: | Line 257: | ||
| ^ showres | Show existing reservations | | ^ showres | Show existing reservations | | ||
| ^ showstart | Show estimate of when job can or will start | | ^ showstart | Show estimate of when job can or will start | | ||
| - | ^ Checkjob | + | ^ checkjob |
| | | ||