I recently updated my Docker for Desktop to latest Edge channel version: 2.1.1.0 on a Windows 10 machine. Unfortunately, after updating, Kubernetes was no longer working as it is always stuck at "Kubernetes is Starting".
I have tried the following so far.
Nothing seems to be working. How can I resolve it?
Go to Preferences , open Reset tab, and click Reset Kubernetes cluster . All object that have been created with Kubectl before that will be deleted. You can also reset docker VM image ( Reset disk image ) and all settings ( Reset to factory defaults ) or even uninstall Docker.
It usually take from 6 to 15 minutes to complete the setting depending on the factors including network speed, vpn and machine capabilities. It still has the unforeseeable factors to stop the successful configuration of Kubernetes even though adopting the above-strict steps.
What options do you have for installing Kubernetes on Windows 10? Similar to Docker, Kubernetes has constraints that you need to watch out for. Kubernetes can run Windows and Linux containers. However, you can only run Windows containers on Windows nodes and Linux containers on Linux nodes.
Can You Use Docker Without Kubernetes? The short and simple answer is yes, Docker can function without Kubernetes. You see, Docker is a standalone software designed to run containerized applications. Since container creation is part of Docker, you don't need any separate software for Docker to execute.
After hours of trying out different things, here is what finally helped me:
Restore Docker to Factory Default settings and Quit Docker for Desktop
Delete the folder C:\ProgramData\DockerDesktop\pki
(Make a backup of it just in case). Note that many have reported the folder to be located elsewhere: C:\Users\<user_name>\AppData\Local\Docker\pki
Delete the folder ~\.kube\
(Again make a backup to be safe)
Start Docker again, open Docker settings, make the necessary configuration changes (adding proxy, setting resource limits, etc..), Enable Kubernetes and let it start
Wait a while and both Docker and Kubernetes will be up now.
When you try to connect to Kubernetes using kubectl, you might face another issue like
Unable to connect to the server: x509: certificate signed by unknown authority
You can solve this by
https://kubernetes.docker.internal:6443
to https://localhost:6443
Or if you are behind a (corporate) proxy: add kubernetes.docker.internal
to NO_PROXY
(eg export NO_PROXY=kubernetes.docker.internal
), given that the proxy is configured correctly.
If this still doesn't resolve your issue, go through the logs at C:\ProgramData\DockerDesktop\log\
to debug the issue further
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With