AWS
Connect AWS with one CloudShell command, request GPU quota, and verify training and recovery.
Connect AWS to train on 1, 2, 4 or 8 NVIDIA GPUs of one instance in your own EC2 account. Setup takes GPU quota, one command in AWS CloudShell, and one paste into Tensorant. Tensorant then starts an on-demand instance for each run and releases it after collecting the adapter.
Your own GPU accounts come with the Own compute subscription. An AWS account connected before Own compute existed keeps working without it until 31 Dec 2026: see Your own accounts. AWS bills the GPU time in your account, and each training run's training-token fee comes from your Tensorant credits.
AWS compute and project storage are separate connections. Set up custom S3 storage before creating your first project, or keep your existing RunPod network storage. Managed inference, publishing and managed experiment evaluation still require RunPod and a RunPod network volume.
1. Request GPU quota
Use a commercial AWS region such as us-east-1. AWS China and GovCloud are not supported.
In Service Quotas → AWS services → Amazon Elastic Compute Cloud, select your region and check the on-demand quota for the instance family you intend to use. G instances and P instances have separate quotas. Request enough vCPUs for the instance, including other running instances in that quota group; a quota of one does not mean one GPU. An instance of several GPUs has more vCPUs, so it needs more quota. New accounts can have zero GPU-family quota. AWS EC2 instance quotas
Tensorant lists x86_64 instance types with 1, 2, 4 or 8 Ampere-or-newer NVIDIA GPUs of one kind, such as A10G (g5), L4 (g6), L40S (g6e) or H100. Training GPU shows the types with the run's Number of GPUs, each GPU's memory and the instance's price. T4 types (g4dn), ARM machines and Spot requests are not offered. A regional listing does not reserve capacity or increase your quota.
2. Run the setup command
In Tensorant, open your name at the foot of the sidebar, then Settings → Connections under Organization, and choose Connect AWS. Enter the Region for training. The dialog shows the command for that region, with a link to AWS CloudShell.
Open AWS CloudShell in the AWS console, signed in to the account you will train in, and run the command. For us-east-1 it reads:
REGION=us-east-1
cat > tensorant-policy.json <<EOF
{
"Version": "2012-10-17",
"Statement": [
{
"Sid": "DiscoverAndPrice",
"Effect": "Allow",
"Resource": "*",
"Action": [
"ec2:DescribeImages",
"ec2:DescribeVpcs",
"ec2:DescribeSubnets",
"ec2:DescribeSecurityGroups",
"ec2:DescribeInstanceTypeOfferings",
"ec2:DescribeInstanceTypes",
"ec2:DescribeInstances",
"pricing:GetProducts"
]
},
{
"Sid": "FindAmazonsGpuImage",
"Effect": "Allow",
"Action": "ssm:GetParameter",
"Resource": "arn:aws:ssm:$REGION::parameter/aws/service/deeplearning/ami/x86_64/*"
},
{
"Sid": "MakeTheTrainingSecurityGroup",
"Effect": "Allow",
"Action": "ec2:CreateSecurityGroup",
"Resource": "*",
"Condition": {
"StringEquals": {
"aws:RequestedRegion": "$REGION"
}
}
},
{
"Sid": "LaunchInputs",
"Effect": "Allow",
"Action": "ec2:RunInstances",
"Resource": [
"arn:aws:ec2:$REGION::image/*",
"arn:aws:ec2:$REGION:*:subnet/*",
"arn:aws:ec2:$REGION:*:security-group/*",
"arn:aws:ec2:$REGION:*:network-interface/*",
"arn:aws:ec2:$REGION:*:key-pair/*"
]
},
{
"Sid": "CreateTaggedComputeAndDisks",
"Effect": "Allow",
"Action": "ec2:RunInstances",
"Resource": [
"arn:aws:ec2:$REGION:*:instance/*",
"arn:aws:ec2:$REGION:*:volume/*"
],
"Condition": {
"StringEquals": {
"aws:RequestTag/tensorant:managed": "true"
}
}
},
{
"Sid": "TagsAtCreationOnly",
"Effect": "Allow",
"Action": "ec2:CreateTags",
"Resource": "*",
"Condition": {
"StringEquals": {
"ec2:CreateAction": [
"RunInstances",
"CreateSecurityGroup"
]
}
}
},
{
"Sid": "ManageTaggedTrainingInstances",
"Effect": "Allow",
"Action": [
"ec2:StartInstances",
"ec2:StopInstances",
"ec2:TerminateInstances"
],
"Resource": "arn:aws:ec2:$REGION:*:instance/*",
"Condition": {
"StringEquals": {
"ec2:ResourceTag/tensorant:managed": "true"
}
}
}
]
}
EOF
aws iam create-user --user-name tensorant-training --output text > /dev/null
aws iam put-user-policy --user-name tensorant-training --policy-name tensorant-training \
--policy-document file://tensorant-policy.json &&
aws iam create-access-key --user-name tensorant-training --output json |
jq --arg region "$REGION" '{provider: "aws", access_key_id: .AccessKey.AccessKeyId, secret_access_key: .AccessKey.SecretAccessKey, region: $region}'It creates the IAM user tensorant-training, without console access, with this policy and a new access key. It prints one JSON object with the key and your region. Run it as someone who can create IAM users and their keys, such as an administrator. Never use root-account keys.
With this policy, Tensorant can:
- find Amazon's GPU image, and read instance types, prices and your network;
- create its security group and start instances in your region, only tagged
tensorant:managed; - start, stop and terminate only instances with that tag.
It cannot touch your other instances. Discovery and pricing can't be limited to single resources. The Pricing API is called in us-east-1 even when your GPUs run elsewhere, so an account policy that blocks that region stops the GPU list from loading.
Running the command again updates the same user's policy and creates a new key; create-user reports that the user already exists. AWS allows two keys per user: if create-access-key refuses, remove an unused key in IAM → Users → tensorant-training → Security credentials, then run the command again. Keep the key Tensorant currently uses until its replacement has been saved and checked, so active or retained instances remain manageable.
3. Connect in Tensorant
Back in the Connect AWS dialog, paste everything the command printed into Paste what it printed, and choose Connect AWS. Tensorant checks the key, finds Amazon's GPU image and your default VPC, and loads the GPU types with current prices. It does not launch an instance or check your quota.
To update the connection later, choose Update connection in the provider's ... menu and paste new output. Your Advanced settings stay filled in.
What Tensorant sets up
Unless you choose otherwise under Advanced, each training instance gets:
| Part | Default |
|---|---|
| Image | Amazon's Deep Learning Base OSS NVIDIA Driver GPU AMI (Ubuntu 24.04), the current release in your region, looked up through its public SSM parameter |
| Network | The region's default VPC, in a default subnet of an availability zone that offers the instance type |
| Address | A public IP for downloads |
| Firewall | The security group tensorant-training, created on the first launch, which allows no inbound traffic |
| Login | No key pair unless you name one |
| Disk | An encrypted gp3 root disk, at least the image's size plus the run's working space, deleted with the instance |
A region without a default VPC can't use these defaults. Create one in the VPC console under Your VPCs → Actions → Create default VPC, or use your own subnet.
The instance receives your storage connection's keys to move training data and results. Give the storage connection keys limited to its bucket.
4. Verify a short training run
- Connect storage, create a project and prepare a small dataset version.
- Open Configure a run, choose Training provider → AWS, then choose an eligible Training GPU and its Number of GPUs.
- Choose Training trial · a small sample. Set an affordable Price limit ($/hour) and allow 10 to 20 minutes for the first image and model downloads.
- Save the draft, review the launch confirmation, and launch. This starts a paid EC2 instance.
- Confirm the run progresses through preparation, training and adapter verification. Check both GPU released in Tensorant and terminated in EC2, with the job's root EBS volume removed.
The displayed hourly estimate includes the on-demand Linux instance and gp3 capacity, using the monthly storage rate divided by 730. It excludes public IP, transfer, taxes and account-specific discounts. The launch limit is not an AWS billing cap. See training runs for trial settings and cost controls.
Recovery, cleanup and disconnection
If export fails or the run times out, Tensorant stops the EC2 instance and keeps its root disk for recovery. Compute charges stop when EC2 confirms stopped; the EBS volume still bills. EC2 lifecycle and billing
Open Recover your adapter on the run. To retrieve the completed archive yourself, you need a way into the instance:
- Start the retained instance in EC2. Starting resumes instance billing; it does not resume training.
- The security group
tensorant-trainingallows no inbound traffic. Add an inbound rule for SSH (port 22) from your own IP address. For the browser-based EC2 Instance Connect, allow your region's EC2 Instance Connect address range instead. - Connect as the user
ubuntu, with EC2 → Instances → Connect → EC2 Instance Connect, or with the key pair you named under Advanced. If your image doesn't support EC2 Instance Connect, name a key pair before the run. - With custom S3, download
/var/lib/tensorant/data/adapter.zip; with RunPod network storage,/var/lib/tensorant/data/runs/RUN_ID/adapter.zip. The host's data directory is/workspace/datainside the container. - Remove the inbound rule, and stop the instance while you finish.
Select the downloaded archive and choose Verify and recover. An incomplete checkpoint is not a completed adapter archive. See failure and recovery.
Once you have recovered the output, or decided to discard it, use the run's recovery or cancellation controls to release it. Termination deletes the job's root disk and network interface. It does not delete the tensorant-training security group, your default VPC, or any AMI, subnet or key pair of yours.
Keep the connection and its permissions valid until Tensorant confirms cleanup. If release is pending, inspect the instance in EC2 and use Retry the GPU release. Do not remove tags or replace credentials with an identity from another account while a run is retained. To rotate the key, run the setup command again, update the connection, then delete the old key in IAM.
Advanced: your own network, image or access
Under Advanced: your own network, image or access in the connection dialog, you can replace any default. Leave a field empty to keep Tensorant's default.
Your own subnet and security group
Enter a Subnet ID (subnet-…) and a Security group ID (sg-…) in the same VPC, both or neither. Instances then get no public IP, so the subnet needs its own outbound internet route, typically a NAT gateway, with DNS and outbound HTTPS to container registries, model downloads and your storage endpoint. Choose an availability zone that offers your instance type. Training needs no inbound port; for recovery, allow port 22 only from your VPN or bastion. NAT and transfer charges are outside the estimate. AWS NAT gateways
Your own image
Enter a GPU AMI ID (ami-…) in your region: an available x86_64 Linux/UNIX AMI with an EBS root disk and no Marketplace product code. It needs:
- cloud-init and Python 3, with cloud-init enabled for new instances;
- Docker Engine and NVIDIA Container Toolkit, configured for Docker;
- a working NVIDIA driver 580 or newer, compatible with CUDA 13 and the chosen GPU.
Test a new image on the intended GPU before using it:
nvidia-smi --query-gpu=name,driver_version --format=csv,noheader
sudo docker run --rm --gpus all ubuntu:24.04 nvidia-smiTensorant suppresses secondary disks inherited from the AMI, so keep required software on the root disk. Creating an EBS-backed AMI
Recovery login
- SSH key name: an existing EC2 key pair in the region, by its exact name. Keep the private key.
- Instance profile ARN: an instance profile for Systems Manager recovery, whose role your SSM setup needs. Enter the instance profile ARN, not the role ARN. The image needs a running SSM Agent. Add this statement to the
tensorant-traininguser's policy, replacingACCOUNT_IDandROLE_NAME:
{
"Effect": "Allow",
"Action": "iam:PassRole",
"Resource": "arn:aws:iam::ACCOUNT_ID:role/ROLE_NAME",
"Condition": {"StringEquals": {"iam:PassedToService": "ec2.amazonaws.com"}}
}Keep the profile's permissions limited, because code on the instance can use them. SSM instance-profile setup
Other credentials
If you create the IAM identity yourself, use the policy in the setup command as a starting point, then paste a JSON object in the same shape the command prints:
{"provider": "aws", "access_key_id": "ACCESS_KEY_ID", "secret_access_key": "SECRET_ACCESS_KEY", "region": "us-east-1"}A Session token under Advanced supports temporary STS credentials. Tensorant does not renew them: they must stay valid until every run and retained instance is cleaned up, or Tensorant can no longer stop or terminate them. A long-lived key from the setup command avoids this.
If your account's default EBS encryption key is customer-managed, also grant access to that KMS key. EBS encryption permissions
Troubleshooting
| Symptom | Check |
|---|---|
The setup command fails with AccessDenied |
Run it as someone who can create IAM users, policies and access keys. |
create-access-key reports LimitExceeded |
The user already has two keys. Delete an unused one in IAM, then run the command again. Keep Tensorant's current key valid until the replacement is saved. |
| "This AWS region has no default VPC" | Create one under Your VPCs → Actions → Create default VPC, or enter your own subnet and security group under Advanced. |
Connection fails with AccessDenied |
Run the current setup command again to refresh the policy; account policies must permit the pricing call in us-east-1. |
| GPU catalog is empty | The region offers a supported type with the chosen number of GPUs, and AWS returns public Linux pricing. |
Launch reports VcpuLimitExceeded |
Increase the relevant G or P on-demand quota in that region. |
Launch reports InsufficientInstanceCapacity |
AWS has no capacity for that type now. Try later, or choose another GPU. |
| Startup fails during host validation | With your own image, verify its GPU driver is at least 580. |
| Image or model download fails | With the default VPC, check its route to the internet gateway is intact. With your own subnet, check its NAT and firewall route. |
| Cannot reach the retained instance | Start it, add an inbound SSH rule from your IP, and connect as ubuntu. |
| GPU release fails | Restore the key and its permissions, check EC2 state, then use Retry the GPU release. A stopped instance still keeps billable storage. |
Need a hand? Visit troubleshooting