Path: news.mathworks.com!not-for-mail
From: <HIDDEN>
Newsgroups: comp.soft-sys.matlab
Subject: Re: parallel computing toolbox without distributive computing toolbox
Date: Thu, 1 Oct 2009 13:17:09 +0000 (UTC)
Organization: The MathWorks Inc
Lines: 69
Message-ID: <ha2a4l$e9s$1@fred.mathworks.com>
References: <h9r4tv$7o6$1@fred.mathworks.com> <h9rmgg$p9b$1@fred.mathworks.com> <h9s1km$5vh$1@fred.mathworks.com> <h9t3e1$mv5$1@fred.mathworks.com> <h9voml$ira$1@fred.mathworks.com>
Reply-To: <HIDDEN>
NNTP-Posting-Host: webapp-03-blr.mathworks.com
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: 8bit
X-Trace: fred.mathworks.com 1254403029 14652 172.30.248.38 (1 Oct 2009 13:17:09 GMT)
X-Complaints-To: news@mathworks.com
NNTP-Posting-Date: Thu, 1 Oct 2009 13:17:09 +0000 (UTC)
X-Newsreader: MATLAB Central Newsreader 869084
Xref: news.mathworks.com comp.soft-sys.matlab:574221


There are two ways to run a MATLAB Pool over TORQUE.

1. Interactively.  That is, from the MATLAB prompt you run

   >> matlabpool open torque_config 4

Using a (made up) configuration called torque_config, you start 4 Workers on the cluster.  Now if you run a parfor, it will submit the tasks to TORQUE.

2. Batch.  By using the batch() command, you can either run your code serially on one Worker or pass as an argument the size of the MATLAB Pool to startup for you when you submit the job.

   >> job = batch('myscript','Matlabpool',4)

Raymond

"Sig Du" <dusigh@hotmail.com> wrote in message <h9voml$ira$1@fred.mathworks.com>...
> Raymond,
> 
> Thanks a lot. Your answer is very helpful. I've aske our admin to work on the license problem. One final thing to confirm: If I write some code with 'parfor', and I have Torque on the cluster. Suppose I request multiple nodes through Torque and submit this code to cluster without first running the 'matlabpool' command,  my code won't automatically run parallelly, is that right?
> 
> thanks,
> Sig
> 
> "Raymond Norris" <raymond.norris@mathworks.com> wrote in message <h9t3e1$mv5$1@fred.mathworks.com>...
> > MDCS doesn't allow you to submit MATLAB jobs -- MDCS is (headless) MATLAB.  We provide a scheduler, MathWorks Job Manager, that can submit MATLAB jobs to MDCS.  The Job Manager can be substituted by TORQUE.
> > 
> > I think you might be asking the following question:  Can you submit a MATLAB job via PCT to TORQUE that starts up full MATLAB rather than MDCS.  PCT is written to instruct TORQUE to startup MDCS, not MATLAB (there is a slight difference between full MATLAB mode and MDCS).  And truthfully, you don't want to be useing full MATLAB licenses to run on the cluster.  It's more economical to run MDCS than full MATLAB on the cluster.
> > 
> > Tell me if this answers your questions.
> > 
> > Raymond
> > 
> > "Sig Du" <dusigh@hotmail.com> wrote in message <h9s1km$5vh$1@fred.mathworks.com>...
> > > Hi Raymond,
> > > 
> > > Another question I would like to ask: if I don't have MDCS, but can make the PCT work, can I get my parallel computation matlab job run on cluster with Torque? Since you said MDCS allows me to submit the job, but Torque can do this job too.  I guess Torque can be a substitute for MDCS, right?
> > > 
> > > thanks,
> > > Sig
> > >  
> > > "Raymond Norris" <raymond.norris@mathworks.com> wrote in message <h9rmgg$p9b$1@fred.mathworks.com>...
> > > > Hi Sig,
> > > > 
> > > > Let me clarify one thing, there are two products: The Parallel Computing Toolbox (client side) and the MATLAB Distributed Computing Server (server side).  Functions like parfor are built into the language.  Others, like matlabpool, batch, and spmd require PCT.  The PCT functionality allows you to submit jobs serviced by MDCS.
> > > > 
> > > > The License Manager error is stating that all the PCT licenses have been checked out.  Without a PCT license, you can't start run jobs on the cluster.
> > > > 
> > > > Let me know if this helps. 
> > > > 
> > > > Raymond
> > > > 
> > > > "Sig Du" <dusigh@hotmail.com> wrote in message <h9r4tv$7o6$1@fred.mathworks.com>...
> > > > > Hi,
> > > > > 
> > > > > Is it true that the parallel computing toolbox won't work if the distributive computing toolbox has not been installed? Because then if I type in 'matlabpool', I received the following err msg:
> > > > > "  License checkout failed.
> > > > > License Manager Error -4
> > > > > Maximum number of users for Distrib_Computing_Toolbox reached. 
> > > > > Try again later. 
> > > > > To see a list of current users use the lmstat utility or contact your License Administrator.
> > > > > 
> > > > > Troubleshoot this issue by visiting: 
> > > > > http://www.mathworks.com/support/lme/R2008b/4
> > > > > 
> > > > > Diagnostic Information:
> > > > > Feature: Distrib_Computing_Toolbox 
> > > > > License path: /myhome/.matlab/R2008b_licenses:/opt/stow/matlab-r2008b/licenses/license.dat:/opt/stow/matlab-r2008b/licenses/network.lic: 
> > > > > FLEXnet Licensing error: -4,132."
> > > > > 
> > > > > So it failed to start matlabpool when Distributive Computing Toolbox is missing. And we know that if matlabpool is not working, then parfor loops will be just the same as serial for loops. I also got similar err when I tried with 'findResource' or 'pmode'. They are not working even on a local multi-core PC, not to mention a cluster system. Does this mean, without Distributive Computing Toolbox,  parallel computing toolbox is useless?