-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Add details about GPU resources for Knative services #22791
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
Merged
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,39 @@ | ||
| include::modules/serverless-document-attributes.adoc[] | ||
| [id="gpu-resources"] | ||
| = Using NVIDIA GPU resources with serverless applications | ||
| :context: gpu-resources | ||
| include::modules/common-attributes.adoc[] | ||
|
|
||
| toc::[] | ||
|
|
||
| NVIDIA supports experimental use of GPU resources on {product-title}. | ||
| See link:https://docs.nvidia.com/datacenter/kubernetes/openshift-on-gpu-install-guide/index.html[{product-title} on NVIDIA GPU accelerated clusters] for more information about setting up GPU resources on {product-title}. | ||
|
|
||
| After GPU resources are enabled for your {product-title} cluster, you can specify GPU requirements for a Knative service using the `kn` CLI. | ||
|
|
||
| .Procedure | ||
|
|
||
| You can specify a GPU resource requirement when you create a Knative service using `kn`. | ||
|
|
||
| . Create a service. | ||
| . Set the GPU resource requirement limit to `1` by using `nvidia.com/gpu=1`: | ||
| + | ||
| ---- | ||
| $ kn service create hello --image docker.io/knativesamples/hellocuda-go --limit nvidia.com/gpu=1 | ||
| ---- | ||
| + | ||
| A GPU resource requirement limit of `1` means that the service has 1 GPU resource dedicated. | ||
| Services do not share GPU resources. Any other services that require GPU resources must wait until the GPU resource is no longer in use. | ||
| + | ||
| A limit of 1 GPU also means that applications exceeding usage of 1 GPU resource are restricted. | ||
| If a service requests more than 1 GPU resource, it is deployed on a node where the GPU resource requirements can be met. | ||
|
|
||
| .Updating GPU requirements for a Knative service using `kn` | ||
|
|
||
| * Update the service. Change the GPU resource requirement limit to `3` by using `nvidia.com/gpu=3`: | ||
| ---- | ||
| $ kn service update hello --limit nvidia.com/gpu=3 | ||
| ---- | ||
|
|
||
| == Additional resources | ||
| * For more information about limits, see xref:../../applications/quotas/quotas-setting-per-project.adoc[Setting resource quotas for extended resources]. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| ../images |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| ../modules |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.