FlexLM License Manager

Cadence uses Flexera License Manager (FlexLM) to support network license borrowing for enterprise environments. The following documentation details the architecture and design of the license server for company_name_here based in location_here.

Important Filepaths

  • FlexLM Main Dir: /opt/flexlm
  • Cadence License File: /opt/flexlm/cadence/license.dat
  • Cadence Binaries: /opt/flexlm/cadence/bin
  • Cadence LM Service File: /etc/systemd/system/flexlm-cadence.service

Adding Additional Licence Servers

This install was originally done with only a Cadence license server in mind. However, it is possible to support other vendors such as Solidworks or Matlab using this license server.

  1. Create a new folder to store the vendor specific files.

    mkdir -p /opt/flexlm/vendor_name_here
  2. Copy the bin folder for the license server (usually provided by the vendor) to the new location made in step 1.

  3. Add the new bin folder to the global PATH. Use /etc/bash.bashrc to ensure its applied globally to all users. /etc/profile* will only apply to interactive login shells, aka not to the system flexlm user.

    vendor='vendor_name_here'
    echo -e "export PATH=/opt/flexlm/$vendor/bin:$PATH\nLM_LICENSE_FILE=/opt/flexlm/$vendor/license.dat" >> /etc/bash.bashrc

    Once you have made those files, either reboot or run exec bash to source the new changes.

  4. Create a file at /etc/systemd/system/flexlm-vendor_name_here.service and save the following to it.

    [Unit]
    Description=Licence manger for vendor_name_here
    After=network.target
    
    [Service]
    Type=simple
    User=flexlm
    WorkingDirectory=/opt/flexlm/vendor_name_here
    ExecStart=/opt/flexlm/vendor_name_here/bin/lmgrd -z -c /opt/flexlm/vendor_name_here/license.dat
    SuccessExitStatus=15
    Restart=always
    RestartSec=30
    
    [Install]
    WantedBy=multi-user.target
  5. Enable new daemon service.

    systemctl daemon-reload
    systemctl enable --now flexlm-vendor_name_here.service
  6. Update file permissions.

    chown -R flexlm:flexlm /opt/flexlm/vendor_name_here
    find /opt/flexlm/vendor_name_here -type d -exec chmod 750 {} \;
    find /opt/flexlm/vendor_name_here -type f -exec chmod 640 {} \;