Add License Key Information (ADDLICKEY)

Where allowed to run: All environments (*ALL)
Threadsafe: No
Parameters
Examples
Error messages

The Add License Key Information (ADDLICKEY) command can be used to add the software license key information to the license repository for products with keyed compliance. Products with "keyed compliance" require that you have a software license key from the software provider in order to change the usage limit or the expiration date of the license information.

The license repository stores product license information for each unique product, license term, feature, and system. The repository can contain licenses for any system, and the product need not be installed.

If the product is installed on the system and the license is for this system, this command installs the license, which changes the usage limit from the product's default usage limit to the licensed usage limit. The expiration date is also set.

If a software license key already exists in the repository for the unique product, license term, feature, and system, the software license key information is replaced.

If a license does not exist on the system, the added software license key uses the default values for its threshold (90 percent of the usage limit), message queue (*OPSYS), and log (usage limit violations are not logged) attributes. If a license exists, the values on these attributes do not change. To change any of these values, you can use the Change License Information (CHGLICINF) command.

Restrictions: This command is shipped with public *EXCLUDE authority.

Top

Parameters

Keyword Description Choices Notes
LICKEYINP License key input *PROMPT, *LICKEYFILE, *TAPE Optional, Positional 1
PRDID Product identifier Character value Optional, Positional 2
LICTRM License term Character value Optional, Positional 3
FEATURE Feature Character value Optional, Positional 4
SERIAL System serial number Character value, *LOCAL, *REMOTE, *ALL Optional
PRCGRP Processor group Character value, *ANY Optional
LICKEY License key Element list Optional
Element 1: Characters 1 - 6 Character value
Element 2: Characters 7 - 12 Character value
Element 3: Characters 13 - 18 Character value
USGLMT Usage limit 0-999999, 1, *NOMAX Optional
EXPDATE Expiration date Date, *NONE Optional
VNDDTA Vendor data Character value, *NONE Optional
LICKEYFILE License key file Qualified object name Optional
Qualifier 1: License key file Name
Qualifier 2: Library Name, *LIBL, *CURLIB
LICKEYMBR License key member Name, *FIRST, *LAST Optional
DEV Device Name Optional
VOL Volume identifier Character value, *MOUNTED Optional
SEQNBR Sequence number 1-9999, *SEARCH, *NEXT Optional
ENDOPT End of tape option *REWIND, *LEAVE, *UNLOAD Optional
Top

License key input (LICKEYINP)

Specifies how the software license key information to be added is supplied.

*PROMPT
The software license key information is supplied through prompting.
*LICKEYFILE
The software license key information is taken from the file specified on the LICKEYFILE parameter.
*TAPE
The software license key information is taken from a data file with the label QFILEPGMKEY on the tape device specified on the DEV parameter. The QFILEPGMKEY data file must be created on the tape using the Copy To Tape (CPYTOTAP) command, specifying a file in the format of QSYS/QALZAKEY on the FROMFILE parameter.
Top

Product identifier (PRDID)

Specifies the seven-character identifier of the product for which software license key information is added.

Top

License term (LICTRM)

Specifies the license term for which software license key information is added. This information is supplied by the software provider. Specify the license term in Vx, VxRy, or VxRyMz format, where x and y can be a number from 0 through 9, and z can be a number 0 through 9 or a letter A through Z.

Top

Feature (FEATURE)

Specifies the feature of the product specified on the PRDID parameter for which the software license key information is added.

5001
The software license key information for feature 5001 is added.
feature
Specify the number of the feature for which software license key information is added. Valid values range from 5001 through 9999.
Top

System serial number (SERIAL)

Specifies the serial number of the system for which software license key information is added.

Note: The *REMOTE and *ALL values are valid only when *LICKEYFILE or *TAPE is specified for the License key input (LICKEYINP) parameter.

*LOCAL
The software license key information for the local system is added.
*REMOTE
The software license key information for all remote systems named in the file specified on the LICKEYFILE parameter or in the tape file with the label QFILEPGMKEY is added.
*ALL
The software license key information for all systems named in the file specified on the LICKEYFILE parameter or in the tape file with the label QFILEPGMKEY is added.
system-serial-number
Specify the serial number of the system for which software license key information is added.
Top

Processor group (PRCGRP)

Specifies the system processor group for which software license key information is added. The software provider supplies this information with the software license key.

*ANY
The software license key is for any processor group.
processor-group
Specify the processor group of the system for which software license key information is added.
Top

License key (LICKEY)

Specifies the software license key that is supplied by the software provider. The license key has three elements, each of which are six characters long. Valid values for the characters are A-F and 0-9, and can be specified in the format: cccccc cccccc cccccc, where c is a valid character.

Top

Usage limit (USGLMT)

Specifies the usage limit for this product or feature. The software provider authorizes the value of the usage limit. For a concurrent usage limit, this is the maximum number of jobs allowed to access the product or feature at any given time. For a registered usage limit, this is the maximum number of license users that can be registered to use this product or feature.

