cannot connect to Minikube on MacOS cannot connect to Minikube on MacOS kubernetes kubernetes

cannot connect to Minikube on MacOS


I ran into the same issue using my Mac and basically I uninstalled both minikube and Kubectl and installed it as follows:

  1. Installed Minikube.

curl -Lo minikube https://storage.googleapis.com/minikube/releases/v0.8.0/minikube-darwin-amd64 && chmod +x minikube && sudo mv minikube /usr/local/bin/

  1. Installed Kubectl.

curl -Lo kubectl http://storage.googleapis.com/kubernetes-release/release/v1.3.0/bin/darwin/amd64/kubectl && chmod +x kubectl && sudo mv kubectl /usr/local/bin/

  1. Start a cluster, run the command:

minikube start

  1. Minikube will also create a “minikube” context, and set it to default in kubectl. To switch back to this context later, run this command:

kubectl config use-context minikube

  1. Now to get the list of all pods run the command:

kubectl get pods --all-namespaces

Now you should be able to get the list of pods. Also make sure that you don't have a firewall within your network that blocks the connections.


I faced a similar issue on win7 when changed work environment, as you said it is working fine at home but not working at office, high chance it caused by firewall policy, cannot pass TLS verification.

Instead of waste time on troubleshoot(sometimes nothing to do if you cannot turn off firewall), if you just want to test local minikube cluster, would suggest to disable TLS verification.

This is what I have done:

# How to disable minikube TLS verification ## disable TLS verification $ VBoxManage controlvm minikube natpf1 k8s-apiserver,tcp,127.0.0.1,8443,,8443$ VBoxManage controlvm minikube natpf1 k8s-dashboard,tcp,127.0.0.1,30000,,30000$ kubectl config set-cluster minikube-vpn --server=https://127.0.0.1:8443 --insecure-skip-tls-verify$ kubectl config set-context minikube-vpn --cluster=minikube-vpn --user=minikube$ kubectl config use-context minikube-vpn## test kubectl$ kubectl get pods## enable local docker client$ VBoxManage controlvm minikube natpf1 k8s-docker,tcp,127.0.0.1,2374,,2376$ eval $(minikube docker-env) $ unset DOCKER_TLS_VERIFY$ export DOCKER_HOST="tcp://127.0.0.1:2374"$ alias docker='docker --tls' ## test local docker client $ docker ps ## test minikube dashboardcurl http://127.0.0.1:30000

Also I make a small script for this for your reference.

Hope it is helpful for you.


You need to just restart minikube. Sometimes I have this problem when my computer has been off for a while. I don't think you need to reinstall anything.

  1. First verify you are in the correct context

    $ kubectl config current-contextminikube

  2. Check Minikube status (status should show "Running", mine below showed "Saved")

    $ minikube statusminikube: Savedcluster: kubectl:

  3. Restart minikube

    $ minikube startStarting local Kubernetes v1.8.0 cluster...Starting VM...Getting VM IP address...Moving files into cluster...Setting up certs...Connecting to cluster...Setting up kubeconfig...Starting cluster components...Kubectl is now configured to use the cluster.

  4. Verify it is running (This is what you should see)

    $ minikube statusminikube: Runningcluster: Runningkubectl: Correctly Configured: pointing to minikube-vm at 192.168.99.100