Questions tagged with AWS Auto Scaling

Content language: English

Sort by most recent

Browse through the questions and answers listed below or filter and sort to narrow down your results.

Hello team, I'm Hariharan B P, I have an account in AWS for the usage of the Elastic Beanstalk and EC2 for my personal usage. I got a notification on 31st January 2023 stating my AWS account is compromised to which I followed the procedure as mentioned in mail. And today when I'm trying to access the Elastic Beanstalk or create an EC2 instance for my application I get this error stating:- "Creating Auto Scaling group named: awseb-e-apcnvj3ndu-stack-AWSEBAutoScalingGroup-1DKVP9LOCC7OE failed. Reason: This account is currently blocked and not recognized as a valid account. Please contact aws-verification@amazon.com if you have questions. Launching EC2 instance failed." I have mailed the same to the above mentioned mail id as well. So, I request Amazon team to help me out as I need to know why my account is still blocked though I'm able to login to it. I have also attached an error screenshot for your reference. Thank you Warm Regards, HARIHARAN B P ![Screenshot of the image](/media/postImages/original/IMmYyh2IKgRIW_V2TMdGKJsA)
1
answers
0
votes
54
views
asked 2 months ago
Application : Android Backend : AWS Amplify Issue : AWS Amplify Scaling and GraphQL Pagination In Splash Screen, i am getting the userID using Amplify.Auth?.currentUser?.userId and using that userID, I am fetching User information saved in User table using amplify-framework [GraphQLRequest(ModelQuery.list)](https://docs.amplify.aws/lib/graphqlapi/query-data/q/platform/android/) So, the issue is for the users around the selected AWS region for the amplify, the Splash page loading is fine. However, for the users who are far, the experience on Splash and others sections of the App is not good while loading the data (which i think is currently it due to the pagination thing in the GraphQL API) So my questions are : 1. What can i do better to reduce the API calls using GraphQL API in context of AWS amplify 2. How can i deploy the AWS amplify application/backend in multiple AWS regions.
0
answers
0
votes
16
views
asked 2 months ago
I have an Launch Template which has the security group attached to it. I can launch an instance that works fine from this template. From the template I created an Auto Scaling gorup. When I look at the AS group I do not see the Security Group at all. I just see a dash. When I try to run the AS group it fails to create the instance. When I look at the failed instances they too do not have a security group. What am I doing wrong??? How do I add the group to the AS Group or get it to pull in the one from the Launch Template.
4
answers
0
votes
38
views
asked 2 months ago
Hi, I currently run a Serverless application using Vercel, and I'm looking for a way to run a scheduled script in AWS. The script will simply total up some database rows and re-insert them into a database table (Using Node.JS). What's the best way for me to host this on AWS and have it run every ~15 minutes. I'm aware a solution like EC2 would work just running a permanent server that's not serverless, although is there a better way which powers down when not running?
1
answers
0
votes
24
views
asked 2 months ago
Hi, I have an environment on Elastic Beanstalk with Application Load Balancer listen to HTTPS and HTTP as well, we also have a auto scaling group with 6 to 10max instances. The application is facing an issue that we're struggling to find, a segfault (we're on it) once it happens in an instance it get terminated and start a new ok. However during the instance replacement, the state of the enviroment becomes "Severe" and the application get off, stops responding. We're looking for a solution for high availability, if we have 4 instances running and one requires to be terminated for some reason, shouldn't the balancer keep the enviroment live and available? What should we look for to have it in place?
0
answers
0
votes
29
views
asked 2 months ago
please recommend me any strategies for optimizing Auto Scaling on my instances
1
answers
0
votes
26
views
asked 2 months ago
I have an autoscaling policy on my RDS Aurora cluster which has been working well for a while. I recently added cloudtrail alerts when a role attempts to do something that is unauthorized, and every time there is a scaling action the AWSServiceRoleForApplicationAutoScaling_RDSCluster throws an error: ``` { "eventVersion": "1.08", "userIdentity": { "type": "AssumedRole", "principalId": "XXXXX:AutoScaling-UpdateDesiredCapacity", "arn": "arn:aws:sts::XXXXX:assumed-role/AWSServiceRoleForApplicationAutoScaling_RDSCluster/AutoScaling-UpdateDesiredCapacity", "accountId": "XXXXX", "sessionContext": { "sessionIssuer": { "type": "Role", "principalId": "XXXXX", "arn": "arn:aws:iam::XXXXX:role/aws-service-role/rds.application-autoscaling.amazonaws.com/AWSServiceRoleForApplicationAutoScaling_RDSCluster", "accountId": "XXXXX", "userName": "AWSServiceRoleForApplicationAutoScaling_RDSCluster" }, "webIdFederationData": {}, "attributes": { "creationDate": "2023-01-09T16:54:55Z", "mfaAuthenticated": "false" } }, "invokedBy": "rds.application-autoscaling.amazonaws.com" }, "eventTime": "2023-01-09T16:54:56Z", "eventSource": "ec2.amazonaws.com", "eventName": "DescribeSubnets", "awsRegion": "us-east-1", "sourceIPAddress": "rds.application-autoscaling.amazonaws.com", "userAgent": "rds.application-autoscaling.amazonaws.com", "errorCode": "Client.UnauthorizedOperation", "errorMessage": "You are not authorized to perform this operation.", "requestParameters": { "subnetSet": {}, "filterSet": { "items": [ { "name": "subnet-id", "valueSet": { "items": [ { "value": "XXXXX" }, { "value": "XXXXX" } ] } } ] } }, "responseElements": null, "requestID": "XXXXX", "eventID": "XXXXX", "readOnly": true, "eventType": "AwsApiCall", "managementEvent": true, "recipientAccountId": "XXXXX", "eventCategory": "Management" } ``` I don't see any way that I can modify the permissions of this service role, but I also don't like my cloudwatch alerts being filled with these notifications. Any way I can give this role the proper permissions?
1
answers
0
votes
41
views
jonb
asked 2 months ago
Hello, Have we any features in aws EC2 instance like docker containers which are newly created when one container is crashed or in fault? Auto-scaling is somewhat part of this but as per my knowledge it only launched when the primary instance is not matching our already given health check parameters like CPU exceeds over 80% while configuring auto-scaling. Please share your knowledge. Thanks.
1
answers
0
votes
37
views
asked 3 months ago
Hello, Let's suppose we have Auto Scaling groups that has 2 desired capacity and configured to launch them as spot instances with price-capacity-optimized strategy We configured the ASG to launch two different instance types: **t3.medium, t3.large** At first run, the running spot instacnes are as the following depending on the allocation strategy: **2 with t3.medium** Now let's suppose that, the other instance type t3.large got better allocation strategy (price-capacity-optimized), **Will the ASG switch the running spot instances from t3.medium to be t3.large?** Could you please advise? Thanks
1
answers
0
votes
43
views
Maan
asked 3 months ago
Hi , I was testing Distributed load test . I am also having an autoscaling group with an ALB, which was set to scale out in case of CPU utilization of 60 %. After the test, the CPU utilization reached 10% and the web page of my EC2 instance started giving 5XX errors, so the ALB saw the machine as unhealthy. Accordingly the autoscaling group deleted this machine and created a new one. This should not have happened. As when we try to access the ec2 web page directly without the ALB during the 10% CPU utilization it is working fine. but from the ALB DNS name it is giving us the 5XX errors Can someone please help explain why this is happening and what should be edited in the distributed load test ?
1
answers
0
votes
31
views
asked 3 months ago
Hi guys, I've found that is possible to use math in a target tracking scaling policy for Amazon EC2 Auto Scaling (https://docs.aws.amazon.com/autoscaling/ec2/userguide/ec2-auto-scaling-target-tracking-metric-math.html) I've tried to use same config in application auto-scaling for service-namespace ECS without success This is my config ``` { "CustomizedMetricSpecification": { "Metrics": [ { "Label": "ack_total", "Id": "m1", "MetricStat": { "Metric": { "MetricName": "rabbitmq_queue_messages_ack_total[switch_events]", "Namespace": "Prometheus" }, "Stat": "Average" }, "ReturnData": false }, { "Label": "published_total", "Id": "m2", "MetricStat": { "Metric": { "MetricName": "rabbitmq_queue_messages_published_total[switch_events]", "Namespace": "Prometheus" }, "Stat": "Average" }, "ReturnData": false }, { "Label": "Relation (ack_total + 1) / (published_total + 1)", "Id": "e1", "Expression": "(m1 + 1)/(m2 + 1)", "ReturnData": true } ] }, "TargetValue": 1.0 } ``` This is the command I've used: ``` aws application-autoscaling put-scaling-policy --service-namespace ecs --policy-name rabbitmq-pub-ack-scaling-policy --scalable-dimension ecs:service:DesiredCount --resource-id "service/XXXXX/events" --policy-type TargetTrackingScaling --target-tracking-scaling-policy-configuration file://alarm-definition.json ``` I'm getting this error: ``` Parameter validation failed: Missing required parameter in TargetTrackingScalingPolicyConfiguration.CustomizedMetricSpecification: "MetricName" Missing required parameter in TargetTrackingScalingPolicyConfiguration.CustomizedMetricSpecification: "Namespace" Missing required parameter in TargetTrackingScalingPolicyConfiguration.CustomizedMetricSpecification: "Statistic" Unknown parameter in TargetTrackingScalingPolicyConfiguration.CustomizedMetricSpecification: "Metrics", must be one of: MetricName, Namespace, Dimensions, Statistic, Unit ``` based on doc available in https://docs.aws.amazon.com/autoscaling/application/APIReference/API_CustomizedMetricSpecification.html seems impossible to use a custom metric with math Best regards.
3
answers
0
votes
149
views
asked 3 months ago
Hello, I have a next.js/mysql application running on docker on my laptop. It uses docker-compose. I would like to deploy it to aws and take advantage of Load Balancer and Auto Scaling Groups. Do you suggest to use ECS to deploy the whole container (can I use LB and ASG) or should I better use cloudformation and only deploy the application code? In the latter case how should I setup my dev environment? I would like to have the DEV and the TEST/PRD environments consistent. thanks
2
answers
0
votes
59
views
asked 3 months ago