This section explains the basics of creating a job script. The script can be used with CCQ to automatically launch the nodes needed for the HPC Job.
For information on using Torque to manually submit and manage jobs, see the Torque Administrator Guide.
For information on using Slurm to manually submit and manage jobs, see the Slurm Workload Manager documentation.
Below is a sample for either Torque or Slurm. You would uncomment out the section for whichever scheduler you plan on using.
This sample is in the /software/samplejobs/mpi/GCP/ directory, and in this case, for the MPI sample job, you first have to run the compile script prior to running the sample job.
#!/bin/bash #Uncomment this section for use with Torque/Maui HPC Scheduler ##PBS -l nodes=2:ppn=2 #Uncomment this section for use with Slurm HPC Scheduler ##SBATCH -N 2 ##SBATCH --ntasks-per-node=2 #Need to change the location of the shared FS to the name you specified in the CloudyCluster creation wizard when launching the cluster export SHARED_FS_NAME=/mnt/orangefs #Uncomment this section for use with openMPI module add openmpi/3.0.0 #Uncomment this section for use with mpich #module add mpich/3.2 cd $SHARED_FS_NAME/samplejobs/mpi mpirun -np 4 $SHARED_FS_NAME/samplejobs/mpi/mpi_prime