AWS Elastic Kubernetes Service (EKS)#

RAPIDS can be deployed on AWS via the Elastic Kubernetes Service (EKS).

To run RAPIDS you’ll need a Kubernetes cluster with GPUs available.


First you’ll need to have the aws CLI tool and eksctl CLI tool installed along with kubectl, helm, etc for managing Kubernetes.

Ensure you are logged into the aws CLI.

$ aws configure

Create the Kubernetes cluster#

Now we can launch a GPU enabled EKS cluster. First launch an EKS cluster with eksctl.

$ eksctl create cluster rapids \
                      --version 1.24 \
                      --nodes 3 \
                      --node-type=p3.8xlarge \
                      --timeout=40m \
                      --ssh-access \
                      --ssh-public-key <public key ID> \  # Be sure to set your public key ID here
                      --region us-east-1 \
                      --zones=us-east-1c,us-east-1b,us-east-1d \
                      --auto-kubeconfig \

With this command, you’ve launched an EKS cluster called rapids. You’ve specified that it should use nodes of type p3.8xlarge. We also specified that we don’t want to install the NVIDIA drivers as we will do that with the NVIDIA operator.

To access the cluster we need to pull down the credentials.

$ aws eks --region us-east-1 update-kubeconfig --name rapids

Install drivers#

Next, install the NVIDIA drivers onto each node.

$ helm install --repo --wait --generate-name -n gpu-operator --create-namespace gpu-operator
NAME: gpu-operator-1670843572
NAMESPACE: gpu-operator
STATUS: deployed

Verify that the NVIDIA drivers are successfully installed.

$ kubectl get po -A --watch | grep nvidia
kube-system   nvidia-driver-installer-6zwcn                                 1/1     Running   0         8m47s
kube-system   nvidia-driver-installer-8zmmn                                 1/1     Running   0         8m47s
kube-system   nvidia-driver-installer-mjkb8                                 1/1     Running   0         8m47s
kube-system   nvidia-gpu-device-plugin-5ffkm                                1/1     Running   0         13m
kube-system   nvidia-gpu-device-plugin-d599s                                1/1     Running   0         13m
kube-system   nvidia-gpu-device-plugin-jrgjh                                1/1     Running   0         13m

After your drivers are installed, you are ready to test your cluster.

Let’s create a sample pod that uses some GPU compute to make sure that everything is working as expected.

$ cat << EOF | kubectl create -f -
apiVersion: v1
kind: Pod
  name: cuda-vectoradd
  restartPolicy: OnFailure
  - name: cuda-vectoradd
    image: "nvidia/samples:vectoradd-cuda11.6.0-ubuntu18.04"
       limits: 1
$ kubectl logs pod/cuda-vectoradd
[Vector addition of 50000 elements]
Copy input data from the host memory to the CUDA device
CUDA kernel launch with 196 blocks of 256 threads
Copy output data from the CUDA device to the host memory

If you see Test PASSED in the output, you can be confident that your Kubernetes cluster has GPU compute set up correctly.

Next, clean up that pod.

$ kubectl delete pod cuda-vectoradd
pod "cuda-vectoradd" deleted

Install RAPIDS#

Now that you have a GPU enabled Kubernetes cluster on EKS you can install RAPIDS with any of the supported methods.

Clean up#

You can also delete the EKS cluster to stop billing with the following command.

$ eksctl delete cluster --region=us-east-1 --name=rapids
Deleting cluster rapids...⠼