Skip to content

Conversation

@ardentperf
Copy link
Contributor

Disable Grafana Live feature (max_connections=0) to prevent WebSocket connection buildup that causes kubectl port-forward timeout errors. Firefox creates multiple persistent connections that exhausts the port-forward stream multiplexer. This causes grafana to quickly become unresponsive in the browser and the following errors to be thrown:

kubectl port-forward service/grafana-service 3000:3000 -n grafana --context kind-k8s-eu
...
Handling connection for 3000
E0108 03:26:47.977808  812338 portforward.go:351] "Unhandled Error" err="error creating error stream for port 3000 -> 3000: Timeout occurred"
E0108 03:26:47.979969  812338 portforward.go:374] "Unhandled Error" err="error creating forwarding stream for port 3000 -> 3000: Timeout occurred"
E0108 03:26:56.184349  812338 portforward.go:374] "Unhandled Error" err="error creating forwarding stream for port 3000 -> 3000: Timeout occurred"
E0108 03:27:08.983705  812338 portforward.go:374] "Unhandled Error" err="error creating forwarding stream for port 3000 -> 3000: Timeout occurred"
E0108 03:27:09.537632  812338 portforward.go:351] "Unhandled Error" err="error creating error stream for port 3000 -> 3000: Timeout occurred"
Handling connection for 3000
Handling connection for 3000
E0108 03:27:09.556133  812338 portforward.go:374] "Unhandled Error" err="error creating forwarding stream for port 3000 -> 3000: Timeout occurred"
E0108 03:27:10.928121  812338 portforward.go:351] "Unhandled Error" err="error creating error stream for port 3000 -> 3000: Timeout occurred"
E0108 03:27:10.930587  812338 portforward.go:374] "Unhandled Error" err="error creating forwarding stream for port 3000 -> 3000: Timeout occurred"
Handling connection for 3000
E0108 03:27:12.022278  812338 portforward.go:374] "Unhandled Error" err="error creating forwarding stream for port 3000 -> 3000: Timeout occurred"
Handling connection for 3000
Handling connection for 3000

Docs:
https://grafana.com/docs/grafana/latest/setup-grafana/configure-grafana/#live

@ardentperf ardentperf requested a review from a team as a code owner January 8, 2026 04:42
Disable Grafana Live feature (max_connections=0) to prevent WebSocket
connection buildup that causes kubectl port-forward timeout errors.
Firefox was creating multiple persistent connections that exhausted
the port-forward stream multiplexer. This caused grafana to quickly
become unresponsive in the browser. Disabling Grafana Live fixes
the issue.

Docs:
https://grafana.com/docs/grafana/latest/setup-grafana/configure-grafana/#live

Signed-off-by: Jeremy Schneider <[email protected]>
@ardentperf
Copy link
Contributor Author

I still occasionally get the same errors even with this patch, but it's much better than before. Without the patch grafana would completely break but that doesn't seem to be happening with this patch so far.

Add note explaining why Grafana Live is disabled (max_connections: 0)
to prevent WebSocket connection buildup that exhausts kubectl
port-forward streams and causes timeout errors.

Signed-off-by: Marco Nenciarini <[email protected]>
@mnencia mnencia merged commit a6ee6d1 into cloudnative-pg:main Jan 14, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants