Skip to content

Commit f0bb277

Browse files
authored
Merge pull request #29658 from kubernetes/dev-1.23
Official 1.23 Release Docs
2 parents aa2f69c + 03f82bf commit f0bb277

File tree

59 files changed

+46232
-856
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

59 files changed

+46232
-856
lines changed

config.toml

Lines changed: 19 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -139,10 +139,10 @@ time_format_default = "January 02, 2006 at 3:04 PM PST"
139139
description = "Production-Grade Container Orchestration"
140140
showedit = true
141141

142-
latest = "v1.22"
142+
latest = "v1.23"
143143

144-
fullversion = "v1.22.0"
145-
version = "v1.22"
144+
fullversion = "v1.23.0"
145+
version = "v1.23"
146146
githubbranch = "main"
147147
docsbranch = "main"
148148
deprecated = false
@@ -179,40 +179,40 @@ js = [
179179
]
180180

181181
[[params.versions]]
182-
fullversion = "v1.22.0"
183-
version = "v1.22"
184-
githubbranch = "v1.22.0"
182+
fullversion = "v1.23.0"
183+
version = "v1.23"
184+
githubbranch = "v1.23.0"
185185
docsbranch = "main"
186186
url = "https://kubernetes.io"
187187

188188
[[params.versions]]
189-
fullversion = "v1.21.4"
189+
fullversion = "v1.22.4"
190+
version = "v1.22"
191+
githubbranch = "v1.22.4"
192+
docsbranch = "release-1.22"
193+
url = "https://v1-22.docs.kubernetes.io"
194+
195+
[[params.versions]]
196+
fullversion = "v1.21.7"
190197
version = "v1.21"
191-
githubbranch = "v1.21.4"
198+
githubbranch = "v1.21.7"
192199
docsbranch = "release-1.21"
193200
url = "https://v1-21.docs.kubernetes.io"
194201

195202
[[params.versions]]
196-
fullversion = "v1.20.10"
203+
fullversion = "v1.20.13"
197204
version = "v1.20"
198-
githubbranch = "v1.20.10"
205+
githubbranch = "v1.20.13"
199206
docsbranch = "release-1.20"
200207
url = "https://v1-20.docs.kubernetes.io"
201208

202209
[[params.versions]]
203-
fullversion = "v1.19.14"
210+
fullversion = "v1.19.16"
204211
version = "v1.19"
205-
githubbranch = "v1.19.14"
212+
githubbranch = "v1.19.16"
206213
docsbranch = "release-1.19"
207214
url = "https://v1-19.docs.kubernetes.io"
208215

209-
[[params.versions]]
210-
fullversion = "v1.18.20"
211-
version = "v1.18"
212-
githubbranch = "v1.18.20"
213-
docsbranch = "release-1.18"
214-
url = "https://v1-18.docs.kubernetes.io"
215-
216216
# User interface configuration
217217
[params.ui]
218218
# Enable to show the side bar menu in its compact state.

content/en/blog/_posts/2018-10-01-health-checking-grpc.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@ title: 'Health checking gRPC servers on Kubernetes'
44
date: 2018-10-01
55
---
66

