Skip to content

Commit 391459b

Browse files
authored
Merge pull request #28434 from mehabhalodiya/fix-28324
Add tooltip for affinity
2 parents ba20879 + 53da9df commit 391459b

File tree

2 files changed

+28
-6
lines changed

2 files changed

+28
-6
lines changed

content/en/docs/concepts/scheduling-eviction/pod-priority-preemption.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -252,12 +252,12 @@ Even so, the answer to the preceding question must be yes. If the answer is no,
252252
the Node is not considered for preemption.
253253
{{< /note >}}
254254

255-
If a pending Pod has inter-pod affinity to one or more of the lower-priority
256-
Pods on the Node, the inter-Pod affinity rule cannot be satisfied in the absence
257-
of those lower-priority Pods. In this case, the scheduler does not preempt any
258-
Pods on the Node. Instead, it looks for another Node. The scheduler might find a
259-
suitable Node or it might not. There is no guarantee that the pending Pod can be
260-
scheduled.
255+
If a pending Pod has inter-pod {{< glossary_tooltip text="affinity" term_id="affinity" >}}
256+
to one or more of the lower-priority Pods on the Node, the inter-Pod affinity
257+
rule cannot be satisfied in the absence of those lower-priority Pods. In this case,
258+
the scheduler does not preempt any Pods on the Node. Instead, it looks for another
259+
Node. The scheduler might find a suitable Node or it might not. There is no
260+
guarantee that the pending Pod can be scheduled.
261261

262262
Our recommended solution for this problem is to create inter-Pod affinity only
263263
towards equal or higher priority Pods.
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
---
2+
title: Affinity
3+
id: affinity
4+
date: 2019-01-11
5+
full_link: /docs/concepts/scheduling-eviction/assign-pod-node/#affinity-and-anti-affinity
6+
short_description: >
7+
Rules used by the scheduler to determine where to place pods
8+
aka:
9+
tags:
10+
- fundamental
11+
---
12+
13+
In Kubernetes, _affinity_ is a set of rules that give hints to the scheduler about where to place pods.
14+
15+
<!--more-->
16+
There are two kinds of affinity:
17+
* [node affinity](/docs/concepts/scheduling-eviction/assign-pod-node/#node-affinity)
18+
* [pod-to-pod affinity](/docs/concepts/scheduling-eviction/assign-pod-node/#inter-pod-affinity-and-anti-affinity)
19+
20+
The rules are defined using the Kubernetes {{< glossary_tooltip term_id="label" text="labels">}},
21+
and {{< glossary_tooltip term_id="selector" text="selectors">}} specified in {{< glossary_tooltip term_id="pod" text="pods" >}},
22+
and they can be either required or preferred, depending on how strictly you want the scheduler to enforce them.

0 commit comments

Comments
 (0)