When I run the command lmstat to check how many licenses are available for MATLAB Parallel Server product, I only see 1 license.
MATLAB: Does lmstat report only one license available for the MATLAB Parallel Server license
MATLAB Parallel Server
Related Solutions
Automatic startup of the MATLAB license manager on OS X is currently implemented as a SystemStarter shell script. This is no longer supported on OS X 10.10 Yosemite.
In order to start license manager at boot you will need to create a plist file and save it into /Library/LaunchDaemons. You may use the sample below (also attached) as your plist boot script, just make sure to edit username field.
Note, you cannot run license manager as root so you will need to specify a user that will run it.
<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> <plist version="1.0"> <dict> <key>Label</key> <string>MATLAB License Manager</string> <key>ProgramArguments</key> <array> <string>/Applications/MATLAB_R2014b.app/etc/lmboot</string> <string>-u</string> <string>SpecifyYourUsernameHere</string> </array> <key>RunAtLoad</key> <true/> </dict> </plist>
Occasionally, license keys may not be checked back into the pool of available license keys even though the MATLAB session has ended. This would most likely happen as a result of a system crash. If this is the case it is advisable to restart the FLEXnet license manager.
It is also possible to manually check back hung/stuck license keys into the available pool by using the "lmremove" utility. If the MATLAB session is still running, the lmremove command will not work. In that case, you will need to end the MATLAB session to return the license key.
In order to use lmremove, you must first get the output of lmstat. To obtain this output, you can perform the following steps:
For Windows:
=========
1. Launch lmtools.exe located in $MATLAB\etc\win{32|64} ($MATLAB\flexlm for releases prior to 2010b) on the license server (where $MATLAB is the installation folder for MATLAB on that machine)
2. Go to the "Server Status" tab.
3. Click perform Status Enquiry button.
For Unix/Linux/Mac:
=========
1. Open a terminal window (for MAC, Terminal is located in Applications/Utilities)
2. Change directories to MATLAB's etc folder in the terminal by running the following command:
cd $MATLAB/etc
Where $MATLAB is the installation folder for MATLAB (for Mac OS X with R2008b or higher, $MATLAB is generally /Applications/MATLAB_R2008b.app).
3. Run the following command to obtain the lmstat output:
./lmstat -a
Both the lmstat and the lmtools, will list all of the users that have checked out licenses. For example:
License server status: 27000@server1
License file(s) on server1: C:\Program Files\MATLAB\R2010b\etc\license.dat:
server1: license server UP (MASTER) v11.4
Vendor daemon status (on server1):
MLM: UP v11.6.1
Feature usage info:
Users of MATLAB: (Total of 10 licenses issued; Total of 1 licenses in use)
"MATLAB" v20, vendor: MLM
nodelocked license, locked to "ID=123456"
johndoe johnpc johnpc (v20) (johnpc/27000 101), start Wed 3/11 10:06
The lmstat will output the username, then the computer name, and then the display name (usually the display is the same as the computer name). In order to use lmremove, you will need the feature name (ex: MATLAB), the host (computer name) and the display name.
To use lmremove, you will need to run the command:
lmremove [-c <path to license file>] feature Entry1(user) Entry2(host) Entry3(display)
(where <path to license file> is the path to the license.dat file)
For UNIX/Linux/Mac, lmremove is located in $MATLAB/etc. Thus if you followed the steps above, you can execute it by running:
./lmremove [-c <path to license file>] feature Entry1(user) Entry2(host) Entry3(display)
Using the example above, to remove johndoe's license, you would run the following:
./lmremove -c license.dat MATLAB johndoe johnpc johnpc
For a Windows machine, to access lmremove, you will need to use a Windows command prompt. To run lmremove, you can take the following steps:
1. Open up a Windows Command Prompt by clicking on the Start Menu and go to All Programs, Accessories, and click on Command Prompt.
2. In the Command Prompt, change directories to the MATLAB's flexlm folder. For example:
cd C:\Program Files\MATLAB\R2010b\etc\win32
3. Launch lmremove through the lmutil.exe executable:
lmutil.exe lmremove -c license.dat (feature) (user) (host) (display)
Thus for our example above, you would run:
lmutil.exe lmremove -c license.dat MATLAB johndoe johnpc johnpc
NOTE: If the username contains a space, you will find an error stating 'lmremove doesn't exist. The name will need to have quotes added:
lmutil.exe lmremove -c license.dat MATLAB "john doe" johnpc johnpc
Related Question
- Do I get the error message “Inconsistent encryption code” in the log file and/or “Invalid passcode” when starting MATLAB
- Check availability of floating license
- Do I receive License Manager Error -21
- Can’t I run the network license manager with the stand-alone (USER=name) LINUX license
- Do I receive License Manager Error -4
- Do I receive an “Incomplete License File” error when activating MATLAB
Best Answer