7+
_Built-in gRPC probes were introduced in Kubernetes 1.23. To learn more, see [Configure Liveness, Readiness and Startup Probes](/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/#define-a-grpc-liveness-probe)._
8+
79
**Author**: [Ahmet Alp Balkan](https://twitter.com/ahmetb) (Google)
810

911
[gRPC](https://grpc.io) is on its way to becoming the lingua franca for
Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
---
2+
title: Container Runtime Interface (CRI)
3+
content_type: concept
4+
weight: 50
5+
---
6+
7+
<!-- overview -->
8+
9+
The CRI is a plugin interface which enables the kubelet to use a wide variety of
10+
container runtimes, without having a need to recompile the cluster components.
11+
12+
You need a working
13+
{{<glossary_tooltip text="container runtime" term_id="container-runtime">}} on
14+
each Node in your cluster, so that the
15+
{{< glossary_tooltip text="kubelet" term_id="kubelet" >}} can launch
16+
{{< glossary_tooltip text="Pods" term_id="pod" >}} and their containers.
17+
18+
{{< glossary_definition term_id="container-runtime-interface" length="all" >}}
19+
20+
<!-- body -->
21+
22+
## The API {#api}
23+
24+
{{< feature-state for_k8s_version="v1.23" state="stable" >}}
25+
26+
The kubelet acts as a client when connecting to the container runtime via gRPC.
27+
The runtime and image service endpoints have to be available in the container
28+
runtime, which can be configured separately within the kubelet by using the
29+
`--image-service-endpoint` and `--container-runtime-endpoint` [command line
30+
flags](/docs/reference/command-line-tools-reference/kubelet)
31+
32+
For Kubernetes v{{< skew currentVersion >}}, the kubelet prefers to use CRI `v1`.
33+
If a container runtime does not support `v1` of the CRI, then the kubelet tries to
34+
negotiate any older supported version.
35+
The v{{< skew currentVersion >}} kubelet can also negotiate CRI `v1alpha2`, but
36+
this version is considered as deprecated.
37+
If the kubelet cannot negotiate a supported CRI version, the kubelet gives up
38+
and doesn't register as a node.
39+
40+
## Upgrading
41+
42+
When upgrading Kubernetes, then the kubelet tries to automatically select the
43+
latest CRI version on restart of the component. If that fails, then the fallback
44+
will take place as mentioned above. If a gRPC re-dial was required because the
45+
container runtime has been upgraded, then the container runtime must also
46+
support the initially selected version or the redial is expected to fail. This
47+
requires a restart of the kubelet.
48+
49+
## {{% heading "whatsnext" %}}
50+
51+
- Learn more about the CRI [protocol definition](https://github.com/kubernetes/cri-api/blob/c75ef5b/pkg/apis/runtime/v1/api.proto)

content/en/docs/concepts/architecture/nodes.md

Lines changed: 91 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -424,20 +424,104 @@ for gracefully terminating normal pods, and the last 10 seconds would be
424424
reserved for terminating [critical pods](/docs/tasks/administer-cluster/guaranteed-scheduling-critical-addon-pods/#marking-pod-as-critical).
425425

426426
{{< note >}}
427-
When pods were evicted during the graceful node shutdown, they are marked as failed.
428-
Running `kubectl get pods` shows the status of the the evicted pods as `Shutdown`.
427+
When pods were evicted during the graceful node shutdown, they are marked as shutdown.
428+
Running `kubectl get pods` shows the status of the the evicted pods as `Terminated`.
429429
And `kubectl describe pod` indicates that the pod was evicted because of node shutdown:
430430

431431
```
432-
Status: Failed
433-
Reason: Shutdown
434-
Message: Node is shutting, evicting pods
432+
Reason: Terminated
433+
Message: Pod was terminated in response to imminent node shutdown.
435434
```
436435

437-
Failed pod objects will be preserved until explicitly deleted or [cleaned up by the GC](/docs/concepts/workloads/pods/pod-lifecycle/#pod-garbage-collection).
438-
This is a change of behavior compared to abrupt node termination.
439436
{{< /note >}}
440437

438+
### Pod Priority based graceful node shutdown {#pod-priority-graceful-node-shutdown}
439+
440+
{{< feature-state state="alpha" for_k8s_version="v1.23" >}}
441+
442+
To provide more flexibility during graceful node shutdown around the ordering
443+
of pods during shutdown, graceful node shutdown honors the PriorityClass for
444+
Pods, provided that you enabled this feature in your cluster. The feature
445+
allows allows cluster administers to explicitly define the ordering of pods
446+
during graceful node shutdown based on [priority
447+
classes](docs/concepts/scheduling-eviction/pod-priority-preemption/#priorityclass).
448+
449+
The [Graceful Node Shutdown](#graceful-node-shutdown) feature, as described
450+
above, shuts down pods in two phases, non-critical pods, followed by critical
451+
pods. If additional flexibility is needed to explicitly define the ordering of
452+
pods during shutdown in a more granular way, pod priority based graceful
453+
shutdown can be used.
454+
455+
When graceful node shutdown honors pod priorities, this makes it possible to do
456+
graceful node shutdown in multiple phases, each phase shutting down a
457+
particular priority class of pods. The kubelet can be configured with the exact
458+
phases and shutdown time per phase.
459+
460+
Assuming the following custom pod [priority
461+
classes](docs/concepts/scheduling-eviction/pod-priority-preemption/#priorityclass)
462+
in a cluster,
463+
464+
|Pod priority class name|Pod priority class value|
465+
|-------------------------|------------------------|
466+
|`custom-class-a` | 100000 |
467+
|`custom-class-b` | 10000 |
468+
|`custom-class-c` | 1000 |
469+
|`regular/unset` | 0 |
470+
471+
Within the [kubelet configuration](/docs/reference/config-api/kubelet-config.v1beta1/#kubelet-config-k8s-io-v1beta1-KubeletConfiguration)
472+
the settings for `shutdownGracePeriodByPodPriority` could look like:
473+
474+
|Pod priority class value|Shutdown period|
475+
|------------------------|---------------|
476+
| 100000 |10 seconds |
477+
| 10000 |180 seconds |
478+
| 1000 |120 seconds |
479+
| 0 |60 seconds |
480+
481+
The corresponding kubelet config YAML configuration would be:
482+
483+
```yaml
484+
shutdownGracePeriodByPodPriority:
485+
- priority: 100000
486+
shutdownGracePeriodSeconds: 10
487+
- priority: 10000
488+
shutdownGracePeriodSeconds: 180
489+
- priority: 1000
490+
shutdownGracePeriodSeconds: 120
491+
- priority: 0
492+
shutdownGracePeriodSeconds: 60
493+
```
494+
495+
The above table implies that any pod with priority value >= 100000 will get
496+
just 10 seconds to stop, any pod with value >= 10000 and < 100000 will get 180
497+
seconds to stop, any pod with value >= 1000 and < 10000 will get 120 seconds to stop.
498+
Finally, all other pods will get 60 seconds to stop.
499+
500+
One doesn't have to specify values corresponding to all of the classes. For
501+
example, you could instead use these settings:
502+
503+
|Pod priority class value|Shutdown period|
504+
|------------------------|---------------|
505+
| 100000 |300 seconds |
506+
| 1000 |120 seconds |
507+
| 0 |60 seconds |
508+
509+
510+
In the above case, the pods with custom-class-b will go into the same bucket
511+
as custom-class-c for shutdown.
512+
513+
If there are no pods in a particular range, then the kubelet does not wait
514+
for pods in that priority range. Instead, the kubelet immediately skips to the
515+
next priority class value range.
516+
517+
If this feature is enabled and no configuration is provided, then no ordering
518+
action will be taken.
519+
520+
Using this feature, requires enabling the
521+
`GracefulNodeShutdownBasedOnPodPriority` feature gate, and setting the kubelet
522+
config's `ShutdownGracePeriodByPodPriority` to the desired configuration
523+
containing the pod priority class values and their respective shutdown periods.
524+
441525
## Swap memory management {#swap-memory}
442526

443527
{{< feature-state state="alpha" for_k8s_version="v1.22" >}}

content/en/docs/concepts/cluster-administration/networking.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ This means that containers within a `Pod` can all reach each other's ports on
6464
usage, but this is no different from processes in a VM. This is called the
6565
"IP-per-pod" model.
6666

67-
How this is implemented is a detail of the particular container runtime in use.
67+
How this is implemented is a detail of the particular container runtime in use. Likewise, the networking option you choose may support [dual-stack IPv4/IPv6 networking](/docs/concepts/services-networking/dual-stack/); implementations vary.
6868

6969
It is possible to request ports on the `Node` itself which forward to your `Pod`
7070
(called host ports), but this is a very niche operation. How that forwarding is

content/en/docs/concepts/cluster-administration/system-logs.md

Lines changed: 63 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,14 +22,62 @@ generates log messages for the Kubernetes system components.
2222

2323
For more information about klog configuration, see the [Command line tool reference](/docs/reference/command-line-tools-reference/).
2424

25-
An example of the klog native format:
25+
Kubernetes is in the process of simplifying logging in its components. The
26+
following klog command line flags [are
27+
deprecated](https://github.com/kubernetes/enhancements/tree/master/keps/sig-instrumentation/2845-deprecate-klog-specific-flags-in-k8s-components)
28+
starting with Kubernetes 1.23 and will be removed in a future release:
29+
30+
- `--add-dir-header`
31+
- `--alsologtostderr`
32+
- `--log-backtrace-at`
33+
- `--log-dir`
34+
- `--log-file`
35+
- `--log-file-max-size`
36+
- `--logtostderr`
37+
- `--one-output`
38+
- `--skip-headers`
39+
- `--skip-log-headers`
40+
- `--stderrthreshold`
41+
42+
Output will always be written to stderr, regardless of the output
43+
format. Output redirection is expected to be handled by the component which
44+
invokes a Kubernetes component. This can be a POSIX shell or a tool like
45+
systemd.
46+
47+
In some cases, for example a distroless container or a Windows system service,
48+
those options are not available. Then the
49+
[`kube-log-runner`](https://github.com/kubernetes/kubernetes/blob/d2a8a81639fcff8d1221b900f66d28361a170654/staging/src/k8s.io/component-base/logs/kube-log-runner/README.md)
50+
binary can be used as wrapper around a Kubernetes component to redirect
51+
output. A prebuilt binary is included in several Kubernetes base images under
52+
its traditional name as `/go-runner` and as `kube-log-runner` in server and
53+
node release archives.
54+
55+
This table shows how `kube-log-runner` invocations correspond to shell redirection:
56+
57+
| Usage | POSIX shell (such as bash) | `kube-log-runner <options> <cmd>` |
58+
| -----------------------------------------|----------------------------|-------------------------------------------------------------|
59+
| Merge stderr and stdout, write to stdout | `2>&1` | `kube-log-runner` (default behavior) |
60+
| Redirect both into log file | `1>>/tmp/log 2>&1` | `kube-log-runner -log-file=/tmp/log` |
61+
| Copy into log file and to stdout | `2>&1 \| tee -a /tmp/log` | `kube-log-runner -log-file=/tmp/log -also-stdout` |
62+
| Redirect only stdout into log file | `>/tmp/log` | `kube-log-runner -log-file=/tmp/log -redirect-stderr=false` |
63+
64+
### Klog output
65+
66+
An example of the traditional klog native format:
2667
```
2768
I1025 00:15:15.525108 1 httplog.go:79] GET /api/v1/namespaces/kube-system/pods/metrics-server-v0.3.1-57c75779f-9p8wg: (1.512ms) 200 [pod_nanny/v0.0.0 (linux/amd64) kubernetes/$Format 10.56.1.19:51756]
2869
```
2970

71+
The message string may contain line breaks:
72+
```
73+
I1025 00:15:15.525108 1 example.go:79] This is a message
74+
which has a line break.
75+
```
76+
77+
3078
### Structured Logging
3179

32-
{{< feature-state for_k8s_version="v1.19" state="alpha" >}}
80+
{{< feature-state for_k8s_version="v1.23" state="beta" >}}
3381

3482
{{< warning >}}
3583
Migration to structured log messages is an ongoing process. Not all log messages are structured in this version. When parsing log files, you must also handle unstructured log messages.
@@ -38,9 +86,11 @@ Log formatting and value serialization are subject to change.
3886
{{< /warning>}}
3987

4088
Structured logging introduces a uniform structure in log messages allowing for programmatic extraction of information. You can store and process structured logs with less effort and cost.
41-
New message format is backward compatible and enabled by default.
89+
The code which generates a log message determines whether it uses the traditional unstructured klog output
90+
or structured logging.
4291

43-
Format of structured logs:
92+
The default formatting of structured log messages is as text, with a format that
93+
is backward compatible with traditional klog:
4494

4595
```ini
4696
<klog header> "<message>" <key1>="<value1>" <key2>="<value2>" ...
@@ -52,6 +102,13 @@ Example:
52102
I1025 00:15:15.525108 1 controller_utils.go:116] "Pod status updated" pod="kube-system/kubedns" status="ready"
53103
```
54104

105+
Strings are quoted. Other values are formatted with
106+
[`%+v`](https://pkg.go.dev/fmt#hdr-Printing), which may cause log messages to
107+
continue on the next line [depending on the data](https://github.com/kubernetes/kubernetes/issues/106428).
108+
```
109+
I1025 00:15:15.525108 1 example.go:116] "Example" data="This is text with a line break\nand \"quotation marks\"." someInt=1 someFloat=0.1 someStruct={StringField: First line,
110+
second line.}
111+
```
55112

56113
### JSON log format
57114

@@ -82,7 +139,7 @@ Example of JSON log format (pretty printed):
82139

83140
Keys with special meaning:
84141
* `ts` - timestamp as Unix time (required, float)
85-
* `v` - verbosity (required, int, default 0)
142+
* `v` - verbosity (only for info and not for error messages, int)
86143
* `err` - error string (optional, string)
87144
* `msg` - message (required, string)
88145

@@ -139,4 +196,5 @@ The `logrotate` tool rotates logs daily, or once the log size is greater than 10
139196

140197
* Read about the [Kubernetes Logging Architecture](/docs/concepts/cluster-administration/logging/)
141198
* Read about [Structured Logging](https://github.com/kubernetes/enhancements/tree/master/keps/sig-instrumentation/1602-structured-logging)
199+
* Read about [deprecation of klog flags](https://github.com/kubernetes/enhancements/tree/master/keps/sig-instrumentation/2845-deprecate-klog-specific-flags-in-k8s-components)
142200
* Read about the [Conventions for logging severity](https://github.com/kubernetes/community/blob/master/contributors/devel/sig-instrumentation/logging.md)

content/en/docs/concepts/extend-kubernetes/_index.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ failure.
7777
In the webhook model, Kubernetes makes a network request to a remote service.
7878
In the *Binary Plugin* model, Kubernetes executes a binary (program).
7979
Binary plugins are used by the kubelet (e.g.
80-
[Flex Volume Plugins](/docs/concepts/storage/volumes/#flexVolume)
80+
[Flex Volume Plugins](/docs/concepts/storage/volumes/#flexvolume)
8181
and [Network Plugins](/docs/concepts/extend-kubernetes/compute-storage-net/network-plugins/))
8282
and by kubectl.
8383

@@ -163,6 +163,8 @@ After a request is authorized, if it is a write operation, it also goes through
163163
) allow users to mount volume types without built-in support by having the
164164
Kubelet call a Binary Plugin to mount the volume.
165165

166+
FlexVolume is deprecated since Kubernetes v1.23. The Out-of-tree CSI driver is the recommended way to write volume drivers in Kubernetes. See [Kubernetes Volume Plugin FAQ for Storage Vendors](https://github.com/kubernetes/community/blob/master/sig-storage/volume-plugin-faq.md#kubernetes-volume-plugin-faq-for-storage-vendors) for more information.
167+
166168

167169
### Device Plugins
168170

0 commit comments

Comments
 (0)