amazon-web-services - AWS 自动缩放中的 'Health Check Grace Period' 和 'Default Cooldown' 如何工作?

标签 amazon-web-services autoscaling

我一直在玩我的自动缩放组的配置,但我不完全了解这两个是如何工作的。

正如亚马逊所说 Health Check Grace Period指:

The length of time that Auto Scaling waits before checking an instance's health status. The grace period begins when an instance comes into service.



虽然 Default Cooldown指:

The number of seconds after a scaling activity completes before another can begin. This is also called the cooldown period. Learn more about cooldown periods.



所以想象我有一个规则,当 CPU 消耗超过 50% 时扩展,并且 Health Check Grace Period = 300Default Cooldown = 100 .如果我在 0 秒启动一个实例,AWS 检查伸缩组的 CPU 消耗需要多长时间?而且,新实例启动需要多长时间?启动前的时间是 400 秒,再次检查组的 CPU 的时间是 100 秒吗?谢谢。

最佳答案

健康检查宽限期和默认冷却时间是不同的概念。 Health Check Grace Period 适用于单个实例,而 Default Cooldown 适用于 Auto Scaling 组。

如果实例在第 0 秒启动,因为 CPU 高于 50%,则此新实例将获得 300 秒的宽限期以恢复健康。如果 300 秒后健康,它将继续运行,否则将终止。

如果在第 100 秒 CPU 仍然在 50% 以上,则 Auto Scaling 组将启动一个新实例(最后一次伸缩操作发生在 100 秒前 = 冷却时间)。因此,回答你的问题是 100 秒 直到启动新实例。

另请注意,默认情况下,Amazon EC2 Auto Scaling 在手动扩展事件(= 设置所需容量)期间不遵守冷却时间,并且如果实例变得不健康,Auto Scaling 组不会等待冷却时间完成后再更换不健康的实例。

关于amazon-web-services - AWS 自动缩放中的 'Health Check Grace Period' 和 'Default Cooldown' 如何工作?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/55872117/

相关文章:

javascript - 当存储桶设置为公共(public)时,IAM 用户只能访问 S3 存储桶

amazon-web-services - API 网关和 Lambda 的地理限制

amazon-web-services - 为什么AWS CloudWatch没有自动扩展组的内存使用量指标

node.js - AWS SDK - 更改自动扩展组更新策略

amazon-web-services - AWS 云信息 : Is it possible to access user id inside a Cloudformation template?

amazon-web-services - 错误 !!! CloudFormation 模板验证

php - Apache - htdocs 和/var/www/html

azure - Autoscale实例是否复制磁盘文件?

amazon-web-services - AWS Autoscaling 和 AWS Opsworks 之间有什么区别

amazon-web-services - AWS CloudFormation 模板 "Launch configuration name not found"