0

I'm running minikube with the vbox driver. I noticed that when I get back to my workstation after it's been in sleep mode, I can't do kubectl get pods (or any other kubectl command).

Some digging and I found that the the HostOnly network adapter of the minikube machine is not working. I logged in to the machine with minikube ssh and tried to restart the interface but I'm just getting an error.

$ ifdown eth1 
ifdown: can't open '/etc/network/interfaces': No such file or directory

the only thing currently working is to minikube stop and minikube start again. But that takes long and I just want to get back to work.

any ideas on how to fix the network quicker after it's been in sleep mode? or prevent it losing the network altogether?

  • Do you get any errors while trying to execute kubectl after being in sleep mode? – Wytrzymały Wiktor Aug 3 '20 at 9:16
  • No. It justs hangs (that is what I expect after finding out that the VM's network interface is down) – Tom Klino Aug 3 '20 at 13:41
  • Could you please check if you can see the HostOnly network in Preferences -> Network of your VirtualBox after you resume your work? – Wytrzymały Wiktor Aug 5 '20 at 8:54
  • Yes I can. In the vbox settings. I also went thete to tick off and on the "cable connected" tickbox – Tom Klino Aug 5 '20 at 9:16
  • Sorry for the late response. Do you still need help with this? – Wytrzymały Wiktor Aug 24 '20 at 10:17
1

minikube start should resume the cluster after being stopped/paused.

However, there is an issue with Minikube on VirtualBox and HostOnly network adapter that sometimes causes the adapter to stop working. When that happens you can do two things:

  • Execute minikube stop and minikube start as you already tried which is a common workaround solution for this.

  • Uninstall the VirtualBox and reinstall at least version 5.0.12 that is supposed to fix this issue.

This bug is being discussed here and here if you'd like to know more details.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.