Tuesday, August 5, 2014

License server hosted by Amazon Web Service

Hosting services in the cloud is more and more popular. As prices fall and processes simplify, a growing number of companies consider moving some services on dedicated machines provided  by cloud services such as Amazon Web Service (AWS).

Some of our customers have recently considered running the license server used to manage MOSEK licenses to a virtual machine provided by AWS. We think it may be an interested choice for other customers too. Here are the details.


A license server is a service that is used to provide access to a pool of licenses. When a user runs a MOSEK instance the solver asks the license server for a license token: if there is one available, the token is assigned to the requester. MOSEK relies on the FLEXlm license manager, a de-facto standard.

A license server is a lightweight process that can run on any machine that is accessible by the users. Yet it may require
  • a fast and reliable network connection;
  • a reliable machine to minimize down-time.
High-availability can be obtained by using a three-server redundant configuration. Otherwise, a  Disaster Recovery (DR) license can be provided for a backup machine.

Licenses are assigned to a specific machine, identified by a hostid, i.e. a unique code that the license manager generate for that machine (typically the MAC address).


Moving a license server on the cloud can be an interesting choice:

Access a common pool of licenses from different sites.
In this case a license server accessible from the Internet must be set up. Security and availability issues must carefully considered, while network latency is a minor issue.

Hosting a license server on the cloud solves most of the issues: the server is available from everywhere in the Internet; security management from the provider; reliable machines ensure limited or no downtime.

Hosting a DR license

Hopefully, a DR license server is only needed in exceptional cases. Nevertheless it must be kept running and fully working. This involves periodically testing the DR server to ensure its full availability.

A small virtual machine hosting a DR license server can be an alternative: it can be switch on when needed, no worries about its availability. Often it is also payed only for the up-time.

Simplify IT management

No more machine decommissioning: the cloud provider will take care of that and, as we will see, your license server will run machine independently. The server is also nowhere, takes no space,  must never be moved or taken care of. It will need no special room, and will not suffer of any local network or site re-organization.


Moving to the cloud is not always the solution:

  1. If speed is a concern, then the network latency may be unacceptable.
  2. It doesn't solve connection issues from a site to the license server.
  3. Lack of control over the virtual machine.
  4. Three-server redundancy would require three virtual machines.
  5. Yet another service provider to deal with.
  6. Running a license server in-house is usually way much cheaper. 


We will briefly describe how to setup a license server on a AMI instance from AWS. Similar steps are usually required for other cloud services.

The main issue is to obtain a hostid for an AMI instance that will not change after every machine reboot. Otherwise you will need a new license file each time.

The FLEXlm license server can use as hostid the Elastic IP (EIP) associated to each AMI instance: an EIP can be manually set by the user so that if the machine needs restart, the EIP can be reset to a given value, and thus the license server will be correctly assigned to the machine. For more information about the use of FLEXlm license manager on cloud machines, please refer to chapter 16 of the license manager manual.

So in a nutshell, deploying a license server on an AMI instance involves these few steps:

  1. Follow the official guide to obtain the EIP
  2. Send us the EIP to obtain the license file specifying the setting.
  3. Install MOSEK on the AMI instance along with the license file.
  4. Setup the clients so that they will look for that host to fetch the license (see here).
  5. In case adjust firewall permission and port listening.
That's it!

Any questions? Contact us!