I've noticed that there are many different flavors of MATLAB available. Some licenses require constant contact with the licensing server, and if disconnected the client will show some message like "unable to contact licensing server, will quit if connection not re-established in X minutes." Others are stand-alone installs, without such limitations. My question is, is there any way to tell which MATLAB license type I have installed from the command line?
+3
A:
You can check whether you have a file called network.lic
in the $matlabroot/licenses folder. If yes, you're most likely running a network installation.
hasNetworkLicense = exist(fullfile(matlabroot,'licenses','network.lic'),'file') == 2;
Jonas
2010-05-13 20:04:42
In my case, the install script adds an environment variable `MLM_LICENSE_FILE` which contains what appears to be addresses of license servers..
Amro
2010-05-13 23:49:23
@Amro: Thanks for the information.
Jonas
2010-05-14 00:24:38
FWIW, I tested this on a few different machines - network licensed and user licensed - and it worked as advertised.
eykanal
2010-05-14 03:03:06
A:
Matlab has a function called LICENSE that returns information on which toolboxes etc. are available. I'm not sure if it tells you the level of detail you're looking for. Note that this runs from the Matlab command line, not the shell command line. From your question I wasn't quite sure which you were looking for.
mtrw
2010-05-13 22:54:37