Who needs a license for kdb+?
Everyone. All use of kdb+ is governed by a license.
64-bit installations require a license key file:
Licenses at kx.com
Free, non-commercial, 64-bit kdb+ on demand
Free 64-bit kdb+ On-Demand Personal Edition is for personal, non-commercial use. Currently, it may be used on up to 2 computers, and up to a maximum of 16 cores per computer, but is not licensed for use on any cloud – only on personal computers. It may not be used for any commercial purposes. See the full terms and conditions.
It requires a
kc.lic license key file and an always-on internet connection to operate.
Free, non-commercial, 32-bit kdb+
Use of the free, non-commercial, 32-bit kdb+ distribution, is governed by the 32-bit terms and conditions.
No license key file is required. When you start kdb+ the banner shows your license has no expiry date.
KDB+ 3.6 2018.07.30 Copyright (C) 1993-2018 Kx Systems m32/ 4()core 8192MB sjt mint.local 192.168.0.39 NONEXPIRE Welcome to kdb+ 32bit edition
Use of commercial kdb+ is covered by your license agreement with Kx.
Your copy of kdb+ will need access to a valid license key file.
If you wish to begin using kdb+ commercially, please contact firstname.lastname@example.org.
License key files
All 64-bit versions of kdb+ need a valid license key file to run.
Without one, kdb+ signals an error
'k4.lic and aborts.
tom@mb13:~/q$ q KDB+ 3.6 2018.07.30 Copyright (C) 1993-2018 Kx Systems m64/ 2()core 8192MB tom mb13.local 192.168.1.44 'k4.lic tom@mb13:~/q$
The license key file is
kc.lic for kdb+ On Demand.
If both are found, the
kc.lic file is used.
(The 32-bit kdb+ distribution does not require a license key file.)
Obtain a license key file
License key files (
kc.lic) are distributed by email.
An unlicensed kdb+ session aborts: see above. The banner at the top of the aborted session contains machine-configuration information but no license information.
Your Designated Contact sends a copy of the banner to email@example.com to request a license file by return.
Each Kx customer designates to firstname.lastname@example.org a couple of technical people as the Designated Contacts for issues with kdb+, managing licenses and downloading software.
Install the license key file
Save a copy of the license key file (
kc.lic) in the
(See installation instructions for your operating system.)
Restart your kdb+ session and note the change in the banner.
tom@mb13:~/q$ q KDB+ 3.6 2018.07.30 Copyright (C) 1993-2018 Kx Systems m64/ 2()core 8192MB tom mb13.local 192.168.1.44 EXPIRE 2019.05.15 email@example.com #400 q)til 6 0 1 2 3 4 5 q)
Note the license number (
#400 in the example) and quote it in any correspondence about the license.
If you are sharing use of a commercial license, you will probably want to set the environment variable
QLIC to the path of the license key file, as below.
Keeping the license key file elsewhere
The default location for the license key file is the
QHOME folder. You do not have to keep the license key file there. You can use the environment variable
QLIC to specify a different filepath.
Folder not file
QLIC points to a folder, not a file. For example,
Licensing server for kdb+ On Demand
As well as a license key file, kdb+ On Demand also requires frequent contact with the Kx licensing server. For this you need an always-on Net connection.
If kdb+ cannot contact the Kx server it will abort with a timestamped message.
'2018.03.28T11:20:03.831 couldn't connect to license daemon -- exiting
If the license is for fewer cores than the total number on the machine, the number of cores available to kdb+ must be restricted with OS programs, or kdb+ will signal
'cores and abort.
KDB+ 3.6 2018.07.30 Copyright (C) 1993-2018 Kx Systems m64/ 4(3)core 16384MB simon simon-macos.local 127.0.0.1 firstname.lastname@example.org #40000 'cores
As long as you use
numa correctly, the binary will not abort itself.
You can see the number of cores entitled to a q process:
- by looking at the banner, e.g.
…m64/ 4(3)core…– the 4 here is the number of cores reported by the OS, and the 3 is the number of cores licensed
.z.c– not the physical cores of the system, but rather the number the process is allowed to use
- the first element of
The number of licensed cores is always 16 for the on-demand license.
On the road
The license key file binds the interpreter to your computer’s hostname.
For example, for a Mac named
mymbp the hostname might be
When travelling you may find a network has changed the hostname, for example to
mymbp.fritz.box. Kdb+ then signals a host error on launch.
Linux and macOS users can restore their hostnames from the command shell, e.g.
scutil --set HostName "mymbp.local"
Designated Contacts should send license questions to email@example.com.
Emergency failover licenses
In case of an emergency, such as a hardware or infrastructure failure that renders your license key file unusable, the Designated Contact can email firstname.lastname@example.org to request a temporary failover license to allow use of a different machine or IP address.