-
Notifications
You must be signed in to change notification settings - Fork 4.9k
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
minikube start with hyper-v won't resolve guest ip-address #1945
Comments
It looks like hv_kvp_daemon isn't running by default in the vm. This is the daemon that allows the guest os to communicate with the host. If you start it manually (/usr/sbin/hv_kvp_daemon), the ip shows up in hyperv manager. I think its a bug that it isn't starting by default. |
I can confirm this with 0.22.1 and hyperv on windows 10 Tried starting hv_kvp_daemon as suggested but the vm still doesn't seem to get an ip any suggestions? |
I obtained the same result running the daemon, the ip address isn't returned |
Does anyone know if this is a new bug - is there an earlier version that works? |
Same issue here. minikube vm starts, external virtual switch configured OK, and I have an IP address that I can verify from inside the VM. From outside, I got the powershell command that minikube is trying to execute via procmon, and it matches the same posted in the first message of this issue. Also, kvp service failed to start (as verified with systemctl status hv_kvp_daemon.service). The output says that KVP service started and one second later process exited, status=1/FAILURE. Unit entered failed state. I've studied how systemctl works, found the command line, ran it and it worked. Tried to start the hv-kvp manually using systemctl and it worked too. After some seconds, I could see the IP address in the powershell command... but minikube still hangs on the "Waiting for SSH to be available". with Procmon, I found that minikube is looping trying to connect to port 22 on my own address. As a test, tried to run again using a new, different switch. Added an Internal switch (in hyper-v world, this means no internet, vm and physical machine can communicate) and set static IPs from my physical machine and the VM (192.168.20.1 an 2, respectively). Then, ran the minikube start command again. Crossed that point, but now got looping while configuring the VM... looks like docker service doesn't start. Now it looks like I have a different problem, and will open a different issue later. But I hope this troubleshooting info helps your case too. |
thanks I get something similar after starting the hv_kvp daemon using systemctl as you suggest This is the output I see in powershell admin session
|
It works with minikube version |
Confirmed working. Thank you very much, guys! |
seems I have the same issue with v0.24.1 Error starting host: Error starting stopped host: exit status 1 |
I have the same problem |
The same. Works with minikube 0.22.2 but doesn't for 0.24.1 (hangs at "starting vm"). |
The same problem with v0.24.1. Win10 |
I have the issue with 0.24.1,0.22.2 and 0.20.0 on windows 10 md or psheel in admin - none of thme works for me
or PowerShell
|
I am facing the error too on a Windows 10 Pro machine. I have the same log output like @cforce. I tested with 0.24.1, 0.22.2, and 0.19.1. In addition, I checked whether /usr/sbin/hv_kvp_daemon is running (as suggested by @mikemcgo). It is running. The first mention of this bug/behaviour re-appearing was 2018-01-05 - over a month after 0.24.1 was released. This could be an indicator that a Windows Update or similar triggered this. |
I have the same issue described here. `Starting local Kubernetes v1.9.0 cluster... Retrying. |
@dbovenzi Make sure you run PowerShell as administrator. Also add |
Also running into this issue. Minikube version v0.25.0 I get these logs by running this command: minikube start --vm-driver="hyperv" --memory=4096 --cpus=4 --hyperv-virtual-switch="New Virtual
Switch" --v=7 --alsologtostderr W0317 23:56:24.407104 12708 root.go:148] Error reading config file at C:\Program Files\Docker\Minikube.minikube\config\config.json: open C:\Program Files\Docker\Minikube.minikube\config\config.json: The system cannot find the file specified. [stderr =====>] : [stderr =====>] : [stderr =====>] : [stderr =====>] : [stderr =====>] : [stderr =====>] : ComputerName : DESKTOP-9SMC76M [stderr =====>] : minikube Off 0 0 00:00:00 Operating normally 8.2 [stderr =====>] : [stderr =====>] : [stderr =====>] : |
Then it just seems to repeatedly check for an ip address, but gets nothing. Could this be something to do with my DHCP on my router not giving up an ip for some reason? |
I had this same trouble on my machine. After some troubleshooting and head banging, it became apparent that the external network adapter had an ethernet adapter selected that was not connected to a network. (ethernet selected, instead of the wireless adapter). Of course an IP wont be allocated on an external network if none is connected. Once the connected wireless adapter was selected (an adapter actually connected to a DHCP network), all was good. |
Same issue on: Windows 10 Pro |
Same issue on: Windows 10 Pro |
Same issue on: Windows 10 Pro |
I would suggest enable K8s from Windows Docker (desktop app) and use 'docker-for-desktop' as Context. |
@suvasishm I have tried that as well but the kubernetes option in docker never starts up and runs |
@bretcj7 Is virtualization enabled for your system? |
Same issue on: Windows 10 Pro forever stopping after this...
|
Hung on: Works for me when changed: |
I was able to resolve this issue by creating an external virtual switch instead of using an internal one in hyper-V. It seemed somehow the minikube VM was not getting the IP address from the in built DHCP in my WiFi router. So creating an external switch created a direct bridge between the VM and router's DHCP. If you get into the same IP loop you would see on your machine DNS cache (ipconfig /displaydns) for minikube is not changing. It will remain the same no matter how many times you try 'minikube delete' and 'minikube start' which tell you that IP is not getting assigned to new VM from DHCP and hence not getting updated in DNS cache of host OS either. I took a network capture when I ran it with external switch pointed to Wifi. 625 6:49:22 PM 4/11/2020 10.5034268 svchost.exe 0.0.0.0 255.255.255.255 DHCP DHCP:Request, MsgType = DISCOVER, TransactionID = 0xDEF6CA67 {DHCP:112, UDP:114, IPv4:113} As you can see here minikube VM got offered 192.168.17.130 from WiFi's DHCP which later on reflected in DNS cache as well. Taking a network capture and filtering the traffic with DHCP at the time of issue will help you narrow down the problem |
BUG REPORT
Executing
minikube start --vm-driver="hyperv" --hyperv-virtual-switch="ext1"
, where ext1 is my external virtual switch on hyper-v, the system hangs on "Starting VM" message.Checking the log it seems that the powershell command used to retireve the ip address of the guest machine don't returns any value (i tested running the command on a separate powershell with the same result).
I obtained the same result on two different machines.
Environment:
Minikube version: v0.22.0
Output of
minikube logs
:The text was updated successfully, but these errors were encountered: