Open andyblog opened 4 months ago
it happens also on version 0.37.0
k describe <node>
.
.
Resource Requests Limits
-------- -------- ------
cpu 507m (12%) 302m (7%)
.
.
requirements for my pods are CPU: "3.5", RAM: "15Gi"
and in my case karpenter creates r5dn.xlarge
which is too small for my pod and only daemon set pods are running there.
I'm also noticing similar issue, where Pods are scheduled by Karpenter on a nodeclaim, while default-scheduler decides that given node from Karpenter has insufficient resources and won't run the pod on this node, hence I have Pod stuck in Pending for many hours sometimes days
If you encounter this problem, you can refer to this link of karpenter, which describes how to add resource reservation in the configuration to solve this problem. Please ask the R&D staff to help confirm whether there is another way to solve it. https://karpenter.sh/docs/concepts/nodepools/#reserved-resources
we tried bumping up kube reserved memory still seeing issues where nodes are created while kube scheduler is unhappy with node created and won't place the pod, but we noticed at in past when we were at v0.27.X Karpenter was able to relax the topologConstraints and place the nodes properly, our daemonsets haven't changed before or after upgrade of Karpenter.
I have two deployments with same topologyConstraints and still seeing issues with one deployment unable to have pods scheduled while other deployment succeeds
Description
Observed Behavior:
The resources required by the pod are 7 cores and 5 GB. The node specification is set to c5.2xlarge in the nodepool configuration. This node is configured to be 8 cores and 16 GB. Therefore, this node can allow the pod to run normally, but it appears to be pulling new node all the time, and the pod still is pending.
My understanding is: kubelet on the node reserves 500m cpu in its own resource settings, so the allocable cpu is 7500m. Daemonset pod requires 700m cpu, so when the node is started and daemonset is scheduled, centos pod has no resources to run on the node, so karpenter continues to pull up a new machine.
Expected Behavior:
This situation should have been encountered by other companies. What is the best practice and how to avoid this situation? Is it possible to add fixed resources in the karpenter configuration file to indicate the resource reservation size of kubelet?
How does Karpenter calculate the required node specifications: Is it determined by the resources required by the business pod + daemonset pod?
Reproduction Steps (Please include YAML):
karpenter version
karpenter nodepool config
my deployment yaml
log
pod still is pending
Versions:
Chart Version: karpenter-v0.32.9
Kubernetes Version (
kubectl version
): v1.28.11-eks-db838b0Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
Please do not leave "+1" or "me too" comments, they generate extra noise for issue followers and do not help prioritize the request
If you are interested in working on this issue or have submitted a pull request, please leave a comment