Exec-ing into pod not working - "Server lost session"
What happened?
When trying to initiate new terminal session in pod from dashboard, the terminal screen stays black, and a message is displayed "Server lost session". In the logs, I see
[kubernetes-dashboard-api] 2024/03/11 13:59:01 handleTerminalSession: can't Recv: sockjs: session not in open state
What did you expect to happen?
Interactive terminal session established and shell prompt visible.
How can we reproduce it (as minimally and precisely as possible)?
- Deploy Kubernetes Dashboard via helm chart
- Navigate to a pod details page
- Click "Exec into pod"
- Observe "Server lost session" error message
Anything else we need to know?
No response
What browsers are you seeing the problem on?
Firefox
Kubernetes Dashboard version
7.1.2
Kubernetes version
1.26.9
Dev environment
No response
I could not reproduce it based on the provided steps. Tested on Firefox/Chrome and exec works just fine.
I upgraded to k8s 1.28.7, and since then, the problem is gone.
For future reference:
I am using a setup with HAProxy -> NGINX Inc's Ingress -> gogatekeeper (OAuth2 proxy) -> Kong service of Dashboard.
In the end, I had to whitelist the /api/sockjs path in gogatekeeper (it seems to remove auth headers) to get it to work consistently..
I have this issue on 1.28.5 EKS as well
Correction, it does not work consistently, but randomly. So, this issue is open and being tracked in #8838 I assume..
The Kubernetes project currently lacks enough contributors to adequately respond to all issues.
This bot triages un-triaged issues according to the following rules:
- After 90d of inactivity,
lifecycle/staleis applied - After 30d of inactivity since
lifecycle/stalewas applied,lifecycle/rottenis applied - After 30d of inactivity since
lifecycle/rottenwas applied, the issue is closed
You can:
- Mark this issue as fresh with
/remove-lifecycle stale - Close this issue with
/close - Offer to help out with Issue Triage
Please send feedback to sig-contributor-experience at kubernetes/community.
/lifecycle stale
The Kubernetes project currently lacks enough active contributors to adequately respond to all issues.
This bot triages un-triaged issues according to the following rules:
- After 90d of inactivity,
lifecycle/staleis applied - After 30d of inactivity since
lifecycle/stalewas applied,lifecycle/rottenis applied - After 30d of inactivity since
lifecycle/rottenwas applied, the issue is closed
You can:
- Mark this issue as fresh with
/remove-lifecycle rotten - Close this issue with
/close - Offer to help out with Issue Triage
Please send feedback to sig-contributor-experience at kubernetes/community.
/lifecycle rotten
The Kubernetes project currently lacks enough active contributors to adequately respond to all issues and PRs.
This bot triages issues according to the following rules:
- After 90d of inactivity,
lifecycle/staleis applied - After 30d of inactivity since
lifecycle/stalewas applied,lifecycle/rottenis applied - After 30d of inactivity since
lifecycle/rottenwas applied, the issue is closed
You can:
- Reopen this issue with
/reopen - Mark this issue as fresh with
/remove-lifecycle rotten - Offer to help out with Issue Triage
Please send feedback to sig-contributor-experience at kubernetes/community.
/close not-planned
@k8s-triage-robot: Closing this issue, marking it as "Not Planned".
In response to this:
The Kubernetes project currently lacks enough active contributors to adequately respond to all issues and PRs.
This bot triages issues according to the following rules:
- After 90d of inactivity,
lifecycle/staleis applied- After 30d of inactivity since
lifecycle/stalewas applied,lifecycle/rottenis applied- After 30d of inactivity since
lifecycle/rottenwas applied, the issue is closedYou can:
- Reopen this issue with
/reopen- Mark this issue as fresh with
/remove-lifecycle rotten- Offer to help out with Issue Triage
Please send feedback to sig-contributor-experience at kubernetes/community.
/close not-planned
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.