Using Time-Outs to Free Idle License Keys

If you have a concurrent license, you can use the FLEXnet time-out option to automatically return idle license keys at your site. With license time-outs, the license manager automatically frees license keys that sit idle for a specified period of time, returning them to the pool of available license keys.

For example, when you start MATLAB and other products, such as toolboxes, you check out license keys for these products. If you go home without exiting your MATLAB session, these licenses remain checked out and are not available to other users. With time-out enabled, after your licenses sit idle for a specified period of time, the license manager releases the license keys for all the products you had been using and these keys become available to other users.

For more information about time-outs, see the following sections:

Enabling License Time-Outs

To take advantage of time-outs, you must specify the FLEXnet TIMEOUT option in a FLEXnet options file. A FLEXnet options file is a text file that contains license manager options statements, such as INCLUDE, EXCLUDE, and GROUP statements.

To enable time-outs, follow these instructions:

  1. Create a FLEXnet options file, if one does not already exist, using any text editor. Name the options file MLM.opt and put the file in the flexlm folder in your MATLAB installation folder. For example, you might create the file

    C:\Program Files\MATLAB\R2006b\flexlm\MLM.opt
    
  2. Add the FLEXnet TIMEOUT option to the options file, using the following syntax:

    TIMEOUT feature seconds
    

    For feature, specify MATLAB. You cannot specify separate time-out values for individual MathWorks products, such as toolboxes.

    For seconds, specify the amount of idle time you want to allow. The minimum value is 4 hours (14,400 seconds). If you specify a time-out value that is smaller, the minimum value is used. For example, to specify a five hour time-out, enter the following in your options file.

    TIMEOUT MATLAB 18000
    
  3. Make sure the DAEMON line in your License File specifies the location of your options file. The License File DAEMON line must include the options= syntax. For example, your DAEMON line might look like the following:

    DAEMON MLM "C:\Program Files\MATLAB\R2006b\flexlm\mlm.exe" \
                options="C:\Program Files\MATLAB\R2006b\flexlm\mlm.opt"
    
  4. Stop the license manager and restart it. Whenever you change the License File, or change the time-out value in the options file, you must restart the license manager. See Managing the License Manager Service for information about starting and stopping the license manager.

Experiencing a License Time-Out

When time-out is enabled, if you open a MATLAB session, and then leave it inactive for more than 4 hours, when you return, you will find MATLAB still open on your desktop. However, you will see the following message displayed in the Command Window:

Your MATLAB session has timed out.  All license keys have been 
returned.

The time-out is also recorded in the license manager log file, as follows:

Idle session.  Returning keys for <user>@<machine>

(For more information, see Viewing the License Manager Log File.)

Reacquiring License Keys After a Time-Out

To resume a timed-out MATLAB session, just start using MATLAB again. If a license key is available, MATLAB checks it out automatically. Likewise, as you use the toolboxes and other products that you had checked out, MATLAB obtains license keys for these products as well.

If a license key is not available, MATLAB periodically attempts to check out a license, issuing warning messages. After 10 warnings, if a license key is still not available, MATLAB saves the workspace and exits.


© 1984-2006 The MathWorks, Inc. Terms of Use Patents Trademarks Acknowledgments