- Newest
- Most votes
- Most comments
An internet gateway is not sufficient, a NAT gateway is needed because the containers only get private ip addresses. Underneath, AWS Batch is using task networking, which you can read about here: https://docs.aws.amazon.com/AmazonECS/latest/developerguide/task-networking.html
The best way to setup the networking is to follow the guide: https://docs.aws.amazon.com/eks/latest/userguide/create-public-private-vpc.html
Then take the public and private subnets that were created and specify them in your config:
[vpc public-private]
master_subnet_id = subnet-<public>
compute_subnet_id = subnet-<private>
FYI, single node jobs (jobs not submitted with the
-N
flag) don't need a NAT gateway and should run on your existing setup.
Edited by: aws-hpc-sean on Feb 20, 2019 3:33 PM
Great information, thanks. I'll work through it and report back.
I swear that the initial "vpc public" setup wouldn't even run a simple one-node job, but maybe something else was wrong. Will definitely check it out.
Using the create-public-private-vpc tutorial got me up and running. Our previous VPC had been cobbled together over time -- it seemed to have all the right pieces but there were some differences in how the routing tables attached to the VPC. I could ssh to the master and compute EC2s but awsb tools couldn't see them.
Thanks for your help,
Kim
Relevant content
- asked 5 years ago
- asked 2 years ago
- AWS OFFICIALUpdated 2 years ago
- AWS OFFICIALUpdated 2 years ago
- AWS OFFICIALUpdated 2 years ago