Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"Address not allowed" when trying to get stats summary of the node #4485

Open
VahagnMian opened this issue Apr 6, 2024 · 1 comment
Open

Comments

@VahagnMian
Copy link

Summary

Getting the "Address not allowed" response with error code 400 "BadRequest" when performing API request to kube-api server for getting node's stats
Didn't notice this issue on the v1.29 version, but when you are running an old version, f.e v1.24, and upgrading to v1.29 using snap refresh, it will not bring the required fixes

Endpoint
https://x.x.x.x:16443/api/v1/nodes/worker-node/proxy/stats/summary

What Should Happen Instead?

It should return an actual non-error response with a status code of 200 about the node's statistics

Reproduction Steps

Perform this request with 'curl' or any tool f.e postman

Can you suggest a fix?

This issue is fixed by regenerating the kubelet.crt file and adding flags to the kube-apiserver arguments file, you can run this on the machine that is running Microk8s and it should fix the problem, here is the script

https://gist.github.com/VahagnMian/3c0fc839e0767426ec9ef755a8b848a4

Are you interested in contributing with a fix?

no

@andrewf78
Copy link

Also running into this issue on v1.25. Following.

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

No branches or pull requests

2 participants