我有一个eks集群,该集群的节点组基于具有以下配置的混合实例分发启动模板:
region: us-west-2
instance_distribution: [p2.xlarge,p3.2xlarge,p2.8xlarge]
max_price: 0.9
on_demand_percentage_above_base_capacity: 0
on_demand_base_capacity: 0
spot_instance_pools: 2
当试图将自动缩放比例从0缩放到1时,群集自动缩放器会遇到以下问题:
launching a new EC2 instance. Status Reason: Could not launch Spot Instances. SpotMaxPriceTooLow - Your Spot request price of 0.9 is lower than the minimum required Spot request fulfillment price of 0.918. launching EC2 instance failed.
At the time,the spot price of p3.2xlarge happened to be 0.918.
似乎请求了p3.2xlarge的现货,而不是请求了p2.xlarge的按需实例(即使p2.xlarge的按需价格0.9低于现货) p3.2xlarge的价格为0.918)。我希望分配一个按需的p2.xlarge实例,而不是请求一个p3.2xlarge竞价型实例。是因为我配置了on_demand_percentage_above_base_capacity: 0
吗?
更一般而言,我希望能够配置集群以获取p2.xlarge的竞价型实例,并在不可能的情况下请求按需。实现我所需功能的最佳配置是什么?
是否严格执行on_demand_percentage_above_base_capacity的配置?如果on_demand_percentage_above_base_capacity设置为1并且我的第一个实例是按需实例,那么我接下来的几个缩放请求将被强制仅生成现货实例,还是更像是具有指导权重的权重(例如,如果没有可用的现货,它将仍然退回到按需而不是未能满足请求)?