@@ -262,21 +262,35 @@ problems, the kubelet resets the restart backoff timer for that container.
262
262
[ Sidecar containers and Pod lifecycle] ( /docs/concepts/workloads/pods/sidecar-containers/#sidecar-containers-and-pod-lifecycle )
263
263
explains the behaviour of ` init containers ` when specify ` restartpolicy ` field on it.
264
264
265
+ ### Reduced container restart delay
266
+
267
+ {{< feature-state
268
+ feature_gate_name="ReduceDefaultCrashLoopBackOffDecay" >}}
269
+
270
+ With the alpha feature gate ` ReduceDefaultCrashLoopBackOffDecay ` enabled,
271
+ container start retries across your cluster will be reduced to begin at 1s
272
+ (instead of 10s) and increase exponentially by 2x each restart until a maximum
273
+ delay of 60s (instead of 300s which is 5 minutes).
274
+
275
+ If you use this feature along with the alpha feature
276
+ ` KubeletCrashLoopBackOffMax ` (described below), individual nodes may have
277
+ different maximum delays.
278
+
265
279
### Configurable container restart delay
266
280
267
281
{{< feature-state feature_gate_name="KubeletCrashLoopBackOffMax" >}}
268
282
269
283
With the alpha feature gate ` KubeletCrashLoopBackOffMax ` enabled, you can
270
284
reconfigure the maximum delay between container start retries from the default
271
285
of 300s (5 minutes). This configuration is set per node using kubelet
272
- configuration. In your [ kubelet configuration ] ( /docs/tasks/administer-cluster/kubelet-config-file/ ) ,
273
- under ` crashLoopBackOff ` set the ` maxContainerRestartPeriod ` field between
274
- ` "1s" ` and ` "300s" ` . As described above in [ Container restart
275
- policy] ( #restart-policy ) , delays on that node will still start at 10s and
276
- increase exponentially by 2x each restart, but will now be capped at your
277
- configured maximum. If the ` maxContainerRestartPeriod ` you configure is less
278
- than the default initial value of 10s, the initial delay will instead be set to
279
- the configured maximum.
286
+ configuration. In your [ kubelet
287
+ configuration ] ( /docs/tasks/administer-cluster/kubelet-config-file/ ) , under
288
+ ` crashLoopBackOff ` set the ` maxContainerRestartPeriod ` field between ` "1s" ` and
289
+ ` "300s" ` . As described above in [ Container restart policy] ( #restart-policy ) ,
290
+ delays on that node will still start at 10s and increase exponentially by 2x
291
+ each restart, but will now be capped at your configured maximum. If the
292
+ ` maxContainerRestartPeriod ` you configure is less than the default initial value
293
+ of 10s, the initial delay will instead be set to the configured maximum.
280
294
281
295
See the following kubelet configuration examples:
282
296
@@ -295,6 +309,13 @@ crashLoopBackOff:
295
309
maxContainerRestartPeriod : " 2s"
296
310
` ` `
297
311
312
+ If you use this feature along with the alpha feature
313
+ ` ReduceDefaultCrashLoopBackOffDecay` (described above), your cluster defaults
314
+ for initial backoff and maximum backoff will no longer be 10s and 300s, but 1s
315
+ and 60s. Per node configuration takes precedence over the defaults set by
316
+ ` ReduceDefaultCrashLoopBackOffDecay` , even if this would result in a node having
317
+ a longer maximum backoff than other nodes in the cluster.
318
+
298
319
# # Pod conditions
299
320
300
321
A Pod has a PodStatus, which has an array of
0 commit comments