Use HAMi vGPU ResourceQuota in Alauda Container Platform
Use Alauda Container Platform to configure HAMi vGPU quotas at both the project level and the namespace level. The platform manages project quotas as a project-level ProjectQuota: the sum of namespace ResourceQuota values inside the project must stay within the project's configured limits.
HAMi extended quotas are displayed in Alauda Container Platform after the HAMi extended resource ConfigMaps are created on the GPU cluster. If HAMi NVIDIA is not displayed in the quota type list, check that Alauda Build of Hami is installed and that the extended resource ConfigMaps from the installation guide have been applied.
TOC
PrerequisitesHAMi vGPU quota fieldsConfigure project-level HAMi vGPU quotasWhen creating a projectFor an existing projectConfigure namespace-level HAMi vGPU quotasWhen creating a namespaceFor an existing namespaceView quota usage in Alauda Container PlatformEnforcement behavior for HAMi vGPU quotasTroubleshootingPrerequisites
- Alauda Build of Hami is installed on the target workload cluster.
- The HAMi extended resource ConfigMaps are created in the GPU cluster.
- You have permission to create a project or update project quotas in Alauda Container Platform.
- The target project is associated with the GPU cluster where HAMi resources are available.
HAMi vGPU quota fields
Use the following fields whenever the platform asks you to configure the HAMi NVIDIA quota type:
Configure project-level HAMi vGPU quotas
Project quota is the upper bound for all namespace quotas in that project.
When creating a project
- In Alauda Container Platform, go to
Administrator->Project Management. - Click
Create Project. - Fill in the project information, then select the GPU cluster that provides HAMi resources.
- Click
Nextto open the project quota setting step. - In the selected cluster, add an extended quota.
- Set the quota type to
HAMi NVIDIA. - Fill in
gpu number,vgpu cores, andvgpu memory. - Review the quota values, then create the project.
For an existing project
- In Alauda Container Platform, go to
Administrator->Project Management. - Open the target project detail page.
- Update the project quota for the GPU cluster associated with the project.
- Add or edit the extended quota type
HAMi NVIDIA. - Set
gpu number,vgpu cores, andvgpu memory, then save the change.
Configure namespace-level HAMi vGPU quotas
Namespace HAMi vGPU quotas are consumed from the project quota assigned to the same cluster. If the remaining project quota is insufficient, the platform rejects the namespace quota creation or update.
When creating a namespace
- Open the target project in Alauda Container Platform.
- Click
Create Namespace. - Fill in the namespace information.
- In the
Resource Quotasection, find the hardware accelerator or extended resource quota area. - Add an extended resource quota and set the quota type to
HAMi NVIDIA. - Fill in
gpu number,vgpu cores, andvgpu memory. - Save the namespace.
For an existing namespace
- Open the target project in Alauda Container Platform.
- Open the target namespace detail page.
- Edit the namespace
Resource Quota. - Add or edit the extended quota type
HAMi NVIDIA. - Set
gpu number,vgpu cores, andvgpu memory, then save the change.
View quota usage in Alauda Container Platform
After HAMi vGPU quotas are configured, you can check quota usage and allocation from multiple pages in Alauda Container Platform:
- On the project details page, the
Quotatable shows the project-level quota. For HAMi resources, the table can showUtilizationandQuota Rate;Utilizationrepresents used quota over total quota, whileQuota Raterepresents allocated quota over total quota. - On the namespace details page, the
Resource Quotastable shows namespace-level information such asAllocated,Quota, andQuota Rate. - On the namespace-scoped
Overviewpage in the business view, theResource Quotascard can show the current namespace quota and allocation rate.
Use these pages to check whether gpu number, vgpu cores, and vgpu memory are close to their limits before creating or scaling applications.
Enforcement behavior for HAMi vGPU quotas
HAMi vGPU quota enforcement is different from the standard Kubernetes ResourceQuota admission behavior.
- For standard Kubernetes resource quotas, a request that exceeds quota is usually rejected before the Pod is created.
- For HAMi extended quotas in Alauda Container Platform, quota feasibility is evaluated by
hami-schedulerduring scheduling.
In current product behavior, if an application requests HAMi resources that exceed the remaining namespace quota, the Pod object may still be created first and stay in Pending state, with an insufficient quota or scheduling failure message from the HAMi scheduler. This behavior is consistent with HAMi's scheduler-side quota calculation model.
Troubleshooting
- If
HAMi NVIDIAis not available in the quota type list, reapply the HAMi extended resource ConfigMaps on the GPU cluster. - If namespace quota creation or update fails, check whether the requested namespace quota would exceed the remaining project quota for the same HAMi resource.
- If a Pod is created but stays in
Pending, check the scheduling events fromhami-schedulerand verify that the namespace still has enoughgpu number,vgpu cores, andvgpu memoryquota. - If workloads still cannot be scheduled after the project quota is updated, check the namespace
ResourceQuota, workload resource requests, and actual GPU capacity in the target cluster.