Cluster autoscaler probably cannot drain nodes running Tapas pods
メンテナーはふだん 1 日以内に返信
まだ誰も着手していません。
評価
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 初心者へのやさしさ
- 46/100
- issue の種類
- バグ
- 明瞭さ
- おおむね明確
- 活発さ
- 活発
- 技術スタック
- go, kubernetes
調査の方向性
Start with internal/executor/kube/layout.go:22-27 and trace pod creation in internal/executor/kube/render.go:23, plus the emptyDir definitions in internal/pixienv/pixienv.go:266, internal/podfiles/podfiles.go:72, and internal/controller/jobs/build.go:245. Compare the generated pod volumes and annotations with the cluster autoscaler's FAQ, then verify the behavior on an autoscaled node with an app pod and a job pod. Done means the observed eviction behavior is documented and the annotation behavior or intended policy is resolved.
索引モデルが issue の本文から書いたものです。
説明
Tapas marks app, run and file pods with cluster-autoscaler.kubernetes.io/safe-to-evict-local-volumes: scratch,tmp (internal/executor/kube/layout.go:22-27), so the cluster autoscaler can drain a node whose only local data is scratch space. Reading the code against the autoscaler's FAQ, I don't think the annotation can have that effect for any of our pods.
App and file pods are bare pods. Render creates a corev1.Pod with no owner (internal/executor/kube/render.go:23). The FAQ ("What types of pods can prevent CA from removing a node?") lists "Pods that are not backed by a controller object" as blocking scale-down, unless the pod has cluster-autoscaler.kubernetes.io/safe-to-evict: "true". The local-volumes annotation doesn't lift that.
Job pods have unlisted emptyDirs. Job pods do have a controller, so the local-storage rule applies to them. The FAQ says the annotation only helps when "all of the pod's local volumes are listed in the annotation value", and it counts every emptyDir that isn't medium: Memory. Our pods carry several besides scratch and tmp, for example:
javo-env(internal/pixienv/pixienv.go:266);- the pod-files volumes (
internal/podfiles/podfiles.go:72); - the runner volume for jobs (
internal/controller/jobs/build.go:245).
What I haven't checked: I haven't drained a node with the autoscaler, and the FAQ doesn't spell out what happens when one local volume is missing from the list. To check, run an app and a job on a node of an autoscaled group (autoscaler defaults, which per the FAQ's parameter table include --skip-nodes-with-local-storage=true), leave the node otherwise idle, and see whether the autoscaler removes it or logs the pod as blocking.
If it holds, we need to decide what we want:
- App pods: is it safe to evict a running app? Evicting stops the person's session; the home survives. If yes, set
safe-to-evict: "true". If no, the current behaviour is right and the local-volumes annotation is dead code. - Job pods: list every emptyDir in the annotation, built from the pod's volumes instead of a fixed string.
Found while writing the pixi mirror spec (#25), which adds one more emptyDir (envs) to the list.
- 主要言語
- Go
- スター
- 5
- フォーク
- 0
- 平均マージ
- 21時間 13分
- マージ済み PR(30日)
- 53
環境構築
- Dockerfile または Docker Compose ファイルあり
- プルリクエストのテンプレートなし
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
nebari-dev/tapas のほかの issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
nebari-dev/tapas#124 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
nebari-dev/tapas#121 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 84/100
nebari-dev/tapas#32 ·
メンテナーはふだん 1 日以内に返信
-
Suggest saving a memory when a chat message holds something worth remembering対応中かも @jbouder が今日担当しました。 オープン
難易度 5/5 1週間以上 初心者へのやさしさ 25/100
nebari-dev/tapas#137 ·
メンテナーはふだん 1 日以内に返信
-
難易度 4/5 3〜5日 初心者へのやさしさ 54/100
nebari-dev/tapas#136 ·
メンテナーはふだん 1 日以内に返信
nebari-dev/tapas の issue をすべて見る
似ている issue
-
area: pipeline priority: low type: bug
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
prime-radiant-inc/evener#8335 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 74/100
-
ui: OnTextKey on SearchField never sees keys (it does not reach the inner input)対応中かも @szluyu99 が今日担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100