Is it possible to have Matlab try for a network license first, then fail over to a standalone license if it can't get a network license?

1 次查看(过去 30 天)
Is it possible to have Matlab try for a network license first, then fail over to a standalone license if it can't get a network license?
A network license is easier to keep up to date, but I have machines that must be able to start Matlab if the network happens to be down.

采纳的回答

Rutuja Shirali
Rutuja Shirali 2015-8-31
编辑:Walter Roberson 2015-8-31
I believe this can be done in the following 2 ways :
  1. Using the environment variable MLM_LICENSE_FILE (or LM_LICENSE_FILE):
  2. Using the "-c" startup flag for MATLAB
Using the environment variable MLM_LICENSE_FILE (or LM_LICENSE_FILE):
By setting the environment variable MLM_LICENSE_FILE (or LM_LICENSE_FILE), you can insert a new license search path for MATLAB. The variable value will be searched first, but this will not override the original search path. The value for this variable can either be a path to a license file, or it can be used in the port@host notation. For example, to have MATLAB check against the server "license1" on port 27000, you would set the variable value to be: 27000@license1.
You can also manually specify the location of the license file with the -c option to the MATLAB startup script. This can be achieved by editing the "Target" field in the MATLAB shortcut.
For example:
  • Right click on the MATLAB shortcut and choose "Properties"
  • In the "Target" field, add -c and the path to the license file after the end quotation mark:
"C:\Program Files\MATLAB\R2009b\bin\matlab.exe" -c "C:\Program Files\MATLAB\R2009b\licenses\test.lic"
Using the -c flag will override any default license search paths unlike the MLM_LICENSE_FILE variable.
To find the default locations for MATLAB license files, see the related solution:
"Where are the license files for MATLAB located?" http://www.mathworks.com/matlabcentral/answers/99147

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Startup and Shutdown 的更多信息

产品

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by