Table of Contents
- Install a License via GAMS Studio
- Install a License Manually
- License Problems
- Errors
- License File too old for this Version of GAMS
- License File has expired xx days ago
- Node ID in License File in Incorrect Format
- Node ID Does Not Match License Node ID
- User Name Does Not Match License User Name
- Number of Cores Exceeds Licensed Number of Cores
- Total Memory Exceeds Licensed total Memory
- Network License Without Interprocess Port Not Allowed at this Point
- Expired Network License
This section deals with the installation of a GAMS license. Information on different license types and licensing in general can be found on our website.
The classic GAMS license consists of six lines of text typically delivered via email. Users need to copy and paste this text into a file in some designated locations on their hard drive so GAMS can find it. In addition to this email-based delivery method, GAMS will increasingly rely on a modern delivery method for licenses. This approach supports new licensing options, such as network licenses, providing greater flexibility and improved resource management capabilities. Introduced in GAMS version 47, this license delivery method will continue to be refined over time. The core of this new method is a 36-character access code to the license. The access code enables users to retrieve their GAMS license from a license server, which provides an eight-line text-based license that again needs to be stored on the user's hard drive.
Install a License via GAMS Studio
The simplest way to install a license is through GAMS Studio. For detailed instructions, please refer to the GAMS Studio documentation.
Install a License Manually
If using GAMS Studio is not an option, you can install the license manually. If you received the license contents via email, copy all the lines into a new file named gamslice.txt
and place this file in a location searched by GAMS. If you received the GAMS license as a 36-character access code, read more below.
- Attention
- If you install GAMS on macOS using the self-extracting archive, do not store the
gamslice.txt
in the GAMS system directory. Read more about this here.
Obtaining a License using an Access Code
Installing and activating a license using an access code is done using the command-line utilities gamsgetkey
and gamsprobe
that are located in the GAMS installation directory.
- Navigate to a directory that GAMS searches and where you have write permissions.
Activate your license by running
gamsgetkey
in the terminal, using the access code as an argument. For example:/path/to/GAMS/installation/directory/gamsgetkey xxyyzzxx-yyzz-xxyy-zzxx-yyzzxxyyzzxx > gamslice.txt
Using output redirection (
> gamslice.txt
) will send the command-line output directly to a file. Alternatively, you can omit this part and manually copy the output to a file.- Note
- When using the
gamsgetkey
utility (or the GAMS licensing dialog in GAMS Studio, see above) to activate a license, the access code, along with the node ID, username, number of cores, and available memory, is sent to the GAMS license server once. This information is used to determine the validity and scope of the license. If network communication is not possible, use thegamsprobe
utility as described in Obtaining a License without Network Communication.
- If not already done, place the
gamslice.txt
in a location searched by GAMS.
Obtaining a License without Network Communication
For machines that are not connected to the internet, you can probe the node's data and get a license via a machine connected to the internet. Follow these steps:
On the target machine, navigate to a directory where you have write permissions and run
gamsprobe
to gather necessary device data:/path/to/GAMS/installation/directory/gamsprobe > info.json
Using output redirection (
> info.json
) will send the command-line output directly to a file. Alternatively, you can omit this part and manually copy the output to a file.Transfer the
info.json
file and the access code to a machine with network access. There, rungamsgetkey
to activate the license:/path/to/GAMS/installation/directory/gamsgetkey xxyyzzxx-yyzz-xxyy-zzxx-yyzzxxyyzzxx -i info.json > gamslice.txt
- Transfer the
gamslice.txt
to the target machine and place it in a location searched by GAMS.
License Problems
Errors or warnings triggered by a problem with the GAMS license file (gamslice.txt) are reported in stdout. In GAMS Studio these are visible in the system log. Below are some typical error and warning messages and instructions on how to overcome them.
No License File present
Without a license file, GAMS will not work. If you have received a license file or access code, follow the instructions from the previous section. Do not rename the license file or modify its contents. Without a license GAMS will give you an error message like the one below:
*** Error: No license file found.
Note that this error should not normally occur, as a demo license is included with every GAMS installation.
License File Invalid or Corrupted
Running GAMS with an invalid license will give you an error message like the one below:
*** Error: The installed license C:\Users\username\Documents\GAMS\gamslice.txt is invalid.
Do not try to modify your license file, any change will break it. If you received the license via email but no longer have the original file, please contact sales@gams.com and ask for a copy of your license file. Please attach the license file you are currently using. If your GAMS license was provided as a 36-character access code, you can re-install the license using the access code either through GAMS Studio or manually. Note that this must be done on the machine for which the license was issued.
This error also occurs if you are using a license file that was issued for a different platform.
License File expired
If you try to use an old license file with a newer GAMS distribution, you might encounter an error message stating:
*** License file too old for this version of GAMS. *** Maintenance expired 2840 days ago. *** More than 60 days since expiration, sorry... *** Run an older GAMS system or renew the license
Replace that GAMS system with the one you got together with your license file (use the Check for Update utility of GAMS Studio to find out the latest version you can use with the current license; old systems are available on request from sales@gams.com) or update your license to the current version.
No License (for a particular Solver) found
If a solver you are trying to use (or the default solver) is not included in your license file, and the model size exceeds the limits of the free demo or community version, you will get an error stating:
*** No license found *** To update your license, please contact your distributor.
Check whether the default solvers for a particular problem class are included in the license. Please note that some of the solvers call other solvers as a sub-solver. For example, GAMS/DICOPT requires an NLP and a MIP solver.
Errors
License File too old for this Version of GAMS
The complete message is:
*** License file too old for this version of GAMS. *** Maintenance expired xx days ago.
If GAMS continues working, you can ignore this warning. However, any forthcoming GAMS distribution will most likely not work, but downgrade to the limits of the free demo system.
License File has expired xx days ago
This warning (without further error messages) indicates that the time limited license (e.g. an evaluation license) will stop working soon.
Node ID in License File in Incorrect Format
The node ID specified in the license file does not follow the required format. This may result from a manual entry error or misconfiguration during license generation. Please verify the node ID format and ensure it complies with the expected structure.
Node ID Does Not Match License Node ID
The node ID of the system does not match the node ID registered in the license file. Ensure that the correct node ID is used when generating the license.
User Name Does Not Match License User Name
The user name of the system running GAMS does not correspond to the one registered in the license. Verify that the correct system user name is associated with the license to resolve this issue.
Number of Cores Exceeds Licensed Number of Cores
The current system configuration uses more CPU cores than permitted by the license. To resolve this, reduce the number of cores used, or obtain a license that supports the higher core count.
Total Memory Exceeds Licensed total Memory
The total memory available on the system exceeds the amount specified in the license. To comply with the licensing agreement, adjust the memory allocation or acquire a license that supports the system's memory capacity.
Network License Without Interprocess Port Not Allowed at this Point
The use of a network license without an interprocess communication port is prohibited at this point. Ensure that the necessary port is configured and available to maintain network license functionality.
Expired Network License
The network license has expired, preventing continued access to the software. To restore functionality, renew the license or apply an updated license file with a valid expiration date.