1
The number of users is limited to one.
*NOMAX
The number of users is not limited.
usage-limit
Specify the maximum number of users for this product or feature. Valid values range from 0 through 999999.
Top

Expiration date (EXPDATE)

Specifies the expiration date of the product license. After this date, no users over the default usage limit can use the product or feature in compliance with this software license key.

The software provider supplies the expiration date with the software license key. To use the product after the expiration date, you must obtain a new software license key from the software provider.

*NONE
The license has no expiration date.
expiration-date
Specify the expiration date of the product license.
Top

Vendor data (VNDDTA)

Specifies the vendor data. The software provider supplies this information with the software license key.

*NONE
No vendor data is specified.
vendor-data
Specify a maximum of eight characters of vendor data.
Top

License key file (LICKEYFILE)

Specifies the qualified name of the file from which the software license key information is taken. This input file must be in the format of QSYS/QALZAKEY, and can be created by using the LICKEYFILE parameter on the Display License Key Information (DSPLICKEY) command.

The name of the license key file can be qualified by one of the following library values:

*LIBL
All libraries in the library list for the current thread are searched until the first match is found.
*CURLIB
The current library for the thread is searched. If no library is specified as the current library for the thread, the QGPL library is searched.
library-name
Specify the name of the library to be searched.

The possible value is:

license-key-file
Specify the name of the file that contains the software license key information.
Top

License key member (LICKEYMBR)

Specifies the name of the member in the file specified on the LICKEYFILE parameter from which the software license key information is taken.

*FIRST
The oldest member in the file is used.
*LAST
The newest member in the file is used.
license-key-member
Specify the name of the member from which to get information.
Top

Device (DEV)

Specifies the name of the tape device holding the tape from which the software license key information is copied.

Top

Volume identifier (VOL)

Specifies the volume identifier of the tape from which the software license key information is copied.

*MOUNTED
The volume currently placed in the device is used.
volume-identifier
Specify the identifier of the volume from which the software license key information is copied.
Top

Sequence number (SEQNBR)

Specifies the sequence number of the data file from which the software license key information is copied.

*SEARCH
A search is made for a data file with an identifier that matches the label QFILEPGMKEY.
*NEXT
The next sequence is used if that sequence is for a file with the label QFILEPGMKEY.
sequence-number
Specify the sequence number of the data file with the label QFILEPGMKEY to use for copying the software license key information.
Top

End of tape option (ENDOPT)

Specifies what positioning operation is done automatically on the tape volume after the software license key information is copied.

*REWIND
The tape is automatically rewound, but not unloaded, after the operation has ended.
*LEAVE
The tape does not rewind or unload after the operation ends. It remains at the current position on the tape drive.
*UNLOAD
The tape is automatically rewound and unloaded after the operation ends.
Top

Examples

Example 1: Adding License Key Information from Prompt Input

ADDLICKEY   LICKEYINP(*PROMPT)  PRDID(1MYPROD)
            LICTRM(V3)  SERIAL(1234567)
            PRCGRP(P20)  LICKEY(123456 7890AB CDEF12)
            USGLMT(30)  EXPDATE(*NONE)  VNDDTA(12345678)

This command uses prompting to add the software license key information for feature 5001 of the product 1MYPROD to the license repository. The license term is Version 3. The license allows 30 users to use the system with serial number 1234567. That system is in the processor group of 20 or less. There is no expiration date on the license. Because the product is installed on a system with the specified serial number, the license also is installed.

Example 2: Adding All License Key Information from File Input

ADDLICKEY   LICKEYINP(*LICKEYFILE)  SERIAL(*ALL)
            LICKEYFILE(*LIBL/MYKEYFILE)  LICKEYMBR(*LAST)

This command adds the software license key information for all of the systems in the newest member of the file MYKEYFILE to the license repository. If the product is installed on the system, and the license is for this system, the license also is installed.

Example 3: Adding Local License Key Information from a License Key File

ADDLICKEY   LICKEYINP(*LICKEYFILE)  SERIAL(*LOCAL)
            LICKEYFILE(*LIBL/MYKEYFILE)  LICKEYMBR(*FIRST)

This command adds the software license key information found in the oldest member of the file MYKEYFILE to the license repository for this system only. If the product is installed on this system, the license is also installed.

Example 4: Adding Local License Key Information from Tape

ADDLICKEY   LICKEYINP(*TAPE)  DEV(TAP01)

This command searches the mounted volume on device TAP01 for the label QFILEPGMKEY. This data file is used and all software license keys for the local system are added to the repository. The tape is rewound after the operation.

Top

Error messages

*ESCAPE Messages

CPF9E2D
Usage limit cannot be less than current usage.
CPF9E56
&1 license key information records added, &2 not added.
CPF9E6C
The license key cannot be used for processor group &2.
CPF9E6E
Product identifier &1 not valid.
CPF9E69
License key information not found in license key file.
CPF9E80
Error occurred during restoring license keys from tape.
CPF9E83
Expiration date &2 is not valid.
Top