Reputation: 433
I basically want to find the hard eviction strategy that kubelet is currently using.
I checked the settings in the /etc/systemd/system/kubelet.service file on my K8s node. In that the strategy I mentioned is as follows:
--eviction-hard=nodefs.available<3Gi
However, my pods seem to be evicted when the nodefs.available is <10% (default kubernetes settings) I have been unable to find a way a way to know the current parameters that are being used by kubernetes.
Upvotes: 24
Views: 24530
Reputation: 13941
It is possible to dump the current kubelet configuration using kubectl proxy
along with the /api/v1/nodes/${TARGET_NODE_FOR_KUBELET}/proxy/configz
path.
For details, see linked Kubernetes docs (⚠️ outdated documentation; now provided via Wayback Machine as historic reference material).
Upvotes: 21
Reputation: 6122
You can use kubectl
for that:
kubectl get --raw "/api/v1/nodes/<nodename>/proxy/configz" | jq
Just make sure you replace <nodename>
with your node name. And if you don't have jq
installed, leave out the | jq
part as that's only for formatting.
Upvotes: 33