Difference between revisions of "Licensing"

From YateBTS
Jump to: navigation, search
m (Operations on products machine)
Line 9: Line 9:
** One license per server
** One license per server
** Each license is bound to only one server/virtual machine
** Each license is bound to only one server/virtual machine
* [[Licensing#Products_and_Licenses_on_a_License_Server | '''Products and licenses on different servers''']]
* [[Licensing#Products_and_Licenses_on_different_servers | '''Products and licenses on different servers''']]
** One server can hold N number of licenses
** One server can hold N number of licenses
** All licenses are bound to the License Server.
** All licenses are bound to the License Server.

Latest revision as of 17:32, 1 February 2019


Our licensing system, called "CodeMeter" is provided in collaboration with Wibu-Systems, one of the top suppliers in the industry.

Our clients (hereinafter called "licensee") must activate license on their machine, as our licensing system permits that one licence can cover any of our Core Network Products installed or used on a single machine (virtual or not).

There are two major usage scenarios:

License activation is strongly bounded to the hardware, because on any license request (as action) made by the licensee, a machine fingerprint (containing hardware, environment and OS informations) is generated and stored in the .WibuCmRaC file.

In case of a Virtual Machine the license will be bound to characteristics of both the VM and the host's hardware.

Moving the VM to another host would invalidate the license so in this case it is undesirable to install the license in the VM, a separate license server should be used.

If the stability of hardware cannot be guaranteed please see the USB Dongle alternative below.

To obtain a license request code, log in to your machine and use yate-mgmt command-line utility as shown in License request

The .WibuCmRaC file (which also contains the license request code) must be sent to us via Support system and in turn, we will send back an update file ( .WibuCmRaU ) to the licensee.

With this file, a license update operation is made only once on the licensee machine.

This procedure sums 'license update' and 'license receipt' operations and will be made also with yate-mgmt as shown in License activation

Once license is updated and license receipt is generated, please upload license receipt to our Support system.

This procedure will allow future rebuilding of the license on that specific machine if the license is destroyed.



All our Yate based core products are built on top of Mageia 5 so this Linux distribution should be already installed on the machine.

On every machine with private Yate packages installed, we need to add the YateCore repository and install the yate-mgmt-core package as root.

[yate@licensee-machine][~]$ su -
[root@licensee-machine][~]# urpmi.addmedia --update YateCore http://repo.yate.ro/licensed/mga5/x86_64
[root@licensee-machine][~]# urpmi yate-mgmt-core

These packages will be installed: yate-mgmt-core-*.mga5.noarch , yate-mgmt-*.mga5.noarch and CodeMeter-*.x86_64

If repository access is restricted to users who authenticate with a username and password, please edit /etc/urpmi/urpmi.cfg file, to contain in the first set of braces curl-options specifying username and password as shown below.

[root@licensee-machine][~]$ head -n 5 /etc/urpmi/urpmi.cfg 
  curl-options: --user username:password

Our work as root is temporarily done, to exit root environment, just type 'exit'

[root@licensee-machine][~]# exit

After the installation we will have yate-mgmt in our /usr/bin directory, typing yate-mgmt (we can check if yate-mgmt-core installed successfully) in your console we will have this output message:

[yate@licensee-machine][~]$ yate-mgmt
Usage: yate-mgmt options...
    --cert-view [filename.txt]                Display Apache SSL certificate
    --cert-update filename.pem                Update Apache certificate and restart service
    --license-view [filename.txt]             View current license information
    --license-dump [filename.txt]             Dump Wibu licensing info for troubleshooting          
    --license-verbose [filename.txt]          Show details about current licenses                   
    --license-prepare [filename.wbb]          Create license container from template                
    --license-request [filename.WibuCmRaC]    Create a license request                              
    --license-update filename.WibuCmRaU       Install or update license, use - for stdin            
    --license-receipt [filename.WibuCmRaC]    Create a license activation receipt                   
    --license-deactivate [filename.WibuCmRaC] Create a license deactivation request

Verifying and preparing environment

The environment must be set up on the client's machine or on his license server (if there is one -> check License on a License Server section).

Before we install any license we must check if there are current license information on licensee system by typing: "yate-mgmt --license-view" or the short command: yate-mgmt -lv

[yate@licensee-machine][~]$ yate-mgmt -lv

If there is no result it means our licensee system has no license at all and we may continue.

To add a license we must prepare the environment for the license by creating a license container with the command: "yate-mgmt --license-prepare" or we can use the short command yate-mgmt -lp

[yate@licensee-machine][~]$ yate-mgmt -lp

You may skip preparation in this case this step is executed automatically when creating a License Request.

License request

Next in our process is the license request step and by typing "yate-mgmt --license-request" or the short command yate-mgmt -lr

A file ending in .WibuCmRaC is created. The license request generates and stores also the machine fingerprint in the license request file (ending in .WibuCmRaC)

License request will be made on licensee machine. If our Core Network products are not running on the same machine, check License on a License Server section.

[yate@licensee-machine][~]$ yate-mgmt -lr
[yate@licensee-machine][~]$ ls *Wibu*
-rw-r--r--  1 yate yate  33358 Sep  2 15:57 32767-16385_5000676.WibuCmRaC

The generated file (in our case 32767-16385_5000676.WibuCmRaC) must sent to us via our Support system.

We will send a .WibuCmRaU file used for licence update which will generate a licence receipt. Generated license receipt file must be sent to us in order to activate the license.

License activation

The license update procedure sums 'license update' and 'license receipt' operations and are will be made with yate-mgmt as shown below:

[yate@licensee-machine][~]$ yate-mgmt -lu 15767-16385_5000676.WibuCmRaU
[yate@licensee-machine][~]$ yate-mgmt -lR 

After that a new file ending in .WibuCmRaC is generated (128-26881_5000676-receipt.WibuCmRaC), please upload the file to our Support system.

The license request operation also changes the license container on the licensee machine from 32767-16385_5000676 to 128-26881_5000676.

This change can be verified with yate-mgmt --license-view command.

[yate@licensee-machine][~]$ yate-mgmt --license-view
SER=128-26881 FC=5000676 PC=100 QTY=1 FEAT=0x8000000f NAME=Yate based core network products

Finalizing installation

Once the license is set up it is time to install the product themselves on their machines. This job needs root access.

Here is an example for installing YateHSS:

[yate@licensee-machine][~]$ su -
[root@licensee-machine][~]# urpmi yate-hss
[root@licensee-machine][~]# systemctl status yate-hss.service
● yate-hss.service - YATE based Home Subscribers Server
   Loaded: loaded (/usr/lib/systemd/system/yate-hss.service; enabled)
   Active: active (running) since Tue 2017-06-06 17:45:33 CEST; 14s ago

Products and Licenses on the same server

Below, there are four scenarios:

1. Single server with license as file 2. Single server with license s USB

3. Single VM with license as file 4. Single VM setup with USB license


Products and Licenses on different servers

Licenses are installed on a License Server (we recommend a physical machine), because any hardware changes will invalidate the licenses.

Yate products (Core network products) are running on different machines than the License Server.

In the pictures below are two scenarios:

1. license as file 2. license as usb


In this two cases Yate Core products are running on VMs in two different servers and the License Server is running on another server.

Each VM must have yate-mgmt-core package installed as described in Requirements chapter.

License prepare and license request operations will be made on the License Server, because there will be stored/installed license files.

Below are detailed changes that should be made on License Server settings from CodeMeter WebAdmin:

  • Activate network server
  • Add IP addresses of Yate services machines in License Access Permission

Easy access & Forwarding

CodeMeter License Server by default works on port 22350 and it accepts connexions only from, to access it a local port forwarding is needed.

We will connect trough ssh and forward remote 22350 port to local 8035 port like this:

[user@localhost][~]$ ssh -L 8035:localhost:22350 yate@license-server
Last login: Tue Sep  6 14:24:33 2016 from about.lan

Operations on License Server

  • Open in browser http://localhost:8035/ and see the output of the license server on port 22350 (the CodeMeter default port).
  • Enable Network Server from menu -> Configuration -> Server -> Server Access tab -> Network Server -> [X] Enable

CodeMeter License Server.png

  • Add licensee machine IP address in License Access Permission tab next to Server Access tab by clicking 'Add' and then Apply.
  • Restart CodeMeter service
[root@license-server][~]# systemctl restart codemeter.service

Operations on products machine

Add License Server IP address in Server Search List from CodeMeter WebAdmin for each machine were Yate is installed.

  • Connect trough ssh and forward remote 22350 port of licensee machine were Yate products are running to local 8034 port like this:
[user@localhost][~]$ ssh -L 8034:localhost:22350 yate@licensee-machine
  • Open http://localhost:8034/ in browser and modify CodeMeter settings, to search for licenses on a specific IP address (IP address of the License Server).
    • Configuration -> Basic -> Server Search List : Add server IP address -> Apply

CodeMeter Licensee Machine.png

  • It is very important to restart CodeMeter service so changes can take effect.
[root@licensee-machine][~]# systemctl restart codemeter.service

License on USB Dongle

For special cases we may provide licenses on an USB dongle. In this case the license is not tied to the machine hardware but to the dongle.

On the machine where the Application or the License Server is to be run only the CodeMeter package needs to be installed.

Licensed products pull the package automatically but on a license server it needs to be installed manually from the YateCore repository.

Since the license comes preinstalled on the dongle most of the procedures above are not required. Just plug in the USB dongle and wait a few seconds.

If the license server or product runs in a Virtual Machine the USB device needs to be forwarded from the host to the guest.

Please see case 4. from Product and licenses on the same server

If the USB dongle is used as a License Server then the product machine still needs to be set up to connect to server.