Skip to content

Commit d67c311

Browse files
committed
Risks and Mitigations - Existing use cases of Swap: update NoSwap behavior
Signed-off-by: Itamar Holder <[email protected]>
1 parent dfb0ff1 commit d67c311

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

keps/sig-node/2400-node-swap/README.md

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -449,11 +449,13 @@ As beta2 was being worked on, we discovered use cases where `--fail-swap-on=fals
449449
Kind e2e tests run kubelet with `--fail-swap-on=false` and
450450
the default developer configuration for `hack/local-up-cluster` allows for running developer clusters with swap enabled.
451451

452-
We need to support the `--fail-swap-on=false` for both cgroup v1 and cgroupv2. We will not support KEP-2400 with cgroup v1.
453-
So when one wants to GA this feature, we need to have a way to disable workloads from using swap while keeping the feature toggle on.
454-
To address this, we will propose a new field to `MemorySwap` called `NoSwap`. This will disable swap usage on the node while keeping the feature active.
452+
Now, `--fail-swap-on=false` is supported for both cgroup v1 and cgroupv2 although KEP-2400 does not support cgroup v1.
453+
This is achieved by the newly introduced `MemorySwap` called `NoSwap`, which serves as the default swap behavior, that
454+
will disable swap usage on the node while keeping the feature active.
455+
In addition, nodes that support cgroups v1 only would be able to only use `NoSwap`, i.e. in such environments containers
456+
will be restricted from having access to swap.
455457

456-
This can address existing use cases where `--fail-swap-on=false` in cgroupv1 and still allow us to turn this feature on.
458+
This addresses existing use cases where `--fail-swap-on=false` in cgroupv1 and still allow us to turn this feature on.
457459

458460
#### Exhausting swap resource
459461

0 commit comments

Comments
 (0)