使用 AWS CLI 更新实例监控
Updating Instance monitoring using AWS CLI
我正在尝试使用 AWS CLI 更新实例监控以进行自动缩放并使用文档 on AWS here
我正在尝试以下命令,但没有找到成功或进一步的文档。
>> aws autoscaling update-auto-scaling-group --auto-scaling-group-name awseb-e-test-stack-AWSEBAutoScalingGroup-5ECR3Tc0de --instance-monitoring Enabled=true
usage: aws [options] <command> <subcommand> [<subcommand> ...] [parameters]
To see help text, you can run:
aws help
aws <command> help
aws <command> <subcommand> help
Unknown options: --instance-monitoring, Enabled=true
我也尝试过 aws autoscaling update-auto-scaling-group --auto-scaling-group-name awseb-e-test-stack-AWSEBAutoScalingGroup-5ECR3Tc0de --instance-monitoring help
,但这并没有提供对选项 --instance-monitoring
的任何见解
在现有启动配置上启用对实例的详细监控的最佳方法是什么?
遗憾的是,您无法在现有启动配置上启用对实例的详细监控。它仅在 create-launch-configuration
中受支持
来自Monitoring Your Auto Scaling Groups and Instances Using Amazon CloudWatch:
If you have an Auto Scaling group and need to change which type of
monitoring is enabled for your Auto Scaling instances, you must create
a new launch configuration and update the Auto Scaling group to use
this launch configuration.
使用新的启动配置更新 AS 组后:
From now on, the instances that the Auto Scaling group launches will
use the updated monitoring type. However, if you have existing
instances in the Auto Scaling group, they maintain the previous
monitoring type. You can terminate these instances so that Auto
Scaling replaces them, or update each instance individually.
我正在尝试使用 AWS CLI 更新实例监控以进行自动缩放并使用文档 on AWS here 我正在尝试以下命令,但没有找到成功或进一步的文档。
>> aws autoscaling update-auto-scaling-group --auto-scaling-group-name awseb-e-test-stack-AWSEBAutoScalingGroup-5ECR3Tc0de --instance-monitoring Enabled=true
usage: aws [options] <command> <subcommand> [<subcommand> ...] [parameters]
To see help text, you can run:
aws help
aws <command> help
aws <command> <subcommand> help
Unknown options: --instance-monitoring, Enabled=true
我也尝试过 aws autoscaling update-auto-scaling-group --auto-scaling-group-name awseb-e-test-stack-AWSEBAutoScalingGroup-5ECR3Tc0de --instance-monitoring help
,但这并没有提供对选项 --instance-monitoring
在现有启动配置上启用对实例的详细监控的最佳方法是什么?
遗憾的是,您无法在现有启动配置上启用对实例的详细监控。它仅在 create-launch-configuration
中受支持来自Monitoring Your Auto Scaling Groups and Instances Using Amazon CloudWatch:
If you have an Auto Scaling group and need to change which type of monitoring is enabled for your Auto Scaling instances, you must create a new launch configuration and update the Auto Scaling group to use this launch configuration.
使用新的启动配置更新 AS 组后:
From now on, the instances that the Auto Scaling group launches will use the updated monitoring type. However, if you have existing instances in the Auto Scaling group, they maintain the previous monitoring type. You can terminate these instances so that Auto Scaling replaces them, or update each instance individually.