MATLAB: Do I receive an error when I try to start MATLABPOOL in the Distributed Computing Toolbox 3.2 (R2007b)

parallelParallel Computing Toolbox

When I execute the following line of code at the MATLAB command prompt:
matlabpool open
I receive the following error
??? Error using ==>
distcomp.interactiveclient.pGetSockets>iThrowIfBadParallelJobStatus at 128
The interactive parallel job errored with the following message:
Error using ==> feval
Lab 1 on host adam-leons-computer failed to recognize the host name
adam-leons-computer where the MATLAB client is running.
Error in ==> matlabpool at 88
client.start('matlabpool', numlabs, config, 'nogui');

Best Answer

This error occurs because the host name is not being resolved properly. To work around this issue you can either set your hostname to 'localhost'
dctconfig('hostname','localhost');
Or execute the following line of code at the MATLAB command prompt, making sure to copy the string output of the Java
This should be the short names but might not be (some PC's think their name is different than the DNS name). For example:
java.net.InetAddress.getLocalHost.getHostName
>> java.net.InetAddress.getLocalHost.getHostName
ans =
johns-computer
dctconfig('hostname','johns-computer');