Containers
Announcing AWS Neuron Helm Chart
Introduction
We are pleased to announce the launch of the Neuron Helm Chart, which streamlines the deployment of AWS Neuron components on Amazon Elastic Kubernetes Service (Amazon EKS). With this new Helm Chart, you can now seamlessly install the necessary Kubernetes artifacts needed to run training and inference workloads on AWS Trainium and AWS Inferentia instances.
Until now, users needed to download and apply each component of Neuron Kubernetes plugins separately. The Neuron Helm Chart streamlines the deployment of Neuron components by consolidating the necessary components into a single, directly deployable solution. This means you can deploy the individual components such as Neuron Device Plugin, Neuron Scheduler, and Node Problem Detector with minimal effort and full flexibility. You can also customize which components to deploy using Helm chart configuration values, thus streamlining installation and management.
Key benefits of using the Neuron Helm Chart
- Standardization: Enforces a consistent method for packaging AWS Neuron Kubernetes artifacts. The chart can be downloaded from the Amazon Elastic Container Registry (Amazon) public registry.
- Reusability: Can be reused across different environments with configuration overrides by passing the
values.yaml
file. - Versioning: Can be versioned to track changes and make sure of consistent deployments.
- Templating: Provides flexibility in configuring applications based on specific needs.
- Modularity: Includes Neuron Device Plugin, Node problem detector, and Neuron Scheduler Extension components. Each artifact can be installed individually by enabling/disabling flags at the installation time.
Key components of the Neuron Helm Chart
- Neuron Device Plugin: Neuron Device Plugin exposes Neuron cores and devices to Kubernetes as a resource. It’s designed to run as a daemonset in
kube-system
namespace to make sure of its availability across the worker nodes in the cluster. This component is crucial for enabling access to Neuron hardware on your Kubernetes clusters. - Neuron Scheduler Extension: The Neuron Scheduler Extension is needed for scheduling pods that need more than one and less than the total number of Neuron cores or devices. It intelligently manages the scheduling of pods based on the hardware topology of the underlying instance to make sure of optimal performance. The scheduler identifies sets of devices that are directly connected to minimize communication latency, which is important for achieving high-performance results in distributed workloads.
- Neuron Node Problem Detector Plugin: Neuron Node Problem Detector Pluginis designed to run as a daemonset on AWS Neuron-enabled (Trn1/Inf1/Inf2) EKS worker nodes. The Neuron Node Problem Detector Plugin is responsible for monitoring the health of Neuron devices on each Kubernetes node. If it is detecting an unrecoverable neuron error, then it initiates a node replacement process.
For more detailed information about the individual Neuron components, refer to this documentation.
How to install the Neuron Helm Chart
The Neuron Helm Chart is hosted in an Amazon ECR public repository. Follow these steps to install the chart in your AWS environment. By default, the Neuron Helm Chart deploys the Neuron Device Plugin and the Neuron Node Problem Detector Plugin. Both plugins are designed to run as daemonsets on an EKS cluster.
Prerequisites for installing Neuron Helm Chart
Step1: Create an EKS cluster
Make sure that you have a functioning EKS cluster where Neuron components will be deployed. You can use eksctl for deploying the EKS cluster.
Step2: Set up IAM roles for service accounts for Neuron Node Problem Detector Plugin
To enable Neuron Node Problem Detection and Recovery, you must authorize the plugin through IAM roles for service accounts (IRSA). Follow the steps in this guide to create the necessary IAM policy and configure IRSA.
Step3: Deploy Helm Chart
Make sure that Helm is installed locally on your machine before proceeding. You can install the Neuron Helm Chart using the following command:
Output:
Verify that the Neuron Device Plugin and the Neuron Node Problem Detector plugins are running.
To Install the Neuron Artifacts:
By default, the Neuron Helm chart installs the Neuron Device Plugin and the Neuron Node Problem Detector Plugin. To install the Neuron Scheduler Extension, you must enable the following specified values and deploy the Helm chart.
Note that Neuron creates a scheduler extension called my-scheduler
, thus workloads needing this scheduler must reference this name.
Check the status of the components installed:
Refer to the Helm chart values.yaml file for reference.
Conclusion
The Neuron Helm Chart streamlines the deployment of AWS Neuron components on Amazon EKS, offering a simplified, flexible solution for running training and inference workloads on Trainium and Inferentia instances. By consolidating key components such as the Neuron Device Plugin, Neuron Scheduler Extension, and Neuron Node Problem Detector into a manageable Helm chart, you can now achieve a more efficient setup and operation of Neuron-enabled environments.
If you are planning to deploy an LLM for training and inference on Trainium and Inferentia, make sure to refer to these deployment patterns from the Data on EKS project for further guidance.
We encourage you to get started with the Neuron Helm Chart today and use its capabilities to optimize your machine learning (ML) workloads on Amazon EKS. For detailed guidance, visit the official AWS Neuron Kubernetes Getting Started documentation.