exam questions

Exam AWS DevOps Engineer Professional All Questions

View all questions & answers for the AWS DevOps Engineer Professional exam

Exam AWS DevOps Engineer Professional topic 1 question 66 discussion

Exam question from Amazon's AWS DevOps Engineer Professional
Question #: 66
Topic #: 1
[All AWS DevOps Engineer Professional Questions]

An application is deployed on Amazon EC2 instances running in an Auto Scaling group. During the bootstrapping process, the instances register their private IP addresses with a monitoring system. The monitoring system performs health checks frequently by sending ping requests to those IP addresses and sending alerts if an instance becomes non-responsive.
The existing deployment strategy replaces the current EC2 instances with new ones. A DevOps Engineer has noticed that the monitoring system is sending false alarms during a deployment, and is tasked with stopping these false alarms.
Which solution will meet these requirements without affecting the current deployment method?

  • A. Define an Amazon CloudWatch Events target, an AWS Lambda function, and a lifecycle hook attached to the Auto Scaling group. Configure CloudWatch Events to invoke Amazon SNS to send a message to the Systems Administrator group for remediation.
  • B. Define an AWS Lambda function and a lifecycle hook attached to the Auto Scaling group. Configure the lifecycle hook to invoke the Lambda function, which removes the entry of the private IP from the monitoring system upon instance termination.
  • C. Define an Amazon CloudWatch Events target, an AWS Lambda function, and a lifecycle hook attached to the Auto Scaling group. Configure CloudWatch Events to invoke the Lambda function, which removes the entry of the private IP from the monitoring system upon instance termination.
  • D. Define an AWS Lambda function that will run a script when instance termination occurs in an Auto Scaling group. The script will remove the entry of the private IP from the monitoring system.
Show Suggested Answer Hide Answer
Suggested Answer: C 🗳️

Comments

Chosen Answer:
This is a voting comment (?). It is better to Upvote an existing comment if you don't have anything to add.
Switch to a voting comment New
jackdryan
Highly Voted 3 years, 3 months ago
I'll go with C
upvoted 11 times
...
Bulti
Highly Voted 2 years ago
Correct answer is C. ASG needs CloudWatch Events to trigger Lambda to do the needful.
upvoted 5 times
...
d3717d5
Most Recent 1 day, 7 hours ago
Selected Answer: C
ASGlifeCycleHook->CloudWatchEvent->triggersLambda->Lambda does the work
upvoted 1 times
...
Maygam
2 years, 2 months ago
Selected Answer: C
https://docs.aws.amazon.com/autoscaling/ec2/userguide/tutorial-lifecycle-hook-lambda.html
upvoted 3 times
...
Goozian
2 years, 4 months ago
Selected Answer: C
"C" ASG Lifecycle hook needs CloudWatch event to trigger Lambda
upvoted 1 times
...
RightAnswers
2 years, 11 months ago
The question says that there are false alarms only during deployment. So, I don't understand why "removing the entry of the private IP from the monitoring system upon instance termination" will solve this problem. Obviously there is a process already in place to remove these IP address - otherwise there will be false alarms all the time, not during the deployment period only. As stated in https://docs.aws.amazon.com/autoscaling/ec2/userguide/configuring-lifecycle-hook-notifications.html, you can use Amazon SNS to set up a notification target (an SNS topic) to receive notifications when a lifecycle action occurs. I am not sure what is the use of CloudWatchEvents and Lambda, when direct SNS notification is possible. All the answers doesn't make sense - but I guess A may be closest.
upvoted 2 times
Scofield_12
2 years, 1 month ago
Option A would not stop the false alarm, you need an architecture that would take an action to stop the false alarm, not just notifying the admin
upvoted 1 times
...
...
D2
3 years, 3 months ago
B is right for removing instance from monitoring system. C is not correct
upvoted 3 times
4b18f59
4 months, 1 week ago
Even I feel B is right , why include Cloudwatch events at all. A common pattern is: Auto Scaling group has a lifecycle hook Lifecycle hook triggers an EventBridge rule EventBridge rule invokes a Lambda function Lambda function performs custom logic and calls CompleteLifecycleAction API to signal Auto Scaling
upvoted 1 times
...
...
gmandala
3 years, 3 months ago
B is right. Why CW when ASG lifecycle hooks are tailor-made for this? Also, CW events on their own cannot keep the termination in wait before removing the id.
upvoted 2 times
gmandala
3 years, 3 months ago
On relook, i see lifecycle hooks still need CW events. So it has to be C.
upvoted 4 times
...
...
dnevado
3 years, 3 months ago
Not sure, no need for CW but Lambda also needs to send notifications to a SNS topic which is not totally clear in the answer
upvoted 1 times
...
xlFireman
3 years, 3 months ago
I would go with B here
upvoted 2 times
xlFireman
3 years, 3 months ago
Change to C, You need CW Events or SNS with ASG Target Group to invoke lambda
upvoted 4 times
...
...
ChauPhan
3 years, 4 months ago
B. Lifecycle hooks can invoke Lambda directly by BridgeEvent https://docs.aws.amazon.com/autoscaling/ec2/userguide/configuring-lifecycle-hook-notifications.html
upvoted 2 times
ChauPhan
3 years, 3 months ago
Route notifications to Lambda using EventBridge You can use EventBridge to set up a target to invoke a Lambda function when a lifecycle action occurs.
upvoted 1 times
ChauPhan
3 years, 3 months ago
Sorry my mistake, we need CW Event, now they call it EventBridge
upvoted 2 times
...
...
tarq
3 years, 3 months ago
so correct answer is C
upvoted 4 times
...
...
Dgix
3 years, 4 months ago
B. CW Events not needed.
upvoted 1 times
...
Steve_Dobbs
3 years, 4 months ago
B. Even in their own reference there is no need for cloutdwatch event trigger. You just need lifecycle hook and AWS lamda function. https://aws.amazon.com/blogs/compute/using-aws-lambda-with-auto-scaling-lifecycle-hooks/
upvoted 1 times
Steve_Dobbs
3 years, 4 months ago
Changing to C. You need SNS topic to invoke lamdba from Lifecycle hooks. Without that you will need Cloudwatch Event.
upvoted 2 times
ChauPhan
3 years, 3 months ago
I see that LifeCycle hooks can invoke 1. Lambda by EventBridge 2. SNS 3. SQS. I don't see CW Event involved here
upvoted 2 times
ChauPhan
3 years, 3 months ago
Sorry my mistake, we need CW Event, now they call it EventBridge
upvoted 1 times
...
...
...
...
oku
3 years, 4 months ago
A : As Devops Engineer is tasked with stopping these false alarms only without affecting current Deployment Model .
upvoted 1 times
...
getawaycar
3 years, 4 months ago
They changed the name of Cloudwatch Events to EventBridge https://docs.aws.amazon.com/autoscaling/ec2/userguide/cloud-watch-events.html
upvoted 1 times
...
Smart
3 years, 4 months ago
C is relevant and correct. SNS Notification would have been nice as well.
upvoted 4 times
...
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...
exam
Someone Bought Contributor Access for:
SY0-701
London, 1 minute ago