Deploy HAMi Enterprise on OpenShift
Use this guide to install HAMi Enterprise on a connected OpenShift cluster with NVIDIA GPUs.
Prerequisites
- Sign in to the target cluster with
oc. Install Helm for the CLI installation path, and installkubectlandjqto collect the License request. - Use an account that can create an OpenShift project and the cluster-scoped RBAC and SecurityContextConstraints (SCC) resources required by the chosen Chart.
- Install cert-manager in the cluster. The values below enable the HAMi admission webhook with cert-manager certificates.
- For a new GPU Operator installation, first set up the Red Hat Node Feature Discovery (NFD) Operator and its operand. Reuse NFD if it's already running.
Prepare NVIDIA GPU Operator
If GPU Operator is already installed, reuse it and check its ClusterPolicy. For a new installation, choose one of the following methods. Both prepare the envvar path with GPU Operator CDI disabled. HAMi Enterprise supplies the NVIDIA device plugin.
Install with the OpenShift Console
-
From Ecosystem → Software Catalog, search for NVIDIA GPU Operator and select the certified Operator from
certified-operators. -
Click Install. Select the
nvidia-gpu-operatornamespace and a channel supported for your OpenShift version. For OpenShift 4.22, select channelv26.7and version 26.7.2 for this example. Choose Manual approval to pin a version older than the latest in the channel. Otherwise choose the approval strategy allowed by your cluster and its update policy. Click Install. -
If you selected Manual, open the subscription's pending InstallPlan in the Operator namespace, review the version and resources, and click Approve. Wait for the Operator to reach Succeeded in Ecosystem → Installed Operators.
-
Open Installed Operators → NVIDIA GPU Operator → ClusterPolicy, then select Create ClusterPolicy → YAML view. In the generated YAML, set the following fields under
specand keep the rest of the generated policy. Click Create.spec:devicePlugin:enabled: falsecdi:enabled: falsedriver:enabled: truetoolkit:enabled: true
To see the saved YAML, open the created ClusterPolicy and select its YAML tab, or run oc get clusterpolicy gpu-cluster-policy -o yaml. See the NVIDIA OpenShift installation guide.
Install with the NVIDIA Helm Chart
NVIDIA documents the OLM installation for OpenShift. Use this alternative where your cluster permits a Helm-managed GPU Operator. The example uses Chart v26.7.2 for OpenShift 4.22 with NFD already running. For other cluster versions or GPU configurations, check the NVIDIA platform and driver support matrix.
helm repo add nvidia https://helm.ngc.nvidia.com/nvidia
helm repo update nvidia
helm install gpu-operator nvidia/gpu-operator \
--version v26.7.2 \
--namespace nvidia-gpu-operator --create-namespace \
--set platform.openshift=true \
--set nfd.enabled=false \
--set devicePlugin.enabled=false \
--set cdi.enabled=false \
--wait
The Chart keeps the driver and Container Toolkit enabled and creates a ClusterPolicy named cluster-policy.
Check the ClusterPolicy
List the policies and use the actual policy name and Operator namespace in the commands. The Console example uses gpu-cluster-policy, and the Helm example uses cluster-policy.
oc get clusterpolicy
export GPU_CLUSTER_POLICY='gpu-cluster-policy'
oc get clusterpolicy "$GPU_CLUSTER_POLICY" \
-o jsonpath='state={.status.state}{"\n"}devicePlugin.enabled={.spec.devicePlugin.enabled}{"\n"}cdi.enabled={.spec.cdi.enabled}{"\n"}'
oc get pods -n nvidia-gpu-operator -o wide
oc get runtimeclass nvidia -o jsonpath='{.handler}{"\n"}'
oc get nodes -l nvidia.com/gpu.present=true
Continue when the policy reports state=ready and devicePlugin.enabled=false, the driver and Container Toolkit are ready on every GPU node, and the nvidia RuntimeClass reports handler nvidia. Use the actual cdi.enabled value to choose the HAMi configuration. With false, use the values below. With true, keep CDI or disable it on the existing policy before installing HAMi.
Prepare the OpenShift project
Install HAMi Enterprise in a dedicated project such as hami-system. Never install it in default or another system project such as kube-system. OpenShift skips SCC admission in default. Without the non-root UID that SCC admission normally assigns, vgpu-scheduler-extender can fail to start with a runAsNonRoot error. See Red Hat's SCC documentation.
oc new-project hami-system
oc version
Configure HAMi Enterprise
Save values-openshift.yaml and use it for either installation method. Replace "4.22" with the major and minor numbers from the OpenShift Server Version, and keep scheduler.kubeScheduler.image.tag on the matching v tag.
platform:
openshift: true
openshiftVersion: "4.22"
selinux:
enabled: true
openshift:
securityContextConstraints:
create: true
name: hami-device-plugin
scheduler:
admissionWebhook:
enabled: true
certManager:
enabled: true
kubeScheduler:
image:
tag: "v4.22"
service:
type: ClusterIP
devicePlugin:
runtimeClassName: nvidia
nvidiaNodeSelector:
gpu: null
nvidia.com/gpu.present: "true"
prometheus:
enabled: true
These values enable the admission webhook with cert-manager, create the hami-device-plugin SCC, and keep devicePlugin.deviceListStrategy=envvar with scheduler.useDownward=true. The nvidia RuntimeClass lets Container Toolkit expose driver libraries to the device-plugin container, so devicePlugin.nvidiaDriverRoot can stay unset. Review the device plugin SCC and SELinux changes against your cluster policy before installing.
Use the NVIDIA GPU node label
Confirm that nvidia.com/gpu.present=true identifies every GPU node that HAMi should manage. The gpu: null entry removes the Chart's default gpu=on selector. If you label the target nodes with gpu=on yourself, omit the entire nvidiaNodeSelector block to use the Chart default.
Enable Prometheus monitoring
prometheus.enabled=true creates ServiceMonitors for the scheduler and NVIDIA device plugin when the cluster provides the monitoring.coreos.com/v1/ServiceMonitor API. The Chart does not install that CRD. If the API is absent, Helm succeeds without creating ServiceMonitors.
OpenShift disables monitoring for user-defined projects by default. To scrape ServiceMonitors in hami-system with OpenShift monitoring, set enableUserWorkload: true in the cluster-monitoring-config ConfigMap in openshift-monitoring. See Configuring user workload monitoring. If you use a separate Prometheus installation, configure it to discover ServiceMonitors in hami-system.
Install HAMi Enterprise
Choose one installation method. Both use values-openshift.yaml and the release name hami. The examples below use Chart version 2.10.0-r5. See the HAMi Enterprise changelog for version updates and upgrade notes.
Install the certified Chart in the Console
- In Ecosystem → Software Catalog, select the
hami-systemproject and filter for Helm Charts. Select the certified HAMi Enterprise Chart published by Dynamia. - Click Create to open the release form.
- Enter
hamias the release name, select Chart version2.10.0-r5, and paste the contents ofvalues-openshift.yamlin YAML View. - Before submitting, confirm that the project is
hami-system. Never submit from All Projects or install intodefault. Click Create.
If the Console redirects to /topology/ns/ and returns 404, the release may already exist in default. Check the release and its project under Ecosystem → Helm before retrying.
Install the Dynamia OCI Chart with Helm
helm upgrade --install hami oci://ghcr.io/dynamia-ai/charts/hami-enterprise \
--version 2.10.0-r5 --namespace hami-system \
-f values-openshift.yaml --wait
Verify the deployment
Use the resource names for the Chart you installed. These names assume a release named hami and the values above.
| Chart | Scheduler Deployment | Device plugin DaemonSet | Device plugin SCC |
|---|---|---|---|
OpenShift certified hami 2.10.0-r5 | hami-scheduler | hami-device-plugin | hami-device-plugin |
Dynamia OCI hami-enterprise 2.10.0-r5 | hami-hami-enterprise-scheduler | hami-hami-enterprise-device-plugin | hami-device-plugin |
For the certified Chart, run the following commands. For the OCI Chart, substitute the resource names from the table.
oc rollout status deployment/hami-scheduler -n hami-system
oc rollout status daemonset/hami-device-plugin -n hami-system
oc get pods -n hami-system \
-o 'custom-columns=NAME:.metadata.name,SCC:.metadata.annotations.openshift\.io/scc'
oc get servicemonitor -n hami-system
Confirm that the device plugin uses hami-device-plugin and that the scheduler uses the SCC assigned by OpenShift, typically restricted-v2. With prometheus.enabled=true, confirm that ServiceMonitors exist for both the scheduler and the NVIDIA device plugin. Check that the GPU node reports HAMi's nvidia.com/gpu capacity and that the shared directories have the configured SELinux type container_file_t and level s0.
export GPU_NODE='REPLACE_WITH_GPU_NODE_NAME'
oc describe node "$GPU_NODE"
oc debug node/"$GPU_NODE" -- chroot /host \
ls -Zd /usr/local/vgpu /usr/local/vgpu/containers /tmp/vgpulock
Obtain a license
After the HAMi Enterprise Pods start, confirm that kubectl points to the same cluster as oc. Run the License collection script from your delivery package, or download and run it with these commands.
kubectl config current-context
jq --version
curl -fsSLO https://public.hami.run/collect-hami-license-info.sh
bash collect-hami-license-info.sh
Send the complete JSON output to Dynamia through the support channel for your commercial agreement. You can also contact info@dynamia.ai or call 400-026-7800.
Activate the license
Save the License file on the administration host. Create and label the Secret in the project where HAMi Enterprise is installed.
kubectl create secret generic hami-license \
--from-file=license=/path/to/license-file -n hami-system
kubectl label secret hami-license hami.io/license="true" -n hami-system
kubectl get secret hami-license -n hami-system
kubectl get events --field-selector involvedObject.name=hami-license -n hami-system
kubectl get nodes \
-o 'custom-columns=NODE:.metadata.name,LICENSE:.metadata.annotations.hami\.io/nvidia-license'
Confirm the LicenseValid event and the License registration annotation on the NVIDIA nodes.
With the values above, the admission webhook is enabled. GPU workloads do not need a manual schedulerName unless you changed scheduler.schedulerName. For the envvar configuration, set runtimeClassName: nvidia under the GPU Pod's spec when the workload container needs the NVIDIA runtime.
Optional configuration
Disable CDI in GPU Operator
Use these steps only to switch an existing policy from CDI to envvar. Check the impact on GPU workloads before changing the policy. If the NRI plugin is enabled, first disable it using the NVIDIA CDI and NRI instructions. On CRI-O, pause the validator on GPU nodes before the patch, then restore it even if the patch fails.
oc label nodes -l nvidia.com/gpu.present=true \
nvidia.com/gpu.deploy.operator-validator=false --overwrite
oc patch clusterpolicy "$GPU_CLUSTER_POLICY" --type=json \
-p='[{"op":"replace","path":"/spec/cdi/enabled","value":false}]'
oc label nodes -l nvidia.com/gpu.present=true \
nvidia.com/gpu.deploy.operator-validator=true --overwrite
For a Helm-managed Operator, also record cdi.enabled=false in the release values used for future upgrades. Check the ClusterPolicy again and wait for state=ready and cdi.enabled=false.
Use CDI only when required
If the cluster must keep GPU Operator CDI enabled, keep the nvidia RuntimeClass and leave the GPU Operator NRI plugin disabled for this configuration. In values-openshift.yaml, set scheduler.useDownward=false and devicePlugin.deviceListStrategy=cdi-annotations. Keep the rest of the shared values, including the node selector.
Set devicePlugin.nvidiaDriverRoot or devicePlugin.nvidiaHookPath if the device plugin needs a path specific to your nodes. For GPU Operator-managed drivers, the host driver root is commonly /run/nvidia/driver. For host-installed drivers, it is commonly /. Use /usr/local/nvidia/toolkit/nvidia-ctk only if that is the Toolkit executable path on the host. Follow the HAMi CDI verification procedure with the Enterprise values above.
Configure OpenShift security
Review the device plugin SCC against your cluster policy. With values-openshift.yaml above, the release creates the dedicated hami-device-plugin SCC. That SCC allows privileged containers, host PID, hostPath volumes, and SYS_ADMIN, and leaves host IPC, host networking, and host ports disabled.
- To use an existing approved SCC, set
openshift.securityContextConstraints.create=falseand setopenshift.securityContextConstraints.nameto its name. Confirm that the correspondingsystem:openshift:scc:<name>ClusterRole exists. - To manage the grant outside Helm, set
create=falseandname=""underopenshift.securityContextConstraints. Grant the SCC only to the device-plugin ServiceAccount. Keep the scheduler, admission, and application ServiceAccounts outside that grant.
SELinux relabeling changes the labels and permissions of the three host directories listed in Verify the deployment. Helm uninstall leaves those changes in place. Record the original state before installation if you need to restore it under your node maintenance procedure.
Troubleshooting
| Symptom | Checks and resolution |
|---|---|
The scheduler fails with runAsNonRoot | Check the release namespace and Pod SCC. If the release landed in default, use a dedicated project such as hami-system and check the existing release before reinstalling. |
| SCC admission rejects the device plugin | Check the configured SCC and how its grant binds the device-plugin ServiceAccount. For a Helm-managed grant, inspect the rendered RoleBinding. |
OpenShift resources or selinux-relabel are missing | Confirm platform.openshift=true and selinux.enabled=true. The Chart creates a dedicated SCC only when openshift.securityContextConstraints.create=true and a name is set. |
Device plugin Pods stay Pending | Check the node labels and taints against devicePlugin.nvidiaNodeSelector and devicePlugin.tolerations. |
A device plugin or workload reports an NVIDIA hook or libcuda.so.1 error | Check the driver, Container Toolkit, and selected RuntimeClass. See NVIDIA containers fail with GPU Operator 25.10+. |
| A workload cannot access the HAMi shared directories | Check the selinux-relabel logs and the host directory labels. |