Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

AWS Batch job start too long with Min vCPUs=0 in Compute environment

I`m using AWS Batch. After job submitting I wait 10-15 minutes until my job gets RUNNING status. My Compute environment configuration is next:

Provisioning model: EC2
Instance types: m4.xlarge

Min vCPUs: 0
Desired vCPUs: 0
Max vCPUs: 4

ECR image size ~130 MB.

I understand that problem in Min vCPUs = 0. It takes some time to start ECS instance. But why so long?? To speed up my jobs running I run dummy job which works long time for maintaining ECS instance in running state. After that, my jobs run quickly.

like image 636
Valeriy K. Avatar asked Feb 27 '19 09:02

Valeriy K.


1 Answers

I think this is a little late but the following threads might help other people:

Here you can find an explanation regarding the time to begin execution of jobs and why batch doesn't schedule jobs as quickly as expected:
https://forums.aws.amazon.com/thread.jspa?messageID=897734


Here you can find a thread with the issues encountered by a user and some solutions that were proposed:
https://www.reddit.com/r/aws/comments/amg7yk/is_there_an_opensource_alternative_to_aws_batch/


Here you can find a proposed way to configure the vCPU values:
https://forums.aws.amazon.com/thread.jspa?threadID=265573

like image 164
Dan Nemes Avatar answered Sep 28 '22 09:09

Dan Nemes