Why am I unable to start a local MATLABPOOL from multiple MATLAB sessions that use a shared preference directory using Parallel Computing Toolbox 4.0 (R2008b)?
2 次查看(过去 30 天)
显示 更早的评论
I am using the Parallel Computing Toolbox 4.0 (R2008b) on multiple Linux computers that run separate sessions of MATLAB. These computers share the same Preferences directory (PREFDIR) for MATLAB, which is a shared file system.
When I start a local scheduler session and worker pool on one computer, using the MATLABPOOL command, I see the following error message after trying to start another, independent Local Scheduler on another computer that shares the Preferences directory:
Destroying 1 pre-existing parallel job(s) created by matlabpool that were in the finished or failed state.
采纳的回答
MathWorks Support Team
2013-10-18
The error message can be ignored. Both MATLABPOOLs are expected to function regardless of the message.
To work around this issue, a unique data location directory must be specified for each local worker pool session on each computer. This may be done according to the following steps:
1. On the MATLAB desktop, navigate to:
Parallel -> Manage Configurations
2. Select the "Local" configuration.
3. Right-click and select "Properties..."
4. Specify the DataLocation directory in the corresponding text box.
OR
Change the 'DataLocation' property programmatically to unique locations by executing the following MATLAB code before starting the Local Scheduler, i.e. before running MATLABPOOL:
sched=findResource('scheduler','type','local');
sched.DataLocation = /home/users/JohnSmith/.matlab/local_scheduler_data/<directory name>
If using Parallel Computing Toolbox on MATLAB R2012b or later, please consider using the following new API to set the unique scheduler data locations and to start the MATLAB pool. This is because the old API using 'findResource' will be deprecated in a future release.
pc = parcluster('local')
pc.JobStorageLocation = 'C:\temp'
matlabpool(pc, 4)
0 个评论
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Install Products 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!