[torqueusers] question about submitting multiple jobs (a.k.a job array)

Mahmood Naderan nt_mahmood at yahoo.com
Thu Aug 11 02:50:33 MDT 2011


> #PBS -t 1-2

Is it possible to use strings instead of numbers?
#PBS -t one-two

./run -bench${PBS_ARRAYID}

I get this error
qsub: Bad Job Array Request


// Naderan *Mahmood;


________________________________
From: Glen Beane <glen.beane at gmail.com>
To: Mahmood Naderan <nt_mahmood at yahoo.com>; Torque Users Mailing List <torqueusers at supercluster.org>
Sent: Thursday, August 4, 2011 8:03 PM
Subject: Re: [torqueusers] question about submitting multiple jobs (a.k.a job array)





On Thu, Aug 4, 2011 at 7:44 AM, Mahmood Naderan <nt_mahmood at yahoo.com> wrote:

Hi
>I am looking for some example to submit multiple jobs as stated in http://www.clusterresources.com/torquedocs21/2.1jobsubmission.shtml#jobarrays
>
>For example, I have to jobs:
>job1 >>
>#PBS -q Q1
>cd $PBS_O_WORKDIR
>./run -bench1
>
>job2 >>
>#PBS -q Q2
>cd $PBS_O_WORKDIR
>./run -bench2
>
>Normally I use
>
>qsub job1
>qsub job2
>
>
>Now I want to submit them with one qsub command.
>It is stated that I have to use "qsub -t 0-1 submit_script.sh"
>I want to know what is the content of "submit_script.sh" ?
>Is it
>
>#PBS -q Q1
>cd $PBS_O_WORKDIR
>./run -bench1#PBS -q Q2
>cd $PBS_O_WORKDIR
>./run -bench2
>

#PBS -q Q1
#PBS -t 1-2

cd $PBS_O_WORKDIR
./run -bench${PBS_ARRAYID}


notice I passed 1-2 for the -t argument.  This means one job will be run with a PBS_ARRAYID of 1, and the other of 2.  


More information about the torqueusers mailing list