[GE users] parallel execution in a batch

Reuti reuti at staff.uni-marburg.de
Tue Aug 10 22:09:56 BST 2004


    [ The following text is in the "ISO-8859-1" character set. ]
    [ Your display is set for the "ISO-8859-10" character set.  ]
    [ Some special characters may be displayed incorrectly. ]

>Is there an easy way to run a number of commands in a batch file in 
>parallel and return control only when the entire batch is done?  From 
>the docs, I think I can do this with qmake or with SGE dependencies, 
>but both of these involve more work than would seem necessary.

Do you mean in a normal batch file (also without SGE)?

#!/bin/sh
cp big_file_1 backupdir &
cp big_file_2 backupdir &
cp big_file_3 backupdir &
wait

The `wait` will wait for all child processes, if you don't give a job_id to it 
(man bash).

Cheers - Reuti

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe at gridengine.sunsource.net
For additional commands, e-mail: users-help at gridengine.sunsource.net




More information about the gridengine-users mailing list