Skip to content

Updates module name in metadata and readme #21

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
46 changes: 43 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
# CP4D - DB2 Warehourse Gitops terraform module
# CP4D - DB2 Warehouse service gitops module

### DB2WH Pre-Req
This module populates a gitops repository with the resources necessary to provision the underlying DB2 Warehouse services that a pre-requisites to create a DB2 Warehouse instance. After this module is provisioned a DB2 Warehouse instance can then be created manually by following the steps below or by provisioning the [gitops-cp-db2wh](https://github.com/cloud-native-toolkit/terraform-gitops-cp-db2wh) module.

## DB2WH Pre-Req

Ensure that a cluster administrator completed the required Pre-installation tasks for your environment. Specifically, verify that a cluster administrator completed the following tasks:

Expand Down Expand Up @@ -72,6 +74,45 @@ Run this CLI and check if the DB2WHService completed.

Db2 Warehouse is ready when the command returns "Completed".

### Create DB2WH database instance manually

#### Grant additional privileges

You must grant additional privileges to enable the web console to validate the CPU and memory values that you select for your deployment.

1. To add these privileges, run the following command on the OpenShift® cluster:

```shell
oc adm policy add-cluster-role-to-user system:controller:persistent-volume-binder system:serviceaccount:${NAMESPACE}:zen-databases-sa
```

`${NAMESPACE}` refers where you have created the DB2OLTP instances

2. After you run the command, the console is able to validate your selections by checking the available number of nodes on the cluster, whether the nodes are properly labeled and tainted, and the amount of available CPU and memory.

#### Create the instance from the console

You can manually create the database for DB2WH by following the instructions https://www.ibm.com/docs/en/cloud-paks/cp-data/4.0?topic=warehouse-creating-database-deployment

> This step will create the database on the cluster using CP4D Console

This will create a database using many of the default values. You can adjust through the process for any resources you wish to change to support your requirements.

![DB2WH DB Instance ](images/db2wh-db.jpg)

1. Login to CPD console
2. From the hamburger menu select "Data->Databases"
3. Click **Create a database** and select a database type. Click **Next**.
4. On the "Configure" step, provide the database name, number of nodes, CPU per node, and memory per node. Click **Next**.
5. On the "Advanced configuration" step, select `multiple logic nodes` and the `Analytics` workload. Click **Next**.
6. On the "System storage" step, select `portworx-db2-rwx-sc` and size of `100 GB`. Click **Next**.
7. On the "User storage" step, select `portworx-db2-rwx-sc (RWO with 4K block size)`, set the size to `100 GB`, and the access mode to `ReadWriteOnce`. Click **Next**.
8. On the "Backup storage" step, click **Create new Storage**, select `Use storage template`, set the storage class to `portworx-db2-rwx-sc`, and set the size to `100 GB`. Click **Next**.
9. On the "Transaction logs storage" step, select `Use storage template`, set the storage class to `portworx-db2-rwx-sc (RWO with 4K block size)`, and the size to `100 GB`. Click **Next**.
10. On the "Temporary table spaces storage" step, select `Use storage template`, set the storage class to `portworx-db2-rwx-sc (RWO with 4K block size)`, and set the size to `100 GB`. Click **Finalize**.

As a result, Database for DB2WH will be created.

### DB2WH Service (instance) removal - Finalizer

Run this CLI and remove the finalizer value from the YAML as sometimes DB2WH service getting stuck.
Expand All @@ -86,4 +127,3 @@ Run this CLI and remove the finalizer value from the YAML as sometimes DB2WH ser

- [DB2 Warehouse Knowledge Center](https://www.ibm.com/docs/en/cloud-paks/cp-data/4.0?topic=services-db2-warehouse)


Binary file added images/db2wh-db.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
10 changes: 3 additions & 7 deletions module.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: gitops-cp-db2wh
type: terraform
description: ""
name: gitops-cp-db2wh-service
type: gitops
description: "Module to populate a GitOps repo with the resources to deploy the underlying DB2 Warehouse services from CP4D required to create a DB2 Warehouse instance"
tags:
- tools
- gitops
Expand All @@ -18,10 +18,6 @@ versions:
refs:
- source: github.com/cloud-native-toolkit/terraform-gitops-namespace.git
version: ">= 1.0.0"
# - id: gitops-db2
# refs:
# - source: github.com/cloud-native-toolkit/terraform-gitops-db2u-operator.git
# version: ">= 0.0.1"
- id: gitops-cp4d-instance
refs:
- source: github.com/cloud-native-toolkit/terraform-gitops-cp4d-instance.git
Expand Down