db2licm - License management tool command

You can run the db2licm command to add, remove, list, or modify licenses and policies installed on the local system.

Note: Under the processor Value Unit (PVU) licensing structure, each processor core is assigned a specific number of Value Units. You must get the total number of PVUs for each processor core on which the software programs are deployed. IBM defines a processor as each processor core on a chip. For example, a dual-core chip contains two processor cores.

Each software program has a unique price per Value Unit. To determine the total cost of deploying an individual software program, you multiply the program price per Value Unit by the total number of processor Value Units required.


Attention: Because Db2® cannot limit itself to a specified number of CPU cores, you must limit your Db2 environment to match your Db2 license. In some instances, Db2 returns an ADM12017E message or similar message, stating that you are exceeding your defined processor entitlement.

Authorization

On Windows operating systems:
  • You must belong to the local Administrators or Power Users group to use the -a, -r, or -x command parameters.
  • SYSADM authority is required to use the -c, -e, -p, -r, or -u command parameters.

On UNIX and Linux® operating systems, no authority is required.

Required connection

None

Command syntax

Read syntax diagramSkip visual syntax diagramdb2licm-afilename-eproduct-identifierHARDSOFT-pproduct-identifierCONCURRENTOFF-tdatabase-nameusernamepassword-rproduct-identifier-uproduct-identifiernum-users-cproduct-identifiernum-connectors-mproduct-identifiernum-cores-gfilename-x-lSHOW DETAIL-v-h-?

Command parameters

-a filename
Adds a license for a product. Specify a file name containing valid license information. This can be obtained from your licensed product CD or by contacting your IBM representative or authorized dealer.
-e product-identifier
Updates the enforcement policy on the system. By default, out of compliance usage is logged in the compliance report. Valid values are: HARD or SOFT.
HARD
Specifies that unlicensed requests are restricted in these cases:
  • Row compression: Specifies that the following operations return an error message without a valid license entitlement for row compression:
    • CREATE or ALTER TABLE statement with the COMPRESS YES clause.
    • CREATE or ALTER INDEX statement with the COMPRESS YES clause.
  • Native encryption: Specifies that the following commands return an error message without a valid license entitlement for the IBM® Db2 Encryption Offering:
    • CREATE or BACKUP DATABASE command with the ENCRYPT parameter.
    Note: Changing Db2 product editions does not change the entitlement policy to SOFT.
SOFT
Specifies that unlicensed requests are logged in the compliance report, but not restricted.
-p product-identifier
Updates the license policy type to use on the system.
CONCURRENT
Specify for concurrent user policy.
OFF
Specify to turn off all policies.
-t database-name username password
Displays the user data that is stored in all the user tables of the specified database. Provides data consumption for Terabyte license usage scenarios. Specify the database name, user name, and password. Run the command with this option as an instance user.
-r product-identifier
Removes the license for a product. To get the product identifier for a specific product, invoke the command with the -l option.
-u product-identifier num-users
Updates the number of user licenses that the customer has purchased for record keeping. Specify the product identifier and the number of users. Note that there is no enforcement on the actual number of users.
-c product-identifier num-connectors
Updates the number of connector entitlements that the customer has purchased for record keeping. Specify the product identifier and the number of connectors. Note that there is no enforcement on the actual number of users.
-m product-identifier num-cores
Updates the number of cores entitlements that the customer has purchased for record keeping. Specify the product identifier and the number of cores. Note that there is no enforcement on the actual number of cores.
-g filename
Generates compliance report. Specify file name where output is to be stored.
Note: You must restart the database to get the most up to date license compliance report. Processor, socket, core, memory and other system restrictions are not included in the compliance report.
-x
Resets license compliance information for the purposes of license compliance report.
-l
Lists all the products with available license information, including the product identifier.
SHOW DETAIL
Specify to view detailed information about licensed features (if any).
-v
Displays version information.
-h | -?
Displays help information. When this option is specified, all other options are ignored, and only the help information is displayed.

Examples

Example 1:

Basic examples:
   db2licm -a db2adv_vpc.lic
   db2licm -r db2adv
   db2licm -e db2adv SOFT
   db2licm -t testdb jmathew temp4now
      

Example 2:

Output example listing all the products with available license information, including the product identifier:
/db2licm -l

Product name:                     "IBM DB2 Developer-C Edition"
License type:                     "Community"
Expiry date:                      "Permanent"
Product identifier:               "db2dec"
Version information:              "11.5"
Max amount of memory (GB):        "16"
Max number of cores:              "4"
Max amount of table space (GB):   "100"

Product name:                     "DB2 Advanced Edition"
License type:                     "Virtual Processor Core"
Expiry date:                      "Permanent"
Product identifier:               "db2adv"
Version information:              "11.5"
Enforcement policy                "Hard Stop"
Features:                          
IBM Db2 Performance Management Offering: "Not licensed"
Note: In Linux the db2licm -l command writes the following informational message to /var/log/messages:
   kernel: Program db2licm tried to access /dev/mem between 1f0000000f0000->10100000000.

Example 3: A CREATE DATABASE command with the ENCRYPT parameter fails when enforcement policy is set to HARD

Set the enforcement policy to hard:
db2licm -e db2adv HARD
When the enforcement policy is set to HARD, a CREATE DATABASE command with the ENCRYPT parameter fails. For example,
db2licm -l
Product name:                     "Db2 Advanced Edition"
License type:                     "Virtual Processor Core"
Expiry date:                      "Permanent"
Product identifier:               "db2adv"
Version information:              "11.5"
Enforcement policy:               "Hard Stop"
Features:
IBM Db2 Performance Management Offering: "Not licensed"
db2 create database samptab1 ENCRYPT
SQL8029N  A valid license key was not found for the requested functionality.
Reference numbers: "8".