From d001a74f8a0d177e47a6dee23df672e82698eebd Mon Sep 17 00:00:00 2001 From: Harry Zhang Date: Thu, 24 Aug 2017 21:26:07 +0800 Subject: [PATCH] Use right taint key in doc --- .../workloads/controllers/daemonset.md | 2 +- .../configuration/taint-and-toleration.md | 30 +++++++++---------- .../workloads/controllers/daemonset.md | 8 ++--- 3 files changed, 20 insertions(+), 20 deletions(-) diff --git a/cn/docs/concepts/workloads/controllers/daemonset.md b/cn/docs/concepts/workloads/controllers/daemonset.md index bad610955876b..200d7efed1074 100644 --- a/cn/docs/concepts/workloads/controllers/daemonset.md +++ b/cn/docs/concepts/workloads/controllers/daemonset.md @@ -95,7 +95,7 @@ DaemonSet 也需要一个 [`.spec`](https://git.k8s.io/community/contributors/de -Daemon Pod 关心 [Taint 和 Toleration](/docs/concepts/configuration/assign-pod-node/#taints-and-tolerations-beta-feature),它们会为没有指定 `tolerationSeconds` 的 `node.alpha.kubernetes.io/notReady` 和 `node.alpha.kubernetes.io/unreachable` 的 Taint,创建具有 `NoExecute` 的 Toleration。这确保了当 alpha 特性的 `TaintBasedEvictions` 被启用时,发生节点故障,比如网络分区,这时它们将不会被清除掉(当 `TaintBasedEvictions` 特性没有启用,在这些场景下也不会被清除,但会因为 NodeController 的硬编码行为而被清除,而不会因为 Toleration 导致被清除)。 +Daemon Pod 关心 [Taint 和 Toleration](/docs/concepts/configuration/assign-pod-node/#taints-and-tolerations-beta-feature),它们会为没有指定 `tolerationSeconds` 的 `node.kubernetes.io/not-ready` 和 `node.alpha.kubernetes.io/unreachable` 的 Taint,创建具有 `NoExecute` 的 Toleration。这确保了当 alpha 特性的 `TaintBasedEvictions` 被启用时,发生节点故障,比如网络分区,这时它们将不会被清除掉(当 `TaintBasedEvictions` 特性没有启用,在这些场景下也不会被清除,但会因为 NodeController 的硬编码行为而被清除,而不会因为 Toleration 导致被清除)。 diff --git a/docs/concepts/configuration/taint-and-toleration.md b/docs/concepts/configuration/taint-and-toleration.md index f16f69b88fca9..5ca4cfc26f189 100644 --- a/docs/concepts/configuration/taint-and-toleration.md +++ b/docs/concepts/configuration/taint-and-toleration.md @@ -191,14 +191,14 @@ support for representing node problems. In other words, the node controller automatically taints a node when certain condition is true. The builtin taints currently include: - * `node.alpha.kubernetes.io/notReady`: Node is not ready. This corresponds to + * `node.kubernetes.io/not-ready`: Node is not ready. This corresponds to the NodeCondition `Ready` being "`False`". * `node.alpha.kubernetes.io/unreachable`: Node is unreachable from the node controller. This corresponds to the NodeCondition `Ready` being "`Unknown`". - * `node.kubernetes.io/outOfDisk`: Node becomes out of disk. - * `node.kubernetes.io/memoryPressure`: Node has memory pressure. - * `node.kubernetes.io/diskPressure`: Node has disk pressure. - * `node.kubernetes.io/networkUnavailable`: Node's network is unavailable. + * `node.kubernetes.io/out-of-disk`: Node becomes out of disk. + * `node.kubernetes.io/memory-pressure`: Node has memory pressure. + * `node.kubernetes.io/disk-pressure`: Node has disk pressure. + * `node.kubernetes.io/network-unavailable`: Node's network is unavailable. * `node.cloudprovider.kubernetes.io/uninitialized`: When kubelet is started with "external" cloud provider, it sets this taint on a node to mark it as unusable. When a controller from the cloud-controller-manager initializes @@ -223,20 +223,20 @@ The toleration the pod would use in that case would look like ```yaml tolerations: -- key: "node.alpha.kubernetes.io/unreachable" +- key: "node.kubernetes.io/unreachable" operator: "Exists" effect: "NoExecute" tolerationSeconds: 6000 ``` Note that Kubernetes automatically adds a toleration for -`node.alpha.kubernetes.io/notReady` with `tolerationSeconds=300` +`node.kubernetes.io/not-ready` with `tolerationSeconds=300` unless the pod configuration provided -by the user already has a toleration for `node.alpha.kubernetes.io/notReady`. +by the user already has a toleration for `node.kubernetes.io/not-ready`. Likewise it adds a toleration for -`node.alpha.kubernetes.io/unreachable` with `tolerationSeconds=300` +`node.kubernetes.io/unreachable` with `tolerationSeconds=300` unless the pod configuration provided -by the user already has a toleration for `node.alpha.kubernetes.io/unreachable`. +by the user already has a toleration for `node.kubernetes.io/unreachable`. These automatically-added tolerations ensure that the default pod behavior of remaining bound for 5 minutes after one of these @@ -247,11 +247,11 @@ admission controller](https://git.k8s.io/kubernetes/plugin/pkg/admission/default [DaemonSet](/docs/concepts/workloads/controllers/daemonset/) pods are created with `NoExecute` tolerations for the following taints with no `tolerationSeconds`: - * `node.alpha.kubernetes.io/unreachable` - * `node.alpha.kubernetes.io/notReady` - * `node.kubernetes.io/memoryPressure` - * `node.kubernetes.io/diskPressure` - * `node.kubernetes.io/outOfDisk` (*only for critical pods*) + * `node.kubernetes.io/unreachable` + * `node.kubernetes.io/not-ready` + * `node.kubernetes.io/memory-pressure` + * `node.kubernetes.io/disk-pressure` + * `node.kubernetes.io/out-of-disk` (*only for critical pods*) This ensures that DaemonSet pods are never evicted due to these problems, which matches the behavior when this feature is disabled. diff --git a/docs/concepts/workloads/controllers/daemonset.md b/docs/concepts/workloads/controllers/daemonset.md index f1d6dd871b7c8..92ff86a283c9d 100644 --- a/docs/concepts/workloads/controllers/daemonset.md +++ b/docs/concepts/workloads/controllers/daemonset.md @@ -101,14 +101,14 @@ when the pod is created, so it is ignored by the scheduler). Therefore: Daemon pods do respect [taints and tolerations](/docs/concepts/configuration/assign-pod-node/#taints-and-tolerations-beta-feature), but they are created with `NoExecute` tolerations for the following taints with no `tolerationSeconds`: - - `node.alpha.kubernetes.io/notReady` + - `node.kubernetes.io/not-ready` - `node.alpha.kubernetes.io/unreachable` - - `node.alpha.kubernetes.io/memoryPressure` - - `node.alpha.kubernetes.io/diskPressure` + - `node.kubernetes.io/memory-pressure` + - `node.kubernetes.io/disk-pressure` When the support to critical pods is enabled and the pods in a DaemonSet are labelled as critical, the Daemon pods are created with an additional -`NoExecute` toleration for the `node.alpha.kubernetes.io/outOfDisk` taint with +`NoExecute` toleration for the `node.alpha.kubernetes.io/out-of-disk` taint with no `tolerationSeconds`. This ensures that when the `TaintBasedEvictions` alpha feature is enabled,