From: Marc Anthony on
So here in another rather obnoxious problem which I have not been able to resolve.

I am trying an experiment with two Machines:

Machine-A - Win64 - QuadCore i7 - Client on which I run matabpool 8
Machine-B - Win32 - QuadCore i7 - Host on which the JobManager-B and workers reside

I would like to parallelize compiled mex code within a parfor loop.

1) I set-up the Distributed Computing system
2) I set "Configurations Manager" to put JobManager-B as default
3) I set "Configurations Manager" to copy Files and Directories from client to cluster nodes
4) I validate the Configuration - ALL green - perfect!
5) I set up a matlabpool of 8 on Machine-A
6) I attempt to run my parfor loop

But it won't run because since I compiled my mex code on Machine-A it generates a *.mexw64 file. This obviosly won't work on the Win32 Machine-B.

So the only way I found around this was to fetch the checkpoint folder on Machine-B and recompile the mex file there to produce the correct *.mexw32 executable.

Then it works just fine...
But this is not practical on a larger real-world cluster.

So how can automatically recompile all mex code on the cluster nodes such that each noce has the correct binary file format?

Is there any way to execute a batch file on each lcuster node every time a new pool is created? It would save a lot of aggro!