Skip to content

Listener pod stuck Terminating on an unreachable node leaves the scale set without a listener #4752

Open

Description

@cniackz

Checks

Controller Version

0.15.1

Deployment Method

Helm

Checks

  • This isn't a question or user support case (For Q&A and community support, go to Discussions).
  • I've read the Changelog before submitting this issue and I'm sure it's not due to any recently-introduced backward-incompatible changes

To Reproduce

1. Install gha-runner-scale-set-controller 0.15.1 and a scale set from the official charts on a cluster with at least two workers. Pin the listener to one worker with `listenerTemplate.spec.nodeSelector`.
2. Make that worker unreachable without deleting its Node object. In kind: `docker pause <worker>`.
3. After the `node.kubernetes.io/unreachable` toleration (300 s by default, 30 s in the values below), taint-based eviction sets a deletion timestamp on the listener pod. The pod stays `Terminating`, because the kubelet cannot confirm the deletion.
4. Watch `kubectl get pods -n arc-systems` and the controller log. No new listener pod is created while the old pod object exists.
5. Either `docker unpause <worker>`, or `kubectl delete pod <listener> --grace-period=0 --force` once the node is confirmed down. A new listener pod is created within seconds.

Describe the bug

When the node that runs a listener pod becomes unreachable, taint-based eviction marks the pod for deletion, but the kubelet cannot confirm it, so the pod stays in Terminating. At gha-runner-scale-set-0.15.1, the AutoscalingListener reconciler returns early while the pod has a deletion timestamp (autoscalinglistener_controller.go#L534-L536), the pod name is fixed (#L497-L500), and listenerPodIsDead (#L984-L991) only matches an evicted pod or a terminated container, which a pod on a lost node is not. So no replacement listener starts until the pod object is gone: the node comes back, or someone removes the pod. Nothing from the controller, in its log or as an event, says why. In one cluster this left a scale set taking no jobs for about five hours. #4469 reported the same symptom on 0.14.1 and was closed without a change; the controller does reconcile here, and returns at the line above.

I first posted this as https://github.com/orgs/community/discussions/213565, which I opened through the API and a bot closed 21 seconds later, so I am filing it here.

Describe the expected behavior

This looks like the at-most-one behavior Kubernetes documents for StatefulSet pods on unreachable nodes, so I don't expect the controller to recreate the listener on its own. I would expect the stall to be visible: a Warning event on the AutoscalingListener once its pod has been terminating longer than a threshold. The troubleshooting guide could also document the recovery: once the node is confirmed down, force delete the listener pod, or apply the node.kubernetes.io/out-of-service taint (and remove it once the node is back), and the controller starts a new listener. I am opening a PR for the Warning event and am happy to send the docs change too.

Additional Context

# kind: 1 control-plane and 2 workers. The Actions service is a local fake.
# gha-runner-scale-set-controller 0.15.1 (oci://ghcr.io/actions/actions-runner-controller-charts), values:
nodeSelector: {node-role.kubernetes.io/control-plane: ""}
tolerations: [{key: node-role.kubernetes.io/control-plane, effect: NoSchedule}]
---
# gha-runner-scale-set 0.15.1, values:
githubConfigUrl: "http://fake.fake.svc.cluster.local:8080/fakeorg"
githubConfigSecret: {github_token: "REDACTED"}
runnerScaleSetName: probe
minRunners: 0
maxRunners: 1
controllerServiceAccount: {namespace: arc-systems, name: arc-gha-rs-controller}
listenerTemplate:
  spec:
    nodeSelector: {kubernetes.io/hostname: arclog-worker}
    tolerations:
    - {key: node.kubernetes.io/unreachable, operator: Exists, effect: NoExecute, tolerationSeconds: 30}
    - {key: node.kubernetes.io/not-ready, operator: Exists, effect: NoExecute, tolerationSeconds: 30}
    containers:
    - name: listener
template:
  spec:
    containers:
    - name: runner
      image: busybox
      command: ["sleep","3600"]

Controller Logs

# Complete controller log of the reproduction (66 lines): https://gist.github.com/cniackz/f3b7a92e5f71774d79ddc4aacfe7ce71
# The worker was paused at 14:39:01Z. The listener pod got a deletion timestamp of 14:40:49Z and stayed Terminating.
# The controller logged nothing between 14:38:56Z and the force delete at 14:45:23Z. These are the two "Creating listener pod" lines:
2026-11-20T14:38:56Z	INFO	AutoscalingListener	Creating listener pod	{"version": "0.15.1", "autoscalinglistener": {"name":"probe-69d84db4-listener","namespace":"arc-systems"}, "namespace": "arc-systems", "name": "probe-69d84db4-listener"}
2026-11-20T14:45:23Z	INFO	AutoscalingListener	Creating listener pod	{"version": "0.15.1", "autoscalinglistener": {"name":"probe-69d84db4-listener","namespace":"arc-systems"}, "namespace": "arc-systems", "name": "probe-69d84db4-listener"}

Runner Pod Logs

Not applicable: no runner pod is involved. Jobs never reach a runner because the scale set has no running listener.

Activity

  1. github-actions commented on Nov 20, 2026

    @github-actions
    Contributor

    Hello! Thank you for filing an issue.

    The maintainers will triage your issue shortly.

    In the meantime, please take a look at the troubleshooting guide for bug reports.

    If this is a feature request, please review our contribution guidelines.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions