datafeed-edge-connector

Softing License Server

Introduction

The License Server is a Softing software package used for activating software licenses for other Softing products.

Table of Contents

  1. License Server for native Windows
  2. License Server Enduser Tools
  3. License Server in Containerized Linux
  4. License Server in Containerized Linux with Windows Host

License Server for native Windows

Softing License Server is a machine used to host network software licenses (also called floating licenses or shared licenses) that are installed locally on an individual users’ machines. The network licenses can be shared among many users and/or applications.

Softing License Server fulfills requests to run a network application if the required license is available. When the network license is released (for example, a user closes the application), the license is moved to the license server’s available license pool and is made available for other checkout requests.

Install Softing License Manager V4 on a PC with Internet connection from https://data-intelligence.softing.com/products/edge-connector-docker/datafeed-edgeconnector-siemens/#tx-dftabs-tabContent2.

Activate License with Internet Connection

License activation requires a computer with Internet access. If the connection to the Internet requires a proxy server, please make sure the connection settings are properly configured using the Proxy settings… button at the Settings page of the Configuration section.

Activate License Without Internet Connection

License Server Enduser Tools

LM-X end-user tools provide the functionality for the floating (network) licensing mechanism. These tools are deployed by the Softing License Manager installer (C:\Program Files (x86)\Softing\LicenseManager\LicenseServer\)

Tool File Name Documentation
LM-X License Server lmx-serv.exe https://docs.x-formation.com/display/LMX/LM-X+License+Server
LM-X End-user Utility lmxendutil.exe https://docs.x-formation.com/display/LMX/LM-X+End-user+utility
LM-X End-user Configuration Tool lmxconfigtool.exe https://docs.x-formation.com/display/LMX/LM-X+End-user+Configuration+Tool

License Server in Containerized Linux

The Docker container on Docker Hub can be found at this link.

To start the container, run the following command. The image will be pulled and the container started.

docker container run\
    --name licsrv\
    -p 6200:6200\
    --volume $(pwd)/license_files:/licsrv/licenses\
    softingindustrial/floating-license-server

NOTE: Replace licsrv with the name of the container used in a real-world scenario.

Retrieve the license server Host information

To activate licenses, the Host Id provided by the license server must be used. The Host Id is specific to the host on which the server is run.

Steps to get the Host Id from the containerized licensing server:

  1. From container logs:

     docker container logs licsrv
    

    Output:

     ...
     [2021-05-26 13:38:30] HostId: a476a2de-ca10-11e9-80d8e98fa9baf9c85
     ...
    

    The line above shows the Host Id information.

  2. From log file: the command docker exec -it licsrv cat /licsrv/lmx-serv.log will show the same output.

Steps to activate a license using Softing’s web interface

  1. Log in to Softing web portal

  2. Navigate to Licenses->Register License

  3. Fill in the purchased license activation key in the License key field

  4. Fill in the Host Id information retrieved as indicated in the previous sub-chapter

  5. Click Register License

  6. Download and store the generate *.lic file

Activating newly copied licenses

The downloaded *.lic files need to be copied to the mounted volume of the Docker container. This is how the license server will use them, stored in the persistent volume.

Once the new license files are copied to the shared volume, the container needs to be restarted in order for the new files to be activated.

docker restart licsrv

Technical Data

Name Value
Environment Ubuntu 18.04 LTS
Port 6200
Licenses Volume /licsrv/licenses
Config File /licsrv/lmx-serv.cfg
Log File /licsrv/lmx-serv.log
Address IP-Address from Host

Logs

