Questions tagged with Amazon EC2 Auto Scaling
Content language: English
Sort by most recent
Hello,
We've started working with ECS to run a containerized service we have. The jobs are fairly sparse so the ECS tasks aren't constantly running. We have capacity providers (CP) and autoscaling groups (ASG) to do the scaling of EC2 instances, which is working well from our initial testing. Something we have not been able to resolve is how to configure the scale-in time. After an EC2 instance no longer has running ECS tasks on it how long until the ASG removes that instance? We would like the instances to hang around for a configurable amount of time before being removed from the ECS cluster. Is that time before scale in configurable?
Thanks
When setting up a managed compute environment, AWS Batch allows to set [tags on compute resources](https://docs.aws.amazon.com/batch/latest/APIReference/API_ComputeResource.html#Batch-Type-ComputeResource-tags) it creates. Per my experiments these tags get only applied to EC2 instances launched in the compute environment, but not to the ECS cluster nor the EC2 auto scaling group created for the environment.
Is this a bug in AWS Batch? If not, what's the recommended way to propagate tags to Batch-initiated ECS clusters and auto scaling groups?
We're new to AWS and launched an EC2 instance, in addition to some other services. Public website isn't active. Main concern is Elemental Media Package at the moment used 500GB for one of the packages this month and we are not sure why so much data is being processed. Last month, there was over 2TB of data processed.
Is there a way to add a launch template that defines EC2 instances with multiple ENIs that have different configurations (for each ENI) to an Auto Scaling Group? or is it a limitation in ASGs?
I have a redhat instance on which i have attached a Network interface at index 1.That network interface is having a static ip . when i am trying to connect the ec2 with the static ip of netwrok interface it is giving connection timeout error.
I'm setting up an Autoscaling group and it's using TargetTrackingScaling that is tracking a custom metric that is being updated every minute (via a scheduled lambda that queries the inservice instances).
It's working fine, but I'd like the scale-out action to happen more quickly. The source of this looks to be due to the ASG Alarm that gets auto created. It's looking for 3 datapoints before triggering, this means it takes 3 minutes for the alarm to fire.
Is there a way I can configure the ASG/Scaling policy such that the alarm only needs 1 datapoint to fire? Or if not can I create a custom alarm and use that instead?
The metric is `{Unit: 'Percent', Statistic: 'Average'}`
What is the main differences between an load balancer and a autoscaling group
From what I can tell, ASG with target tracking does not define a cooldown period.
As a result, if instances are slow to initialize, the ASG could scale out again, before the new instances join the work.
Is there a way to make it wait longer before scaling out again?
Each release creates a new autoscaling group and therefore new instances. If a release goes well, a replacement instances is created, code is deployed there and traffic is shifted over.
If a release fails, however, the instances created still remain, and so if we have multiple failures, we can have a very large number of heavy instances running without reason. Is there a way we can easily clean up these instances, or prevent it altogether perhaps? Am I doing something wrong?
Hello, everyone, i need your help some body, for repair or knows why i get that error or 1/2 status comprobation.
My ionstance dont had that problems, its so new in my case, i have one instance with centos 7 sistem running.
I need somebody for help me to resolve this incovenient.
thanks so much
AWS released the latest Windows Server 2012 R2 AMIs on 7/13/2022. Upon testing this morning, I found that ami-0c7328b3dbb11f540 is corrupt and will not properly run powershell commands upon launch due to missing files in the filesystem. Reverting to the June image (ami-09e13647920b2ba1d) allowed our autoscaling EC2 instances to launch properly.
For specifics, below is the error that triggered an autoscaling build failure.
```
2022-07-15 13:43:32,501 [ERROR] -----------------------BUILD FAILED!------------------------
2022-07-15 13:43:32,501 [ERROR] Unhandled exception during build: [Errno 2] No such file or directory: 'C:\\Users\\ADMINI~1\\AppData\\Local\\Temp\\tmp2_4a69w_/subp-stderr-8e0905c1-1293-4379-bbb8-bf88a2978290.txt'
Traceback (most recent call last):
File "cfn-init", line 176, in <module>
File "cfnbootstrap\construction.pyc", line 137, in build
File "cfnbootstrap\construction.pyc", line 564, in build
File "cfnbootstrap\construction.pyc", line 578, in run_config
File "cfnbootstrap\construction.pyc", line 146, in run_commands
File "cfnbootstrap\command_tool.pyc", line 92, in apply
File "cfnbootstrap\util.pyc", line 587, in call
File "cfnbootstrap\util.pyc", line 562, in call
FileNotFoundError: [Errno 2] No such file or directory: 'C:\\Users\\ADMINI~1\\AppData\\Local\\Temp\\tmp2_4a69w_/subp-stderr-8e0905c1-1293-4379-bbb8-bf88a2978290.txt'
```
I was able to access the ec2 instance on Public IP, however I am unable to access the instance now, I have 2 instances running with the similar configurations, I am able to access one of them however the other one is not responding on the Public IP, please suggest what to do.