<p>I am attempting to install kubernetes on my local Windows 10 machine via hyperv. I am getting a few errors of which I am unsure how to resolve. I've tried running kubernetes v1.8.0 as well but received the same errors.</p>

<p>Here's what I input into powershell:</p>

<p>minikube start --kubernetes-version="v1.10.11" --vm-driver="hyperv" --hyperv-virtual-switch="Minikube"</p>

<p>Here's what was returned:</p>

<p>Getting VM IP address...
Moving files into cluster...
Stopping extra container runtimes...
Machine exists, restarting cluster components...
E0201 20:22:12.487856   13792 start.go:382] Error restarting cluster:  running cmd: sudo kubeadm alpha phase certs all --config /var/lib/kubeadm.yaml: command failed: sudo kubeadm alpha phase certs all --config /var/lib/kubeadm.yaml
stdout: [certificates] Using the existing ca certificate and key.</p>

<p>stderr: failure loading apiserver certificate: the certificate is not valid yet
: Process exited with status 1
minikube failed :( exiting with error code 1</p>

user11003796
<p>It might happen due to your old minikube cache.
What I can advise you, is to delete your minikube installation along with minikube cache, and start from the scratch.</p>

<p>1) delete minikube
<code>minikube delete</code> </p>

<p>2) clean up <code>cache</code> or <code>.minikube</code> folders:</p>

<pre><code>cd C:\Users\user_name\.minikube\
Remove-Item –path C:\Users\user_name\.minikube\cache\* -recurse
</code></pre>

<p>The above will clean up the existing cache of your minikube. For me after the test is was:</p>

<pre><code>    Directory: C:\Users\User\.minikube\cache


Mode                LastWriteTime         Length Name
----                -------------         ------ ----
d-----     Mon 04.02.19   1:55 PM                iso
d-----     Mon 04.02.19   2:25 PM                v1.10.11
d-----     Mon 04.02.19   2:40 PM                v1.8.0
</code></pre>

<p>Or alternatively you can try to remove all .minikube folder.</p>

<pre><code>Remove-Item –path C:\Users\user_name\.minikube\* -recurse -force
</code></pre>

<p>3) start minikube. For me it started to work after above manipulations.</p>

<pre><code>PS C:\Windows\system32&gt; minikube start --kubernetes-version="v1.10.11" --vm-driver="hyperv" --hyperv-virtual-switch="Minikube"
Starting local Kubernetes v1.10.11 cluster...
Starting VM...
Downloading Minikube ISO
 181.48 MB / 181.48 MB [============================================] 100.00% 0s
Getting VM IP address...
Moving files into cluster...
Downloading kubeadm v1.10.11
Downloading kubelet v1.10.11
Finished Downloading kubeadm v1.10.11
Finished Downloading kubelet v1.10.11
Setting up certs...
Connecting to cluster...
Setting up kubeconfig...
Stopping extra container runtimes...
Starting cluster components...
Verifying kubelet health ...
Verifying apiserver health ...
Kubectl is now configured to use the cluster.
Loading cached images from config file.


Everything looks great. Please enjoy minikube!
</code></pre>