To view the logs of the Docker container run the following commands:

  1. If the container is run with the -it (interactive) option, it will display all standard output and error messages in the terminal. If it is run with the -d option (daemon), the output logs can be retrieved via a docker command:

     docker container logs licsrv
    

    The output should look similar to the following, in both cases (interactive and daemon):

     [2021-05-26 13:38:30] LM-X License Server v4.9.23 build 74220bf8 on softing_licsrv (Linux_x64)
     [2021-05-26 13:38:30] Copyright (C) 2002-2020 X-Formation. All rights reserved.
     [2021-05-26 13:38:30] Website: https://www.lm-x.com https://www.x-formation.com
     [2021-05-26 13:38:30] License server has pid 1.
     [2021-05-26 13:38:30] Serving licenses for vendor SOFTING.
     [2021-05-26 13:38:30] WARNING: It is not recommended to run license server as root.
     [2021-05-26 13:38:30]
     [2021-05-26 13:38:30] License server using TCP IPv4 port 6200.
     [2021-05-26 13:38:30] License server using TCP IPv6 port 6200.
     [2021-05-26 13:38:30] License server using UDP IPv4 port 6200.
     [2021-05-26 13:38:30] Reading licenses...
     [2021-05-26 13:38:30] License file(s):
     [2021-05-26 13:38:30] /licsrv/licenses/<license_file>.lic
     [2021-05-26 13:38:30] Log file path: /licsrv/lmx-serv.log
     [2021-05-26 13:38:30] Log to stdout: Yes
     [2021-05-26 13:38:30] Log format: Normal
     [2021-05-26 13:38:30] Configuration file path: /licsrv/config/lmx-serv.cfg
     [2021-05-26 13:38:30] Serving following features:
     [2021-05-26 13:38:30] edgeConnector (v1.0) (5 license(s)) shared on: HOST USER VIRTUAL license type: additive
     [2021-05-26 13:38:30]
     [2021-05-26 13:38:30] HostId: a476a2de-ca10-11e9-80d8e98fa9baf9c85
     [2021-05-26 13:38:30] To administrate the license server go to your enduser directory and run the License Server Client.
     [2021-05-26 13:38:30] Ready to serve...
    
  2. In the output above the path to the licensing server log file. The command docker exec -it licsrv cat /licsrv/lmx-serv.log will show the same output, extracting the content of the log file from the container.

Volumes

License files

The Docker image from which the container is created is configured with a default internal Docker volume of /licsrv/licenses, into which the license files can be copied for the server to activate.

This internal volume can be mapped to the host machine in two ways:

Server configuration file

Similarly to the license files volumes, the container provides a way to expose the configuration file as well.

The default volume path for this is /licsrv/config and the file name is lmx-serv.cfg.

A number of parameters can be configured, based on the official X-Formation documentation.

The container must be restarted in order for the changes to take effect.

Mounting the volume should be done by using Docker Volumes:

NOTE: Use only volumes for the configuration file, not bind mounts. The latter will overwrite the internal container volume, making the configuration file inaccessible.

To edit the configuration file after the volume has been mapped, it can be found in the following path: /var/lib/docker/volumes/config_volume/_data/lmx-serv.cfg, where config_volume is the name of the Docker volume created. This path may change depending on host environment.

Bind Mounts for Windows

Bind mount license file diretory on Windows host

The above described scenarios are described for docker environments on linux hosts. If you are running a windows host, the steps are slightly different. Follow the description above to run the container (as linux container on windows host system).

Then use the following command to retrieve the HostID:

docker container logs licsrv

Then log in at mySofting and go to register license.

Enter the HostID and the License Key you received from Softing and download the .lic-File to your host.

Go to the host and create a new folder you want to use as license store. In this example, the folder docker_volume was created in the following path: C:\Users\fch\docker_volume

After the folder was created, it can be shared/bind mounted to the docker environment:

Now the downloaded .lic-File can be copied to the created folder.

With the following command, the license server is started together with the created folder/volume and the included license file:

docker container run -d -p 6200:6200 --name licsrv --volume c:\users\fch\docker_volume:/licsrv/licenses softingindustrial/floating-license-server

The last step is to activate the license server in the edgeConnector product:

Use the IP-Address from the host system and the port 6200. Click on save, navigate to operation and toggle a restart of the application to apply the changes. If the license was generated/detected correctly it will be shown on the license overview page:

Hint: The licsrv needs a restart, everytime new licenses are copied to the bind mounted volume to apply the new licenses!