[torqueusers] Perl Threads

Dimitrakakis Georgios giwrgis at chemistry.uoc.gr
Wed Aug 21 00:51:57 MDT 2013


>  > Hi Dimitrakakis,
>  >> I have a program that uses perl threads to run in parallel.
>  >> I would like to know if there is a way for Torque to understand the
> number
>  >> of threads used in order to assign the proper number of processors for
> the
>  >> specific job or do I have to specify them explicitly in the submit
> script?
>  >
>  > You do it the other way around: you tell Torque how many cores you want
>  > with -lnodes=1:ppn=8, for example, and the the perl script can figure
>  > out how many threads it can launch according to the number of lines in
>  > $PBS_NODEFILE. This works only inside Torque so your perl script has to
>  > default to something else if $PBS_NODEFILE is undefined and you want
>  > your script to also run outside Torque.
>  >
>  >> What about distribution in more than one nodes? Is it possible?
>  >
>  > Threads work in shared memory so it is restricted to one node, unless
>  > you trick it to believe that there is only one node. ScaleMP comes to
>  > mind, but it is a commercial product.
>
> I believe you can make Perl use MPI via Parallel::MPI, see here:
>
> http://search.cpan.org/~josh/Parallel-MPI/MPI.pm
>
> However, i have never used MPI as I am no programmer, neither have any of
> our users. If
> your cluster is configured with MPI, this might be a way to parallelize
> across nodes, but
> I guess it will require significant modification of your Perl code, that's
> the downside.
>
> --

Michel and Michael,

thanks you both for the very useful info.
The way I see it for now is to use just one node of the cluster and
specify in the pbs script the number of cores.

Regards,

G.


-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.



More information about the torqueusers mailing list