I'm using CloudFormation to spin up some servers in an auto scaling group, and I want them all to use basic monitoring. I tried setting Monitoring
to false
in the AWS::AutoScaling::AutoScalingGroup
properties as well as the AWS::AutoScaling::LaunchConfiguration
, but the stack cannot start up; I see CREATE_FAILED
with the error message: Encountered unsupported property Monitoring
.
Open the Amazon EC2 console at console.aws.amazon.com/ec2/. From the navigation pane, select Auto Scaling Groups > (select your group). From the Monitoring tab, select Auto Scaling Metrics > Enable Group Metrics Collection or Display > Auto Scaling.
You can terminate these instances and let Amazon EC2 Auto Scaling replace them, or use the instance refresh feature to terminate and replace the instances. Or, you can put the instances on standby, update the software, and then put the instances back in service.
On the Automatic scaling tab, under Dynamic scaling policies, select the check box in the top right corner of the desired scaling policy. Scroll to the top of the Dynamic scaling policies section, and choose Actions, Disable.
Just another day in the lovingly roguish world of almost-but-not-quite-consistant CFN template syntax.
The property you want is InstanceMonitoring
, not Monitoring
. It should apply to your LaunchConfiguration resource. More details are in the docs.
InstanceMonitoring
Indicates whether or not instance monitoring should be enabled for this
autoscaling group. This is enabled by default. To turn it off, set
InstanceMonitoring to "false".
Required: No. Default value is "true".
Type: Boolean
Of course, if you're provisioning an AWS::EC2::Instance resource, it's just straight up Monitoring
. For what it's worth, I find this slightly less annoying than changing SecurityGroups
to SecurityGroupIds
when moving Instance declarations in and out of VPCs, but that's just me.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With