Unterschiede
Hier werden die Unterschiede zwischen zwei Versionen angezeigt.
Nächste Überarbeitung | Vorhergehende Überarbeitung | ||
en:modul:m321_aws:topics:09 [2025/09/30 17:46] – angelegt dgaravaldi | en:modul:m321_aws:topics:09 [2025/09/30 21:23] (aktuell) – dgaravaldi | ||
---|---|---|---|
Zeile 1: | Zeile 1: | ||
- | ===== Pod Lifecycle | + | ===== How Kubernetes " |
+ | Let's first have an overview over the pieces of ' | ||
+ | |||
+ | - **Controllers** (Deployment → ReplicaSet → Pods): A Deployment declares the desired number of pod replicas. The '' | ||
+ | - **Restart Policy**: Container-level restarts are controlled by the Pod’s '' | ||
+ | - **Health checks** (so called **Probes**) | ||
+ | * **Liveness probe**: if it fails, kubelet will kill & restart the container (useful for recovering stuck processes). | ||
+ | * **Readiness probe**: controls whether a pod is considered " | ||
+ | - **Pod lifecycle**: | ||
+ | |||
+ | \\ | ||
+ | ==== Pod Lifecycle | ||
Lifecycle and hooks that are offered for Pods (and Containers) are points where your code can take actions. Kubernetes offers a number of places where you can provide explicit feedback to the system to have it operate as you’d like. | Lifecycle and hooks that are offered for Pods (and Containers) are points where your code can take actions. Kubernetes offers a number of places where you can provide explicit feedback to the system to have it operate as you’d like. | ||
Zeile 12: | Zeile 23: | ||
* **Succeeded (or) Failed**: The Pod has finished operation (normally or crashed) | * **Succeeded (or) Failed**: The Pod has finished operation (normally or crashed) | ||
* **Unknown**: | * **Unknown**: | ||
+ | \\ | ||
+ | ==== Probes ==== | ||
+ | |||
+ | The two probes enabled in Kubernetes are the **liveness probe** and **readiness Probe**. They are complimentary, | ||
+ | |||
+ | |||
+ | The most basic probe is the **Liveness probe**. It provides a command or URL that Kubernetes can use to determine | ||
+ | whether a Pod is still operational. If the call succeeds, Kubernetes will assume the container is healthy. If it fails to respond, | ||
+ | then the Pod can be handled as the '' | ||
+ | believes your Pod is running, or it fails, so Kubernetes believes your Pod is no longer functional. | ||
+ | |||
+ | In the latter case, it will check with the defined '' | ||
+ | |||
+ | The default value for '' | ||
+ | |||
+ | |||
+ | \\ | ||
+ | ---- | ||
Based on " | Based on " |