kubernetes: Flaky timeouts while waiting for RC pods to be running in density test

About this issue

  • Original URL
  • State: closed
  • Created 6 years ago
  • Comments: 29 (28 by maintainers)

Commits related to this issue

Most upvoted comments

@janetkuo @enisoc - thanks a lot that’s super useful!

So I did a bit more debugging. And what is happening is that in all cases that I’ve seen is:

  1. daemon-set controller is removing fluentd from that node
  2. the latency-pod is scheduled on that node
  3. daemon-set controller is recreating fluentd on that node
  4. kubelet is preempting latency-pod to make place for fluentd (which is critical pod)

So that flow seems reasonable.

My only question now is why daemon-set controller is deleting and recreating fluentd on some node. What is important is that this operation is not done on all nodes.

As an example, in this run: http://gcsweb.k8s.io/gcs/kubernetes-jenkins/logs/ci-kubernetes-e2e-gci-gce-scalability/11664/artifacts/e2e-big-master/

There were 100 nodes, but during the whole run (~40 minutes), controller-manager recreated fluentd pods only on 39 nodes. @janetkuo @enisoc What is triggering those recreations?

why replication controller created two pods (and only then why it didn’t remove the second one)

It looks like one of the RC’s pods Failed? RC never sets its pods to Failed state, because its restartPolicy is Always. It must be kubelet.

When kubelet evicts pods, it sets pod state to Failed but doesn’t delete evicted pods (#54525). @enisoc we’ve debugged another issue related to this.

RC doesn’t take any inactive pods (failed, succeeded, terminating) into account: https://github.com/kubernetes/kubernetes/blob/02611149c181f7fd9ab116c40d7ee32fb5934b7c/pkg/controller/replicaset/replica_set.go#L607-L612 From RC’s view, there’s only 1 active replica so RC didn’t try to remove more replicas.