- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
我有来自 prometheus 适配器的 sidekiq 自定义指标。使用普罗米修斯的队列指标我已经设置了 HPA。当 sidekiq 队列中的作业超过 1000 个作业时,HPA 会触发 10 个新 pod。然后每个 pod 将在队列中执行 100 个作业。当工作减少到 400 个时。HPA 将按比例缩小。但是当缩减发生时,hpa 杀死 pod 说 4 个 pod 被杀死。 Thoes 4 pods 仍在运行作业,说每个 pod 正在运行 30-50 个作业。现在,当 hpa 删除这 4 个 pod 时,在它们上运行的作业也会终止。并且这些工作在 sidekiq 中被标记为失败。
所以我想要实现的是阻止 hpa 删除正在执行作业的 pod。此外,我希望 hpa 即使在负载降至最低后也不会缩小,而是在 sidekiq 指标中队列中的作业为 0 时删除 pod。
有什么办法可以做到这一点?
最佳答案
老实说,奇怪的用法:即使您的流量处于冷却阶段,您也在浪费资源,但是由于您没有提供更多详细信息,所以在这里。
实际上,不可能实现您想要的,因为常见的行为是支持您的工作负载不断增长的负载。实现这一目标的唯一等待(,不推荐 )是更改 horizontal-pod-autoscaler-downscale-stabilization
Kubernetes Controller 管理器的 flag到更高的值(value)。
JFI,文档警告您:
Note: When tuning these parameter values, a cluster operator should be aware of the possible consequences. If the delay (cooldown) value is set too long, there could be complaints that the Horizontal Pod Autoscaler is not responsive to workload changes. However, if the delay value is set too short, the scale of the replicas set may keep thrashing as usual.
关于kubernetes - 防止K8S HPA在减少负载后删除pod,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/59527783/
前言 “大伙得眼里有活,看见同事忙的时候要互相帮助,这样我们团队才能快速成长,出成绩,多干点活没坏处的,领导都看在眼里记在心里,不会亏待大伙。
我目前正在尝试使用 prometheus 和 prometheus 适配器运行一个自动缩放演示,我想知道是否有一种方法可以根据 prometheus 从另一个部署中收集的指标自动缩放我的一个部署。 我
我们有一个Istio集群,我们正在尝试为Kubernetes配置水平容器自动缩放。我们希望将请求计数用作hpa的自定义指标。我们如何才能将Istio的Prometheus用于同一目的? 最佳答案 事实
我有两个彩色轨道,我在其中部署了两个不同版本的 web 应用程序 (nginx+php-fpm),这些轨道可通过称为 live 和 next 的服务使用。 经典的方式是部署Web应用程序的新版本接下来
副本和 HPA 有什么区别? 例如,以下部署配置了 3 个副本 apiVersion: apps/v1 kind: Deployment metadata: name: hello spec:
有没有办法在 Azure Kubernetes 服务上启用基于“每秒请求”的扩展? AKS 中的 HPA 确实允许基于 CPU 和内存限制进行水平 Pod 扩展,但没有直接的方法来实现这一点 - 每秒
HPA-如何避免因CPU使用率激增而扩大规模(不在启动时) 在为其他国家/地区加载业务配置时,CPU负载会增加1分钟,但我们要避免在1分钟内扩大规模。 在下面的图片中,CurrentMetricVal
我正在运行带有HPA的Kubernetes集群v1.16(当前是GKE的最新版本),该集群可基于自定义指标(具体来说是从Google云监控中获取的Rabbitmq消息计数)来扩展部署。 问题 当消息数
我在HPA上发现istio网关有问题。 为什么10m等于10%? 10m 1%不是吗? Kubernetes版本是1.18.5。 # kubectl get hpa --all-namespaces
我们的Web服务API上似乎遇到了一些内部服务器错误(500),似乎是在作为自动缩放器配置的一部分引入或删除了新容器时。 自然,这种事情很难解决,因为您并不总是能够控制 pods 的启动和停止的时间。
从 Kubernetes v1.18 开始,v2beta2 API 允许通过 Horizontal Pod Autoscalar (HPA) 行为字段配置缩放行为。 我计划将具有自定义指标的 HP
我想要实现的是创建一个能够扩展的 Horizontal Pod Autoscaler worker根据 controller 生成的自定义指标生成 Pod荚。 我已经让 Prometheus 抓取
问题设置。 假设我有 2 个 pod,A 和 B。我希望能够根据来自某个任意来源的某个任意数字动态缩放 pod A。假设 pod B 是这样一个源:例如,它可以有一个 HTTP 服务器,它的端点在请求
我正在尝试配置 kubernetes 水平 pod 自动缩放。我部署的定义是 here . 我开始 heapster 部署和 heapster 服务,如下所示: # kubectl run heaps
我终于部署了与其中一个部署相关的 hpa,但 hpa 没有按预期工作。我可以看到利用率远远超过实际情况,甚至不匹配所有 pod 的利用率总和。不确定这个平均利用率是如何计算的,当有 2 个 pod 的
是否有一个“主开关”来启用/禁用 Keda 和 HPA?我可以通过将副本计数编辑为 0 来启用/禁用扩展规则,但是是否有主要的启用/禁用字段? cooldownPeriod: 1800 max
我有一个在 Kubernetes 集群上运行的 openjdk:8 镜像。我添加了内存 HPA(Horizontal Pod Autoscaling),它可以很好地扩展,但由于 JVM 不会将内存
我正在尝试基于GPU利用率在GCP中实现水平荚自动缩放(HPA)。 我的hpa.yaml文件如下所示: kind: HorizontalPodAutoscaler metadata: name:
我已经为我在 Kubernetes 中的部署之一配置了 hpa。 有什么方法可以检查部署中是否发生 HPA 缩放以及何时发生? 我没有部署普罗米修斯或任何监控解决方案。 最佳答案 如果您创建了 HPA
所以这发生在 EKS K8s v1.15 上。您可以在 describe 输出中看到 api 版本。 millicpu 在 80 到 120 之间徘徊……这与 HPA 输出的副本数完全不匹配…… 这是
我是一名优秀的程序员,十分优秀!