0

I want to pass the PBS_ARRAYID to the main argument vector (argv) through qsub but after reading every return in pages of google results - I cannot get this to work. A constant argument qsubs fine.

#
#$ -cwd
#$ -S /bin/bash
#$ -j y
#$ -t 1-3
#$ -pe fah 1
var1=$(echo "$PBS_ARRAYID" -l)
const1=1
./daedalus_linux_1.3_64 $const1 $var1

I lifted the Array code from the solution given here Using a loop variable in a bash script to pass different command-line args

From everything I have read this should work. And it does work with the exception of var1=$(echo "$PBS_ARRAYID" -l)

1 Answer 1

0

It turns out the answer is fairly simple, our University uses a Sun Grid Engine queue - SGE

The tutorials I found by search were all by chance for PBS queue

#
#$ -cwd
#$ -S /bin/bash
#$ -j y
#$ -t 1-9
#$ -pe fah 3
const1=1
./daedalus_linux_1.3_64 $const1 $SGE_TASK_ID
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.