Skip to content

Commit

Permalink
Graduate Evented PLEG to Beta
Browse files Browse the repository at this point in the history
Signed-off-by: Harshal Patil <[email protected]>
  • Loading branch information
harche committed Mar 14, 2023
1 parent bd456cf commit f9df2ac
Show file tree
Hide file tree
Showing 2 changed files with 61 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,8 @@ For a reference to old feature gates that are removed, please refer to
| `DownwardAPIHugePages` | `false` | Beta | 1.21 | 1.21 |
| `DownwardAPIHugePages` | `true` | Beta | 1.22 | |
| `DynamicResourceAllocation` | `false` | Alpha | 1.26 | |
| `EventedPLEG` | `false` | Alpha | 1.26 | - |
| `EventedPLEG` | `false` | Alpha | 1.26 | 1.26 |
| `EventedPLEG` | `false` | Beta | 1.27 | - |
| `ExpandedDNSConfig` | `false` | Alpha | 1.22 | 1.25 |
| `ExpandedDNSConfig` | `true` | Beta | 1.26 | |
| `ExperimentalHostUserNamespaceDefaulting` | `false` | Beta | 1.5 | |
Expand Down
59 changes: 59 additions & 0 deletions content/en/docs/tasks/administer-cluster/switch-to-evented-pleg.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
---
title: Switch to Evented PLEG
content_type: task
weight: 90
---

<!-- overview -->
This page shows how to use `Evented PLEG` in Kubelet which attempts to lower the resource consumption by avoiding frequent polling for container statuses.


## {{% heading "prerequisites" %}}


{{< include "task-tutorial-prereqs.md" >}} {{< version-check >}}



<!-- steps -->

## Why switch to Evented PLEG?

* The current `Generic PLEG` incurs non-negligible overhead due to frequent polling of container statuses.
* This overhead is exacerbated by Kubelet's parallelism, limiting its scalability and causing poor performance and reliability problems.
* The goal of `Evented PLEG` is to reduce unnecessary work during inactivity by replacing periodic polling.

## Switching to Evented PLEG

1. Start the `CRI Runtime` with the `Evented PLEG` support. e.g.
1. Containerd - <PLACE HOLDER>
2. CRI-O - Start the cri-o daemon with the flag `--enable-pod-events=true` or using a drop in config like,
```toml
[crio.runtime]
enable_pod_events: true
```

2. Start the kubernetes cluster with the [feature gate](https://kubernetes.io/docs/reference/command-line-tools-reference/feature-gates/) `EventedPLEG` enabled.


3. Verify that `Evented PLEG` is in use:

```bash
$ grep EventedPLEG /tmp/kubelet.log
I0314 11:10:13.909915 1105457 feature_gate.go:249] feature gates: &{map[EventedPLEG:true]}
```

If you have set LOG_LEVEL to 4 and above,
```bash
$ grep "Evented PLEG" /tmp/kubelet.log
I0314 11:12:42.009542 1110177 evented.go:238] "Evented PLEG: Generated pod status from the received event" podUID=3b2c6172-b112-447a-ba96-94e7022912dc
I0314 11:12:44.623326 1110177 evented.go:238] "Evented PLEG: Generated pod status from the received event" podUID=b3fba5ea-a8c5-4b76-8f43-481e17e8ec40
I0314 11:12:44.714564 1110177 evented.go:238] "Evented PLEG: Generated pod status from the received event" podUID=b3fba5ea-a8c5-4b76-8f43-481e17e8ec40
```

## {{% heading "whatsnext" %}}

* Learn more about [Evented PLEG](https://github.com/kubernetes/enhancements/blob/5b258a990adabc2ffdc9d84581ea6ed696f7ce6c/keps/sig-node/3386-kubelet-evented-pleg/README.md).



0 comments on commit f9df2ac

Please sign in to comment.