Pod bias when building Elastic Cloud on Kubernetes (ECK) with LKE

ECK was built on LKE using the procedure shown here.

https://www.elastic.co/guide/en/cloud-on-k8s/current/k8s-quickstart.html

Pods are biased when pods are drained or uncordon for maintenance, etc.

I want to distribute pods to 3 Nodes for Data-Node and Master-Node, but I don't know how to configure it.

kubectl get pods -o wide

NAME                             READY   STATUS    RESTARTS        AGE     IP          NODE                            NOMINATED NODE   READINESS GATES
quickstart-es-data-nodes-0       1/1     Running   0               2d9h    10.2.5.28   lke116066-172974-649c63812a91   <none>           <none>
quickstart-es-data-nodes-1       1/1     Running   1 (2d16h ago)   4d9h    10.2.4.2    lke116066-172974-649c6380580d   <none>           <none>
quickstart-es-data-nodes-2       1/1     Running   0               2d9h    10.2.6.11   lke116066-172974-649c6380c34c   <none>           <none>
quickstart-es-master-nodes-0     1/1     Running   0               2d16h   10.2.4.6    lke116066-172974-649c6380580d   <none>           <none>
quickstart-es-master-nodes-1     1/1     Running   0               2d15h   10.2.5.2    lke116066-172974-649c63812a91   <none>           <none>
quickstart-es-master-nodes-2     1/1     Running   1 (2d16h ago)   4d9h    10.2.4.3    lke116066-172974-649c6380580d   <none>           <none>
quickstart-kb-694658999d-46b7m   1/1     Running   0               2d9h    10.2.5.26   lke116066-172974-649c63812a91   <none>           <none>
quickstart-kb-694658999d-6722x   1/1     Running   0               2d9h    10.2.5.23   lke116066-172974-649c63812a91   <none>           <none>
quickstart-kb-694658999d-89p7g   1/1     Running   1 (2d16h ago)   4d9h    10.2.4.7    lke116066-172974-649c6380580d   <none>           <none>
➜  eck kubectl get node
NAME                            STATUS   ROLES    AGE     VERSION
lke116066-172974-649c6380580d   Ready    <none>   4d9h    v1.26.3
lke116066-172974-649c6380c34c   Ready    <none>   2d16h   v1.26.3
lke116066-172974-649c63812a91   Ready    <none>   4d9h    v1.26.3

1 Reply

I think the feature you're looking to incorporate into your deployment is the ability to assign pods to nodes.

One method of accomplishing this is using the nodeSelector field to match with node labels.

A more fully featured way to assign pods to nodes is using affinity language. You can set your pod's affinity in the .spec.affinity.nodeAffinity field of the pod spec. This guide titled Assign Pods to Nodes using Node Affinity has instructions for making these configuration changes your cluster.

Reply

Please enter an answer
Tips:

You can mention users to notify them: @username

You can use Markdown to format your question. For more examples see the Markdown Cheatsheet.

> I’m a blockquote.

I’m a blockquote.

[I'm a link] (https://www.google.com)

I'm a link

**I am bold** I am bold

*I am italicized* I am italicized

Community Code of Conduct