|
|
Chapter 6
The License Manager Daemon
The license manager daemon,
lmgrd, is one of two components which comprise the license server (the other being the vendor daemon). It handles the initial contact with FLEXlm-licensed applications, passing the connection on to the appropriate vendor daemon. The purpose of the license manager daemon,lmgrd, is to:A newer
lmgrdcan be used with an older vendor daemon or FLEXlm-licensed application, but a newer vendor daemon or FLEXlm-licensed application might not work properly with an olderlmgrd. Always use the newest version oflmgrdas possible; it is available for download from www.macrovision.com.6.1 lmgrd Command-Line Syntax
lmgrdis the main daemon for FLEXlm. When you invokelmgrd, it looks for a license file which contains information about vendors and features and starts those vendor daemons.Usage is:
lmgrd [-c
license_file_list] [-l [+]debug_log_path]
[-2 -p] [-local] [-x lmdown]
[-x lmremove] [-z ] [-v] [-help]where:
-clicense_file_list Use the specified license file(s).-l [+]debug_log_path Write debugging information to filedebug_log_path. This option uses the letterl, not the numeral 1. Prependingdebug_log_pathwith the + character appends logging entries. See Appendix H, “The Debug Log File,” for more information on this file.-2 -p Restricts usage oflmdown,lmreread, andlmremoveto a FLEXlm administrator who is by default root. If there a UNIX group called “lmadmin,” then use is restricted to only members of that group. If root is not a member of this group, then root does not have permission to use any of the above utilities. If-2 -pis used when startinglmgrd, no user on Windows can shut down the license server withlmdown.-local Restricts thelmdowncommand to be run only from the same machine wherelmgrdis running.-x lmdown Disable thelmdowncommand (no user can runlmdown). Iflmdownis disabled, stoplmgrdviakillpid(UNIX) or stop thelmgrdand vendor daemon processes through the Windows Task Manager or Windows service. On UNIX, be sure thekillcommand does not have a-9argument. (v4.0+lmgrd)-x lmremove Disable thelmremovecommand (no user can runlmremove). (v4.0+lmgrd)-z Run in foreground. The default behavior is to run in the background. If-ldebug_log_pathis present, then no windows are used, but if no-largument specified, separate windows are used forlmgrdand each vendor daemon.-v Displayslmgrdversion number and copyright and exits. -help Displays usage information and exits.
6.2 Starting the License Manager Daemon on UNIX Platforms
If any licenses in the license file are counted (license count > 0), the license manager daemon, and hence the license server, must be started before the FLEXlm licensed application can be used.
The license manager daemon, lmgrd, is started either manually on the command line or automatically at system startup. Both methods are discussed in the following sections.
Note: Start
lmgrdonly on the server node specified on the SERVER line in the license file.
If you are running three-server redundant license servers, maintain a separate copy of the license file (as well as thelmgrdand the vendor daemons binaries) on each server node. If you do not do this, you lose all the advantages of having redundant servers, since the file server holding these files becomes a single point of failure.
6.2.1 Manually
Start
lmgrdfrom the UNIX command line using the following syntax:
lmgrd-clicense_file_list-L [+]debug_log_pathwhere
Start
lmgrdby a user other than “root”, since processes started by root can introduce security risks. Iflmgrdmust be started by the root user, use thesucommand to runlmgrdas a non-privileged user:su
username-c "lmgrd -clicense_file_list-l \debug_log_path"where
usernameis a non-privileged user. You must ensure that the vendor daemons listed in the license file have execute permissions forusername. The paths to all the vendor daemons in the license file are listed on each VENDOR line.6.2.2 Automatically
On UNIX, edit the appropriate boot script, which may be
/etc/rc.boot,/etc/rc.local,/etc/rc2.d/Sxxx,/sbin/rc2.d/Sxxxx, etc. Include commands similar to the following. See the notes following for a full explanation./bin/su daniel -c 'echo starting lmgrd > \
/home/flexlm/v5.12/hp700_u9/boot.log'
/bin/nohup /bin/su daniel -c 'umask 022; \
/home/flexlm/v5.12/hp700_u9/lmgrd -c \
/home/flexlm/v5.12/hp700_u9/license.dat >> \
/home/flexlm/v5.12/hp700_u9/boot.log'
/bin/su daniel -c 'echo sleep 5 >> \
/home/flexlm/v5.12/hp700_u9/boot.log'
/bin/sleep 5
/bin/su daniel -c 'echo lmdiag >>\
/home/flexlm/v5.12/hp700_u9/boot.log'
/bin/su daniel -c '/home/flexlm/v5.12/hp700_u9/lmdiag -n -c\
/home/flexlm/v5.12/hp700_u9/license.dat >> \
/home/flexlm/v5.12/hp700_u9/boot.log'
/bin/su daniel -c 'echo exiting >>\
/home/flexlm/v5.12/hp700_u9/boot.log'Please note the following about how this script was written:
- All paths are specified in full, because no paths are assumed at boot time.
- Because no paths are assumed, the vendor daemon must be in the same directory as
lmgrd, or the VENDOR lines in the license file must be edited to include the full path to the vendor daemon.- The
sucommand is used to runlmgrdas a non-root user, “daniel.” It is recommended thatlmgrdnot be run as “root,” since it is a security risk to run any program as “root” that does not require root permissions.lmgrddoes not require root permissions.- Daniel has a
cshlogin, so all commands executed as “daniel” must be incshsyntax. All commands not executed as “daniel” must be in/bin/shsyntax, since that is what is used by the boot scripts.- The use of
nohupandsleepare required on some operating systems, notably HP-UX and Digital UNIX. These are not needed on Solaris and some other operating systems, but are safe to use on all.lmdiagis used as a diagnostic tool to verify that the server is running and serving licenses.
Note: This does not start the daemon until you reboot your license server machine.
6.3 Starting the License Manager Daemon on Windows
6.3.1 Manually from the Command Line
Start lmgrdas an application from a Windows command shell using the following syntax:C:\flexlm> lmgrd -c
license_file_list-L [+]debug_log_pathwhere
Spaces in pathnames require double quotes around the path.
On Windows,
lmgrdcan be installed as a service to allow it to be started and stopped through a user interface and run in the background.6.3.2 Configuring the License Manager as a Windows Service
To configure a license server as a service, you must have Administrator privileges:
- Run LMTOOLS.
- Click the
Configuration using Servicesradio button, then click the Config Services tab.- In the
Service Name, type the name of the service that you want to define, for example, Myvendor License Manager.- In the
Path to the lmgrd.exe filefield, enter or browse tolmgrd.exefor this license server.- In the
Path to the license filefield, enter or browse to the license file for this license server.- In the
Path to the debug log file, enter or browse to the debug log file that this license server writes. Prepending the debug log file name with the + character appends logging entries.
- To save the new Myvendor License Manager service, click the
Save Servicebutton.6.3.3 Manually from LMTOOLS
A graphical user interface to the license manager tools is provided called LMTOOLS. Some of the functions LMTOOLS performs include:
In order to control the operation of
lmgrdfrom the LMTOOLS user interface, you first must configure it as a license manager service. Follow the procedure in Section 6.3.2, “Configuring the License Manager as a Windows Service,” before proceeding.Once the license manager service is configured, lmgrd is started by starting the service from the LMTOOLS interface:
- Start LMTOOLS.
LMTOOLS appears with the
Service/License Filetab open.- Click the
Configuration using Servicesradio button.- Select the service name from the list presented in the selection box. In this example, the service name is
Myvendor License Manager.- Click the
Start/Stop/Rereadtab.
- Start Myvendor License Manager by clicking the
Start Serverbutton.Myvendor License Manager license server starts and writes its debug log output to
c:\flexlm\lmgrd.dl.6.3.4 Automatically at System Start Up
In order for lmgrd, and hence the license server, to start up automatically at system start up time, you first must configure it as a license manager service. Follow the procedure in Section 6.3.2, “Configuring the License Manager as a Windows Service,” before proceeding. Then continue:
- With LMTOOLS started and the desired service name selected, click the Config Services tab.
- Make this license manager a Windows service: check the
Use Servicescheck box (otherwise, it becomes a FLEXlm service).- Configure it to start at system startup time by checking the
Start Server at Power Upcheck box.From now on, when the machine is rebooted, this license manager starts automatically as a Windows service.
![]() |
![]() |
|
|
| FLEXlm End Users Guide | |||
| March 2003 |