[torqueusers] qsub problem
Jacques Foury
Jacques.Foury at math.u-bordeaux1.fr
Mon Oct 24 03:58:55 MDT 2005
Angelino Matteo a écrit :
> Ok, but in this way I must write (or generate) N script where N is
> the number of my instance.
> Is possible to write e script like this :
>
> #!/bin/sh
>
> program 1
> program 2
> program 3
> ...
> ...
> program 100
>
> and from shell :
>
> qsub myscript.sh
>
> I have tried but torque return me an error. This example is very
> simple, but in real case, my program accept 10 input parameter and
> this input change from an instance to another!
>
> Thank's for your help......
ok, then I'd write a simple loop :
for i in 1 ... 100
do
echo `program.sh ${i}` | qsub -q queue -l mem=156mb,walltime=10:00:00 -
done
where the '-' tells qsub to read the stdin instead of a script file...
note that you can replace the echo by any command sequence where you
replace by $i whatever you want.
Of course the 'for' can be replaced by a 'while'...
--
Jacques Foury
More information about the torqueusers
mailing list