FLEXlmTM provides a wide number of tools for the license managing, all of them are well described in the FLEXlm End User Guide. To start the license manager on a UNIX box the lmgrd command has to be used. The simplest way to start the daemon is to use the command:
FLEXlm_path/lmgrd -c license_path/license.dat
where FLEXlm_path is the absolute path where the FLEXlmTM tools are saved (usually .../ESTECO/modeFRONTIER3xx/lic) and license_path is the absolute path where the license.dat file was saved.
If you want to start the license daemon at startup each UNIX System has some strange system dependent way to do it. We can just show a simple example how to solve this problem.
Let's write a shell script which execute the lmgrd command:
#!/bin/sh nohup /bin/su frontier -c 'echo "exec FLEXlm command: lmgrd" > log_path/license.log' nohup /bin/su frontier -c 'FLEXlm_path/lmgrd -c license_path/license.dat >> log_path/license.log' sleep 3 nohup /bin/su frontier -c 'echo "exec FLEXlm command: lmdiag" >> log_path/license.log' nohup /bin/su frontier -c 'FLEXlm_path/lmdiag -n -c license_path/license.dat >> log_path/license.log' exit 0
Since this script has to be run at boot only absolute paths must be used. The vendor daemon esteco has to be in the same directory of lmgrd or his path must be defined on the SERVER|VENDOR line in the license.dat file.
DAEMON esteco mypath/esteco
For security reasons it is always recommended to run the lmgrd daemon under a user different than root. In this case the /bin/su command will run the service under the frontier user.
Save the script in a file called flexlm_daemon and ask the system administrator to modify the necessary boot files to start the FLEXlmTM license daemon when your server boots.
Since the UNIX machines can be quite different and user dependent some hints on how to set up the boot files can be shown for the following architectures:
Copy flexlm_daemon to /etc/rc.d/init.d.
Modify its permissions to be the same as the owner of the directory (e.g. root).
List the content of /etc/rc.d/rc3.d (run level 3) and pick a number which is not in use and is not smaller then the one for xinetd, let's say 70.
ls /etc/rc.d/rc3.d
S10network S14nfslock S25netfs S30samba S56rawdevices S80sendmail S90xfs
S12syslog S17keytable S26apmd S40atd S56xinetd S85gpm S95anacron
S13portmap S20random S28autofs S55sshd S60lpd S90crond S95rcsge
Create a symbolic link from /etc/rc.d/rc3.d to the flexlm_daemon script in /etc/rc.d/init.d.
cd /etc/rc.d/rc3.d
ln -s ../init.d/flexlm_daemon S70flexlm
Similarly list the content of /etc/rc.d/rc5.d (run level 5) and pick a number which is not in use and is not smaller then the one for xinetd, let's say 70.
Create another symbolic link from /etc/rc.d/rc5.d to the flexlm_daemon script in /etc/rc.d/init.d.
Reboot the system to start the license manager.
Copy flexlm_daemon to /sbin/init.d.
Modify its permissions to be the same as the owner of the directory.
List the content of /sbin/rc2.d and pick a number which is not in use, let's say 780.
ls /sbin/rc2.d
K900nfs.server S340net S550ddfa S660xntpd
S008net.sd S370named S560SnmpMaster S700acct
S100swagentd S400nfs.core S565OspfMib S710hparray
S120swconfig S410nis.server S565SnmpHpunix S720lp
S200clean_ex S420nis.client S565SnmpMib2 S730cron
S202clean_uucp S430nfs.client S570dce S740supprtinfo
S204clean_tmps S490mrouted S580dfs S760auditing
S206clean_adm S500inetd S590ncs S770audio
S220syslogd S510gated S600i4lmd S800spa
S230ptydaemon S520rdpd S610rbootd S880swcluster
S300nettl S530rwhod S620xfs
S320hpether S540sendmail S630vt
Create a symbolic link from /sbin/rc2.d to the flexlm_daemon script in /sbin/init.d.
cd /sbin/rc2.d
ln -s ../init.d/flexlm_daemon S780flexlm
Reboot the system to start the license manager.
Copy flexlm_daemon to /etc/init.d.
Modify its permissions to be the same as the owner of the directory.
List the content of /etc/rc2.d and pick a number which is not in use and is not bigger then the one for xdm, let's say 80.
ls /etc/rc2.d
S00announce S23autoconfig S50mail S88configmsg
S04usr S30network S58rmtmpfiles S90chkdev
S12filesystems S40nck S60lp S96fontserver
S14quotas S45netls S61bsdlpr S97cadmin
S20sysetup S48savecore S70uucp S97mediad
S21perf S49swap S75cron S98xdm
Create a symbolic link from /etc/rc2.d to the flexlm_daemon script in /etc/init.d.
cd /etc/rc2.d
ln -s ../init.d/flexlm_daemon S80flexlm
Reboot the system to start the license manager.
Copy flexlm_daemon to /etc/init.d.
Modify its permissions to be the same as the owner of the directory.
List the content of /etc/rc3.d and pick a number which is not in use, let's say 20.
ls /etc/rc3.d
README S15nfs.server XS76snmpdx XS77dmi
Create a symbolic link from /etc/rc3.d to the flexlm_daemon script in /etc/init.d.
cd /etc/rc3.d
ln -s ../init.d/flexlm_daemon S20flexlm
Reboot the system to start the license manager.
Copy flexlm_daemon to /sbin/init.d.
Modify its permissions to be the same as the owner of the directory.
List the content of /sbin/rc3.d and pick a number which is not in use and is not bigger then the one for xdm, let's say 70.
ls /sbin/rc3.d
S00inet S13rwho S26security S57cron
S01quota S15named S27sia S60motd
S04uucp S18nis S30rmtmpfiles S63write
S05settime S19nfs S36presto S65lpd
S08startlmf S20nfsmount S40sendmail S80crashdc
S10syslog S21audit S45xntpd S95xdm
S11gateway S23kloadsrv S50common_agent
S12route S25preserve S55inetd
Create a symbolic link from /sbin/rc3.d to the flexlm_daemon script in /sbin/init.d.
cd /sbin/rc3.d
ln -s ../init.d/flexlm_daemon S70flexlm
Reboot the system to start the license manager.
Copy flexlm_daemon to a system directory of your choice, e.g. /etc.
Modify its permissions to be the same as the owner of the directory.
Edit the /etc/inittab system file appending the following line
flexlm:2:wait:/etc/flexlm_daemon > /dev/console 2>&1
Reboot the system to start the license manager.