Home‎ > ‎Installation Notes‎ > ‎

Matlab Distributed Computing

Specific installation notes

  • The root matlab directory is installed at: /usr/local/matlab_r2009b
    • The installation files are on vm1 at: /opt/matlab_r2009b_cdrom
  • Detailed cluster setup instructions can be generated here.
  • Currently the license server is linked to user: bingjeff
    • Might want to change this in this file: /etc/init.d/flexnet
  • Need to setup nodes, move license when the time comes.

Stage 1: Install MATLAB Distributed Computing Server 

Startup an X11 ssh session using the -X option.  Mount the DVD using:
mount -t iso9660 -o ro /dev/cdrom /cdrom

Also need to make sure java is installed:
  • Install java using: sudo apt-get install openjdk-6-jre
  • Set the default version of java
    • Run sudo update-java-alternatives -l to see the current configuration and possibilities.
    • Run sudo update-java-alternatives -s XXXX to set the XXX java version as default. For Sun Java 6 this would be sudo update-java-alternatives -s java-6-sun
    • Run java -version to ensure that the correct version is being called.
  • Need to install an X11 lib: apt-get install libxp6
    • If you don't do this first you will get an error that says libXp.so.6 must be installed.

Some edits:
  • When setting up FlexLM in Ubuntu you will need to find the runlevel, it is no longer found in inittab.  Look for DEFAULT_RUNLEVEL here: /etc/init/rc-sysinit.conf

Stage 2: Configure Your Cluster for use with MathWorks Job Manager (provided with the product)

The cluster may have problems if it can't resolve "short" hostnames, choose one of the following if this is the case:
  1. Adjust /etc/hosts so the job manager can resolve the client's short hostname 
  2. Use fully qualified domain names in mdce by setting the variable HOSTNAME in mdce_def.sh file to `hostname -f` (instead of just `hostname`).
To get the MDCE service to start at boot:
$ sudo ln -s /usr/local/matlab/toolbox/distcomp/bin/mdce /etc/mdce
$ sudo ln -s /usr/local/matlab/toolbox/distcomp/bin/mdce /etc/init.d/mdce
$ sudo chmod 555 /etc/init.d/mdce
$ sudo update-rc.d mdce defaults

Stage 3: Install Parallel Computing Toolbox 

Now that your cluster is ready to be used, you need to install Parallel Computing Toolbox on the computer you will use to write MATLAB applications. 

Stage 4: Test Your Parallel Computing Environment 

Random notes

  • You will need to run MDCE on the head node, so that you can have a job manager that is accessible to the outside world. 
  • You should create as many workers on each node as there are cores. 

Configuring the user environment

The lab needs to know where the user is located. This startup script helps with that.
% Dustin's startup.m
% 02/2010
disp('Running startup.m');
disp('Startup.m complete.');
This won't solve all your problems, though, especially if you're behind a router. You might be able to improve your results by setting your host as DMZ in the router configs. If you're feeling extra spunky you could create a script to automate port mapping by using UPnP or NAT-PMP. 

Test script


Further Matlab Cluster Information

Jeff Bingham,
Feb 25, 2010, 5:55 AM
Jeff Bingham,
Feb 25, 2010, 5:39 AM
Jeff Bingham,
Feb 25, 2010, 5:40 AM
Jeff Bingham,
Feb 25, 2010, 5:40 AM
Jeff Bingham,
Feb 25, 2010, 5:41 AM
Jeff Bingham,
Feb 25, 2010, 5:46 AM
Jeff Bingham,
Feb 25, 2010, 5:41 AM