MATLAB Answers

4

Why do I receive License Manager Error -97?

License Manager Error -97.
The desired vendor daemon is down.
Check the lmgrd log file, or try lmreread.
Feature: MATLAB
Vendor:Host: hostname
License path: C:\Program Files\MATLAB\bin\win32\license.dat;
D:\Program Files\MATLAB\bin\win32\*.lic
FLEXnet Licensing error: -97,121
For Further information, refer to the FLEXnet Licensing End User Guide, available at "www.macrovision.com".
For more information, see MathWorks Support page at <http://www.mathworks.com/support> and search for
"license manager error -97"

Tags

No tags entered yet.

Products

4 Answers

Answer by MathWorks Support Team on 7 Mar 2019
Edited by MathWorks Support Team on 7 Mar 2019
 Accepted Answer

This issue generally indicates that the MATLAB License Manager (MLM) process failed to start because the required ports are not available. The cause of this error may be due to one of the following:
1. Port Conflict - There are multiple network license managers on the same machine attempting to use the same ports or a firewall is blocking the ports used by the license manager. (Windows, Mac & Linux)
2. /var/temp Conflict - This error can occur when a lockMLM file is present in /var/tmp, or when the user starting the network license manager does not own the lm_TMW files in /var/tmp. (Linux & Mac)
3. *Incorrect MLM *- The license.dat file has the DAEMON line pointed to an older version of the MLM.exe. (Windows, Mac & Linux)
4. Incorrect HostID - The Host ID is incorrect on the License.dat or Network.lic file. (Windows, Mac & Linux)
5. License is Expired - The License you are trying to use (trial, annual, etc) has expired
Solution 1. Port Conflict
To resolve this issue, you must set different ports for each license manager that you are running. Ports are defined in the first two lines of the license.dat file used by the license manager.
For example, in this license.dat file:
SERVER license-server-name 0123456789AB 27000
DAEMON MLM "C:\Program Files\MATLAB\R20XXx\etc\win64\mlm.exe"
- lmgrd.exe is set use port 27000.
- MLM.exe uses a random port by default, unless a port is manually defined.
If the license.dat file is edited as follows:
SERVER license-server-name 0123456789AB 27050
DAEMON MLM "C:\Program Files\MATLAB\R20XXx\etc\win64\mlm.exe" port=27051
- lmgrd.exe will now use port 27050.
- MLM.exe will now use port 27051.
After the license.dat file is updated, you must restart the network license manager:
Next, change the port number used by MATLAB on the network client.
Update the client's network.lic file. This file is one of the following:
(R2008a or later, Windows) - $MATLAB\R20XXx\licenses\network.lic
(R2008a or later, Linux) - /usr/local/MATLAB/R20XXx/licenses/network.lic
(R2008a or later, Mac) - /Applications/MATLAB_R20XXx.app/licenses/network.lic
Update the SERVER line in the client license files to match the SERVER line in the license file for the license manager.
To verify that the firewall is the cause, temporarily disable it if it is safe to do so. If disabling the firewall allows licenses to be checked out, you will need to allow the MLM and LMGRD to pass through. It is possible to create program-based exceptions to the firewall in Windows and OS X allowing any port from the MLM vendor daemon. On Linux, you must use the port number.
Solution 2. /var/tmp Conflict
To resolve this issue, follow these steps:
1. Remove the lockMLM file and the lm_TMW files from /var/tmp.
2. After these files are removed, restart the license manager.
If you still receive the same error, an existing license manager or vendor daemon process might be the cause. The $MATLAB/etc/lmdown script shuts down a running lmgrd and MLM process. Sometimes the lmdown script can fail in its task.
If this occurs, the most effective way to shut down the license manager daemon is to use the UNIX "kill" command as follows:
1. Determine whether the license daemons are operating.
Depending on your system, use one of the following commands:
ps -ef | grep lm
or
ps agx | grep lm
2. Check the output to see if any LMGRD and "LM" or "MLM" associated with MATLAB are running. If so, kill all daemons manually by executing (root user may be required) the following command for each process.
kill <pid of daemon>
3. Restart the daemons by running $MATLAB/etc/lmstart.
If the error still remains at this point, it is also possible that the vendor daemon is trying to run on an occupied port.
To specify an open port for the vendor daemon, edit the DAEMON line in the license.dat file found in the $MATLAB/etc directory to contain the port=##### option (where ##### is an open port.)
The best numbers to use for open ports are those that are not in the 27000 to 27009 range (for example, use a port in the 1700-1711 range). For example:
DAEMON MLM $MATLAB/etc/MLM port=1711
(NOTE: prior to R2011a, the DAEMON line on Linux/Mac is "$MATLAB/etc/lm_matlab")
After you make this edit, reboot the machine and start the license manager.
Solution 3. Incorrect MLM
To resolve this issue, make sure you’re running the latest version of FlexLM.
Follow these steps to check the version of FlexLM on Windows.
1. Check the version of LMTools through Help > About
2. Check in the "Config Services" tab that the paths are pointing to the latest versions of lmgrd and license.dat
3. Confirm the license.dat has the DAEMON line pointed to the latest MLM.exe
Follow these steps to check the version of FlexLM on Linux and Mac.
1. Navigate to usr/local/MATLAB/R20XXx/etc or /Applications/MATLAB_R20XXx/etc
2. Run the “lmver” command
3. Check that you are running the latest version of license manager binaries.
Solution 4. Incorrect HostID
To resolve this issue, verify that the Host ID of the license server matches the license.dat and network.lic files. For more information on Host ID, see the following Article.
Solution 5. Expired License
To resolve this issue, please obtain an updated license that is not expired.

  4 Comments

Show 1 older comment
"To specify an open port for the vendor daemon, please edit the DAEMON line in the license.dat file found in the $MATLAB/etc directory [...]"
how do i edit the license.dat file?
Hi Sadhan,
If you are still having trouble editing the license.dat file, please contact MathWorks support:
-Justin
MathWorks Installation & Licensing Support

Sign in to comment.


Answer by Daru Nurisma Pramukti on 1 Mar 2016

  1 Comment

Hello,
I have exactly the similar issue as Daru Nurisma Pramukti above. I am on a network license, thus I have no control over the licensing server.
Srdan

Sign in to comment.


Answer by Orion Poplawski on 12 Mar 2014

You might have a conflict with a different product that uses the license manager. Make sure that LM_LICENSE_FILE does not point to the file of a different product.

  0 Comments

Sign in to comment.


Answer by dragonfighter on 18 Aug 2016

Hello,
I installed Matlab 2016a on a Windwos Server 2012. When I start the client I get the above mentioned error message. Why the matlab client can cause a license server error message? Someelse ran into that too?
Other clients based on Windows 7 connecting well to license server machine. Which should proof license server is up and running and firewalling shoud be ok on server side.
I opened firewall completly on the troubled client with no effect. error persisting. I checked license server firewall log to see any client request coming in. no incoming requests.
To me it seems the matlab 2016a client thinking himself to be a license server instead an application or something like that.
Many thanks in advance. Tom

  0 Comments

Sign in to comment.