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

kubctl can't conncet to kind cluster with wsl2 #3165

Closed
misaya98 opened this issue Apr 12, 2023 · 13 comments
Closed

kubctl can't conncet to kind cluster with wsl2 #3165

misaya98 opened this issue Apr 12, 2023 · 13 comments
Labels
area/WSL2 Issues or PRs related to WSL2 kind/external upstream bugs

Comments

@misaya98
Copy link

Creating cluster "kind" ... 
 βœ“ Ensuring node image (kindest/node:v1.26.3) πŸ–Ό 
 βœ“ Preparing nodes πŸ“¦
 βœ“ Writing configuration πŸ“œ
 βœ“ Starting control-plane πŸ•ΉοΈ
 βœ“ Installing CNI πŸ”Œ
 βœ“ Installing StorageClass πŸ’Ύ
Set kubectl context to "kind-kind"
You can now use your cluster with:

kubectl cluster-info --context kind-kind

Thanks for using kind! 😊
misaya@LAPTOP-HENQBOIG:~$ kubectl cluster-info --context kind-kind
E0412 21:33:51.727333    3504 memcache.go:265] couldn't get current server API group list: Get "https://127.0.0.1:42909/api?timeout=32s": dial tcp 127.0.0.1:42909: connect: connection refused

Environment:
wsl2 ubuntu20.04
wsl version 1.2.0.0

  • kind version: (use kind version): kind version 0.18.0

  • Runtime info: (use docker info or podman info): Docker version 20.10.24, build 297e128

  • OS (e.g. from /etc/os-release): ubuntu20.04.4 LTS

  • Kubernetes version: (use kubectl version): Client Version: v1.26.3 Kustomize Version: v4.5.7

  • Any proxies or other special environment settings?: no

@misaya98 misaya98 added the kind/bug Categorizes issue or PR as related to a bug. label Apr 12, 2023
@aojea
Copy link
Contributor

aojea commented Apr 12, 2023

dial tcp 127.0.0.1:42909: connect: connection refused

the forwarding is not working there

@aojea
Copy link
Contributor

aojea commented Apr 12, 2023

@misaya98 can you check if this is the same known issue with WSL reported here ?
#3094 (comment)

@igordcard
Copy link

Starting to look like WSL2 v1.2.0.0 brought the issue back - facing the same here after the update.

@misaya98
Copy link
Author

@misaya98 can you check if this is the same known issue with WSL reported here ? #3094 (comment)

yes , it was caused by wsl part

@aojea
Copy link
Contributor

aojea commented Apr 15, 2023

@misaya98 can you check if this is the same known issue with WSL reported here ? #3094 (comment)

yes , it was caused by wsl part

/close

Thanks

@k8s-ci-robot
Copy link
Contributor

@aojea: Closing this issue.

In response to this:

@misaya98 can you check if this is the same known issue with WSL reported here ? #3094 (comment)

yes , it was caused by wsl part

/close

Thanks

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/test-infra repository.

@asheeshv
Copy link

I'm facing the same issue with wsl version 1.2 and the latest kind version. I know folks have mentioned that reverting to v1.0.3 of wsl fixes the issue for them. Are there clearly defined steps in order to revert to the wsl version?

@BenTheElder
Copy link
Member

Sorry, Currently we only have WSL2 documented by user contribution: https://kind.sigs.k8s.io/docs/user/using-wsl2/
We don't use this and there's no windows CI #1529

@asheeshv
Copy link

Thanks for the response Ben. I'll take a look and determine the way to lower the wsl2 version. I know for sure KIND has worked fine for me on my windows setup using docker-desktop.

@igordcard
Copy link

For those who come across this issue as of today, run the following on an admin shell:
wsl --update --pre-release

WSL2 v1.2.3/1.2.4 (pre-release) have the issue above fixed.

@BenTheElder
Copy link
Member

Thank you very much @igordcard! #3180 is pinned and links back to your comment

@zapho
Copy link

zapho commented Apr 20, 2023

@BenTheElder thanks for looking into this.

Unfortunately I cannot run wsl --update --pre-release as it leads to an error (To install this application you need either a Windows developer license or a sideloading-enabled system. Error code: Wsl/UpdatePackage/0x80073cff).

I will try to fix this and, if I can't, I'll wait for the next WSL release version.

I'll update the issue as soon as I can.

@BenTheElder
Copy link
Member

@zapho maybe you could downgrade instead?

I think that would be:

wsl --update --rollback

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/WSL2 Issues or PRs related to WSL2 kind/external upstream bugs
Projects
None yet
Development

No branches or pull requests

7 participants