Uninstall from OpenShift with GreyMatter
This page removes a Kamiwaza installation from the kamiwaza namespace. It does
not change the platform around it: the namespace, GreyMatter and Kamiwaza's
configuration in your tenant configuration repository, storage classes, DNS, and
certificates belong to the platform administrator and stay in place.
This is destructive. Uninstalling deletes Kamiwaza's databases, stored objects, and model files along with the platform. Back up anything you need before you begin.
Step 1: Back up
Export or copy any data you need to keep, such as documents in workrooms, configuration, and anything in the platform databases. Step 3 deletes the platform databases and object store, and they cannot be recovered after it.
Step 2: Remove apps and models
Remove what you deployed through Kamiwaza while the platform is still running:
- Log in as
admin. - In the App Garden, stop every deployed app. In the Tool Shed, stop every tool server.
- On the Models page, stop every model deployment, including the embedding model Kamiwaza deploys on its own, and remove any model provider connections you added.
- Confirm that all three lists are empty.
Step 3: Uninstall the release
Run as the installer identity. This deletes the volume claims for the platform databases and the object store; step 4 describes what happens to the disks behind them:
helm uninstall kamiwaza --namespace kamiwaza --wait --timeout 15m
Step 4: Delete the remaining volumes
Two kinds of volume outlive the release: the model registry cache, which the chart keeps on purpose, and the configuration store's volumes, which Kubernetes keeps for any StatefulSet. GreyMatter shares this namespace, so delete Kamiwaza's claims by name rather than every claim in it:
kubectl -n kamiwaza get persistentvolumeclaims
kubectl -n kamiwaza delete persistentvolumeclaims --ignore-not-found \
kamiwaza-registry-data core-etcd-data-core-etcd-0 core-etcd-data-core-etcd-1 core-etcd-data-core-etcd-2
Whether the underlying disks are also deleted depends on the StorageClass's
reclaimPolicy. With Retain, the platform administrator deletes the released
PersistentVolumes.
Step 5: Verify
Run as the platform administrator, since the installer identity may not be able to list every kind:
kubectl api-resources --verbs=list --namespaced -o name \
| grep -v -E '^events(\.events\.k8s\.io)?$' \
| xargs -n 1 kubectl -n kamiwaza get --ignore-not-found -o name 2>/dev/null \
| grep -v -E '^(packagemanifest|podmetrics)\.'
The last line drops kinds that OpenShift lists in every namespace: operator catalog entries and pod metrics.
Expect only the platform prerequisites, what OpenShift creates in every project, and what GreyMatter runs for the namespace:
- the installer's ServiceAccount, Roles, and RoleBindings;
- the
kamiwaza-licenseSecret, and your pull Secret if you use one; - the
greymatter-tenant-repo,greymatter-edge-ingress, andgreymatter-image-pullSecrets; - the
kamiwaza-edge-trustConfigMap; - the
kube-root-ca.crtandopenshift-service-ca.crtConfigMaps, and the service accounts, Secrets, and RoleBindings OpenShift adds to every project; - GreyMatter's tenant controllers, the edge and its Route, and their GreyMatter
resources. GreyMatter keeps these while Kamiwaza's configuration is in the
tenant configuration repository. They include the
edgeresourcesandsidecarresourcesobjects, thegreymatter-sidecar-injection-certsSecret, thegreymatter-sidecar-injection-serviceService, thegreymatter-cni-greymatterNetworkAttachmentDefinition, and the controllers' leases.
If anything else remains, contact Kamiwaza support with the list before reinstalling into the same namespace.
Removing the platform prerequisites
If Kamiwaza will not be installed again, the platform administrator can remove what was prepared for it, following their own procedures for GreyMatter, storage, DNS, and certificates. Work in this order:
-
Remove Kamiwaza's configuration from the tenant configuration repository (
_tenants/kamiwaza), and let GreyMatter Sync apply the change. GreyMatter then removes the edge and its Route. -
Remove the namespace from
tenant_namespaces(andftr_namespaces, if you added it) in your GreyMatter Core configuration. -
Delete the
kamiwazanamespace, which removes the installer identity, the Secrets, and everything else in it:oc delete project kamiwaza -
Remove the DNS records for the Kamiwaza domain. If nothing else relies on the inotify limits, remove them the way you set them: delete the
99-worker-kamiwaza-inotifyMachineConfig, which restarts the pool's nodes, or, where you couldn't use aMachineConfig, undo the setting the way you applied it.
To install again after deleting the namespace, start from Platform Prerequisites.