After you install the Db2 service, you can upgrade your license from Db2 Community Edition to Db2 Advanced Edition.
About this task
You can upgrade your Db2 Community Edition license to any of the Db2 11.5 production licenses:
Table 1. Processor and memory limits per
Db2 server or pureScale®
cluster
Db2 edition |
Processor cores |
Allowed instance memory |
Advanced |
Unlimited |
Unlimited |
Standard |
Up to 16 |
128 GB |
Community |
Up to 4 |
16 GB |
You can download the license keys for the Advanced and Standard editions from the IBM® Passport Advantage® site:
- Db2 Advanced Edition: db2adv_vpc.lic
- Db2 Standard Edition: db2std_vpc.lic
Note: You must be entitled to use a license before you can download it. Ensure that you or your
organization purchased the required license.
Procedure
-
Encode your license to base64 by running the following command:
base64 license.lic > /tmp/encode.lic
license=$(cat /tmp/encode.lic)
- Optional: Create a secret by using the license from Step 1. For
example:
apiVersion: v1
data:
${secretKeyName}: ${license}
kind: Secret
metadata:
name: ${secretName}
namespace: ${PROJECT_CPD_INSTANCE}
type: Opaque
Note: The value you set
secretKeyName
and
secretName
to must be
supported by
Kubernetes. For more
information on supported object names, see
Object Names and IDs in the
Kubernetes documentation.
- Patch Db2oltpservice with the license information.
- If you completed the previous optional step, run the following
command:
oc patch Db2oltpservice db2oltp-cr --type merge -p "{\"spec\":{\"license\":{\"license\":\"$licenseType\",\"licenseValue\":{\"valueFrom\":{\"secretKeyRef\":{\"key\":\"$secretKeyName\",\"name\":\"$secretName\"}}}}}}"
where
$licenseType
is either Advanced or Standard,
depending on which license is being upgraded; $secretName
is the name of the secret
that was created in the previous optional step; and $secretKeyName
is the name of
the key value for the secret that was created in the previous optional step.
- If you did not complete the previous optional step, run the following
command:
oc patch Db2oltpservice db2oltp-cr --type merge -p "{\"spec\":{\"license\":{\"license\":\"$licenseType\",\"licenseValue\":{\"value64\":\"$license\"}}}}"
where
$licenseType
is either Advanced or Standard,
depending on which license is being upgraded; and $license
is the base64 encoded
value from Step 1.
- Wait for the Db2 service to be in
Completed
state. To get the state value, run the following
command:
oc get Db2oltpService db2oltp-cr -o jsonpath='{.status.db2oltpStatus} {"\n"}'