Kubernetes taints

Hey community,

I wonder why I need to define taint effects on both, on node and on pod, can someone explain me why I have to do so?

There are three types of taint effects:

NoSchedule
NoExecute
PreferNoSchedule

Why do I have to define these on node and on port, I don’t understand why I need to define them on both, what’s the result when both are not the same, meaning for example:

node

kubectl taint nodes node1 key1=value1:NoSchedule

pod

tolerations:
- key: "key1"
  operator: "Equal"
  value: "value1"
  effect: "NoExecute"

In order to tolerate the taint of a node , you need to declare the tolerations in the pod.

Handover to the taints and tolerations lecture, where mumshad has explained clearly with a pictorial diagram

I 've seen this lecture already.

I understand the taint on nodes is the “resulting” action the node chooses when the pod is NOT MATCHING the taint scope, but the taint effect on the pod itself, when is this effect relevant (executed)?