Minikube: hyperv: Unable to start VM: start: exit status 1 / panic: runtime error: index out of range

Created on 29 May 2019  路  12Comments  路  Source: kubernetes/minikube

! Ignoring --vm-driver=virtualbox, as the existing "minikube" VM was created using the hyperv driver.
! To switch drivers, you may create a new VM using minikube start -p <name> --vm-driver=virtualbox
! Alternatively, you may delete the existing VM using minikube delete -p minikube

  • Restarting existing hyperv VM for "minikube" ...
    E0529 15:48:40.579626 5484 start.go:529] StartHost: start: exit status 1

X Unable to start VM: start: exit status 1

chyperv prioritawaiting-more-evidence triagneeds-information

Most helpful comment

@sgiovinetti @sneevand I was able to bypass the issue by deleting the .minikube folder

could you please try to delete the folder under C:\Users\medya\.minikube and do minikube delete and minikube start ?

All 12 comments

Do you mind sharing the output of:

minikube start --alsologtostderr -v=8

Thanks!

trying to install in windows 2012 r2 server

I0530 07:58:06.368967 6744 notify.go:128] Checking for updates...

  • minikube v1.1.0 on windows (amd64)
    I0530 07:58:06.879295 6744 downloader.go:60] Not caching ISO, using https://storage.googleapis.com/minikube/iso/minik
    ube-v1.1.0.iso
    I0530 07:58:06.880293 6744 start.go:721] Saving config:
    {
    "MachineConfig": {
    "MinikubeISO": "https://storage.googleapis.com/minikube/iso/minikube-v1.1.0.iso",
    "Memory": 2048,
    "CPUs": 2,
    "DiskSize": 20000,
    "VMDriver": "hyperv",
    "ContainerRuntime": "docker",
    "HyperkitVpnKitSock": "",
    "HyperkitVSockPorts": [],
    "XhyveDiskDriver": "ahci-hd",
    "DockerEnv": null,
    "InsecureRegistry": null,
    "RegistryMirror": null,
    "HostOnlyCIDR": "192.168.99.1/24",
    "HypervVirtualSwitch": "",
    "KvmNetwork": "default",
    "DockerOpt": null,
    "DisableDriverMounts": false,
    "NFSShare": [],
    "NFSSharesRoot": "/nfsshares",
    "UUID": "",
    "GPU": false,
    "Hidden": false,
    "NoVTXCheck": false
    },
    "KubernetesConfig": {
    "KubernetesVersion": "v1.14.2",
    "NodeIP": "",
    "NodePort": 8443,
    "NodeName": "minikube",
    "APIServerName": "minikubeCA",
    "APIServerNames": null,
    "APIServerIPs": null,
    "DNSDomain": "cluster.local",
    "ContainerRuntime": "docker",
    "CRISocket": "",
    "NetworkPlugin": "",
    "FeatureGates": "",
    "ServiceCIDR": "10.96.0.0/12",
    "ImageRepository": "",
    "ExtraOptions": null,
    "ShouldLoadCachedImages": true,
    "EnableDefaultCNI": false
    }
    }
    I0530 07:58:06.880293 6744 cache_images.go:307] Attempting to cache image: gcr.io/k8s-minikube/storage-provisioner:v1
    .8.1 at C:\Users\xyz.minikube\cache\images\gcr.io\k8s-minikube\storage-provisioner_v1.8.1
    I0530 07:58:06.880293 6744 cache_images.go:307] Attempting to cache image: k8s.gcr.io/kube-proxy:v1.14.2 at C:\Users\
    xyz.minikube\cache\images\k8s.gcr.io\kube-proxy_v1.14.2
    I0530 07:58:06.880293 6744 cache_images.go:307] Attempting to cache image: k8s.gcr.io/kube-scheduler:v1.14.2 at C:\Us
    ers\xyz.minikube\cache\images\k8s.gcr.io\kube-scheduler_v1.14.2
    I0530 07:58:06.880293 6744 cache_images.go:307] Attempting to cache image: k8s.gcr.io/kube-controller-manager:v1.14.2
    at C:\Users\xyz.minikube\cache\images\k8s.gcr.io\kube-controller-manager_v1.14.2
    I0530 07:58:06.880293 6744 cache_images.go:307] Attempting to cache image: k8s.gcr.io/kube-apiserver:v1.14.2 at C:\Us
    ers\xyz.minikube\cache\images\k8s.gcr.io\kube-apiserver_v1.14.2
    I0530 07:58:06.880293 6744 cache_images.go:307] Attempting to cache image: k8s.gcr.io/pause:3.1 at C:\Users\dondapati
    .navin1.minikube\cache\images\k8s.gcr.io\pause_3.1
    I0530 07:58:06.880293 6744 cache_images.go:307] Attempting to cache image: k8s.gcr.io/k8s-dns-kube-dns-amd64:1.14.13
    at C:\Users\xyz.minikube\cache\images\k8s.gcr.io\k8s-dns-kube-dns-amd64_1.14.13
    I0530 07:58:06.880293 6744 cache_images.go:307] Attempting to cache image: k8s.gcr.io/k8s-dns-dnsmasq-nanny-amd64:1.1
    4.13 at C:\Users\xyz.minikube\cache\images\k8s.gcr.io\k8s-dns-dnsmasq-nanny-amd64_1.14.13
    I0530 07:58:06.880293 6744 cache_images.go:307] Attempting to cache image: k8s.gcr.io/k8s-dns-sidecar-amd64:1.14.13 a
    t C:\Users\xyz.minikube\cache\images\k8s.gcr.io\k8s-dns-sidecar-amd64_1.14.13
    I0530 07:58:06.880293 6744 cache_images.go:307] Attempting to cache image: k8s.gcr.io/etcd:3.3.10 at C:\Users\dondapa
    ti.navin1.minikube\cache\images\k8s.gcr.io\etcd_3.3.10
    I0530 07:58:06.880293 6744 cache_images.go:307] Attempting to cache image: k8s.gcr.io/coredns:1.3.1 at C:\Users\donda
    pati.navin1.minikube\cache\images\k8s.gcr.io\coredns_1.3.1
    I0530 07:58:06.880293 6744 cache_images.go:307] Attempting to cache image: k8s.gcr.io/kubernetes-dashboard-amd64:v1.1
    0.1 at C:\Users\xyz.minikube\cache\images\k8s.gcr.io\kubernetes-dashboard-amd64_v1.10.1
    I0530 07:58:06.880293 6744 cache_images.go:307] Attempting to cache image: k8s.gcr.io/kube-addon-manager:v9.0 at C:\U
    sers\xyz.minikube\cache\images\k8s.gcr.io\kube-addon-manager_v9.0
    I0530 07:58:06.887295 6744 cluster.go:76] Machine does not exist... provisioning new machine
    I0530 07:58:07.001312 6744 cluster.go:77] Provisioning machine with config: {MinikubeISO:https://storage.googleapis.c
    om/minikube/iso/minikube-v1.1.0.iso Memory:2048 CPUs:2 DiskSize:20000 VMDriver:hyperv ContainerRuntime:docker HyperkitVp
    nKitSock: HyperkitVSockPorts:[] XhyveDiskDriver:ahci-hd DockerEnv:[] InsecureRegistry:[] RegistryMirror:[] HostOnlyCIDR:
    192.168.99.1/24 HypervVirtualSwitch: KvmNetwork:default Downloader:{} DockerOpt:[] DisableDriverMounts:false NFSShare:[]
    NFSSharesRoot:/nfsshares UUID: GPU:false Hidden:false NoVTXCheck:false}
  • Creating hyperv VM (CPUs=2, Memory=2048MB, Disk=20000MB) ...
    Reading certificate data from C:\Users\xyz.minikube\certs\ca.pem
    Decoding PEM data...
    Parsing certificate...
    Reading certificate data from C:\Users\xyz.minikube\certs\cert.pem
    Decoding PEM data...
    Parsing certificate...
    [executing ==>] : C:\Windows\System32\WindowsPowerShellv1.0\powershell.exe -NoProfile -NonInteractive @(Get-Module -Lis
    tAvailable hyper-v).Name | Get-Unique
    2019/05/30 07:58:07 Unable to read "C:\Users\xyz\.docker\config.json": open C:\Users\xyz.
    docker\config.json: The system cannot find the path specified.
    2019/05/30 07:58:07 No matching credentials were found, falling back on anonymous
    2019/05/30 07:58:07 Unable to read "C:\Users\xyz\.docker\config.json": open C:\Users\xyz.
    docker\config.json: The system cannot find the path specified.
    2019/05/30 07:58:07 No matching credentials were found, falling back on anonymous
    I0530 07:58:07.093138 6744 cache_images.go:304]
    2019/05/30 07:58:07 Unable to read "C:\Users\xyz\.docker\config.json": open C:\Users\xyz.
    docker\config.json: The system cannot find the path specified.
    2019/05/30 07:58:07 No matching credentials were found, falling back on anonymous
    2019/05/30 07:58:07 Unable to read "C:\Users\xyz\.docker\config.json": open C:\Users\xyz.
    docker\config.json: The system cannot find the path specified.
    2019/05/30 07:58:07 No matching credentials were found, falling back on anonymous
    2019/05/30 07:58:07 Unable to read "C:\Users\xyz\.docker\config.json": open C:\Users\xyz.
    docker\config.json: The system cannot find the path specified.
    2019/05/30 07:58:07 No matching credentials were found, falling back on anonymous
    2019/05/30 07:58:07 Unable to read "C:\Users\xyz\.docker\config.json": open C:\Users\xyz.
    docker\config.json: The system cannot find the path specified.
    2019/05/30 07:58:07 No matching credentials were found, falling back on anonymous
    2019/05/30 07:58:07 Unable to read "C:\Users\xyz\.docker\config.json": open C:\Users\xyz.
    docker\config.json: The system cannot find the path specified.
    2019/05/30 07:58:07 No matching credentials were found, falling back on anonymous
    2019/05/30 07:58:07 Unable to read "C:\Users\xyz\.docker\config.json": open C:\Users\xyz.
    docker\config.json: The system cannot find the path specified.
    2019/05/30 07:58:07 No matching credentials were found, falling back on anonymous
    2019/05/30 07:58:07 Unable to read "C:\Users\xyz\.docker\config.json": open C:\Users\xyz.
    docker\config.json: The system cannot find the path specified.
    2019/05/30 07:58:07 No matching credentials were found, falling back on anonymous
    2019/05/30 07:58:07 Unable to read "C:\Users\xyz\.docker\config.json": open C:\Users\xyz.
    docker\config.json: The system cannot find the path specified.
    2019/05/30 07:58:07 No matching credentials were found, falling back on anonymous
    2019/05/30 07:58:07 Unable to read "C:\Users\xyz\.docker\config.json": open C:\Users\xyz.
    docker\config.json: The system cannot find the path specified.
    2019/05/30 07:58:07 No matching credentials were found, falling back on anonymous
    2019/05/30 07:58:07 Unable to read "C:\Users\xyz\.docker\config.json": open C:\Users\xyz.
    docker\config.json: The system cannot find the path specified.
    2019/05/30 07:58:07 No matching credentials were found, falling back on anonymous
    I0530 07:58:07.622146 6744 cache_images.go:331] OPENING: \?\Volume{4b812149-a9d2-11e7-80d6-806e6f6e6963}\Users\dond
    apati.navin1.minikube\cache\images\k8s.gcr.io\kube-addon-manager_v9.0
    I0530 07:58:07.625143 6744 cache_images.go:331] OPENING: \?\Volume{4b812149-a9d2-11e7-80d6-806e6f6e6963}\Users\dond
    apati.navin1.minikube\cache\images\k8s.gcr.io\kube-proxy_v1.14.2
    I0530 07:58:07.640916 6744 cache_images.go:331] OPENING: \?\Volume{4b812149-a9d2-11e7-80d6-806e6f6e6963}\Users\dond
    apati.navin1.minikube\cache\images\k8s.gcr.io\coredns_1.3.1
    I0530 07:58:07.690691 6744 cache_images.go:331] OPENING: \?\Volume{4b812149-a9d2-11e7-80d6-806e6f6e6963}\Users\dond
    apati.navin1.minikube\cache\images\k8s.gcr.io\kubernetes-dashboard-amd64_v1.10.1
    I0530 07:58:07.698639 6744 cache_images.go:331] OPENING: \?\Volume{4b812149-a9d2-11e7-80d6-806e6f6e6963}\Users\dond
    apati.navin1.minikube\cache\images\k8s.gcr.io\k8s-dns-sidecar-amd64_1.14.13
    I0530 07:58:07.755265 6744 cache_images.go:331] OPENING: \?\Volume{4b812149-a9d2-11e7-80d6-806e6f6e6963}\Users\dond
    apati.navin1.minikube\cache\images\k8s.gcr.io\kube-apiserver_v1.14.2
    I0530 07:58:07.755265 6744 cache_images.go:331] OPENING: \?\Volume{4b812149-a9d2-11e7-80d6-806e6f6e6963}\Users\dond
    apati.navin1.minikube\cache\images\k8s.gcr.io\etcd_3.3.10
    I0530 07:58:07.757266 6744 cache_images.go:331] OPENING: \?\Volume{4b812149-a9d2-11e7-80d6-806e6f6e6963}\Users\dond
    apati.navin1.minikube\cache\images\k8s.gcr.io\kube-scheduler_v1.14.2
    I0530 07:58:07.759266 6744 cache_images.go:331] OPENING: \?\Volume{4b812149-a9d2-11e7-80d6-806e6f6e6963}\Users\dond
    apati.navin1.minikube\cache\images\k8s.gcr.io\k8s-dns-kube-dns-amd64_1.14.13
    I0530 07:58:07.771266 6744 cache_images.go:331] OPENING: \?\Volume{4b812149-a9d2-11e7-80d6-806e6f6e6963}\Users\dond
    apati.navin1.minikube\cache\images\gcr.io\k8s-minikube\storage-provisioner_v1.8.1
    I0530 07:58:07.833593 6744 cache_images.go:331] OPENING: \?\Volume{4b812149-a9d2-11e7-80d6-806e6f6e6963}\Users\dond
    apati.navin1.minikube\cache\images\k8s.gcr.io\kube-controller-manager_v1.14.2
    [stdout =====>] :
    [stderr =====>] :
    panic: runtime error: index out of range

goroutine 1 [running]:
github.com/docker/machine/drivers/hyperv.hypervAvailable(0xc000553980, 0xc00056d380)
/go/pkg/mod/github.com/docker/[email protected]/drivers/hyperv/powershell.go:64 +0x101
github.com/docker/machine/drivers/hyperv.(Driver).PreCreateCheck(0xc000409b60, 0x0, 0x0)
/go/pkg/mod/github.com/docker/[email protected]/drivers/hyperv/hyperv.go:168 +0x3b
k8s.io/minikube/pkg/minikube/machine.(
LocalClient).Create(0xc00005f5c0, 0xc000409bc0, 0xc00054e928, 0x0)
/app/pkg/minikube/machine/client.go:211 +0x36b
k8s.io/minikube/pkg/minikube/cluster.createHost(0x173a6e0, 0xc00005f5c0, 0xc00008f700, 0x3f, 0x800, 0x2, 0x4e20, 0xc0000
72c50, 0x6, 0x14e84b2, ...)
/app/pkg/minikube/cluster/cluster.go:311 +0x63d
k8s.io/minikube/pkg/minikube/cluster.StartHost(0x173a6e0, 0xc00005f5c0, 0xc00008f700, 0x3f, 0x800, 0x2, 0x4e20, 0xc00007
2c50, 0x6, 0x14e84b2, ...)
/app/pkg/minikube/cluster/cluster.go:78 +0x10a2
k8s.io/minikube/cmd/minikube/cmd.startHost.func1(0xc0000225a0, 0x30)
/app/cmd/minikube/cmd/start.go:527 +0xb6
k8s.io/minikube/pkg/util.RetryAfter(0x3, 0xc0000225a0, 0x77359400, 0x887f00, 0x0)
/app/pkg/util/utils.go:116 +0x99
k8s.io/minikube/cmd/minikube/cmd.startHost(0x173a6e0, 0xc00005f5c0, 0xc00008f700, 0x3f, 0x800, 0x2, 0x4e20, 0xc000072c50
, 0x6, 0x14e84b2, ...)
/app/cmd/minikube/cmd/start.go:533 +0x140
k8s.io/minikube/cmd/minikube/cmd.runStart(0x2275000, 0xc00012f2c0, 0x0, 0x2)
/app/cmd/minikube/cmd/start.go:223 +0x46f
github.com/spf13/cobra.(Command).execute(0x2275000, 0xc00012f180, 0x2, 0x2, 0x2275000, 0xc00012f180)
/go/pkg/mod/github.com/spf13/[email protected]/command.go:757 +0x2b5
github.com/spf13/cobra.(
Command).ExecuteC(0x2274420, 0x1, 0x12f68e0, 0xc0000729a8)
/go/pkg/mod/github.com/spf13/[email protected]/command.go:843 +0x2f3
github.com/spf13/cobra.(*Command).Execute(...)
/go/pkg/mod/github.com/spf13/[email protected]/command.go:791
k8s.io/minikube/cmd/minikube/cmd.Execute()
/app/cmd/minikube/cmd/root.go:103 +0x35
main.main()
/app/cmd/minikube/main.go:44 +0xd6

This issue appears to be a duplicate of #2954, so I will close this one so that we may centralize the content relating to the issue. If you feel that this issue is not in fact a duplicate, please feel free to re-open it.

Thank you for reporting this!

The root cause here is that HyperV has not been setup on the host. You may want to try the virtualbox driver instead.

Please reopen the bug is still present.
Here below the log. It seems that minikube skip to create the VM even if it should be. (No minikube VM is present in Hv since it was delete before using minikube delete).

minikube start --vm-driver hyperv --hyperv-virtual-switch "MiniKube" --alsologtostderr -v=8
I0605 10:05:31.048076 20616 notify.go:128] Checking for updates...

  • minikube v1.1.0 on windows (amd64)
    I0605 10:05:31.439988 20616 downloader.go:60] Not caching ISO, using https://storage.googleapis.com/minikube/iso/minikube-v1.1.0.iso
    I0605 10:05:31.440737 20616 start.go:721] Saving config:
    {
    "MachineConfig": {
    "MinikubeISO": "https://storage.googleapis.com/minikube/iso/minikube-v1.1.0.iso",
    "Memory": 2048,
    "CPUs": 2,
    "DiskSize": 20000,
    "VMDriver": "hyperv",
    "ContainerRuntime": "docker",
    "HyperkitVpnKitSock": "",
    "HyperkitVSockPorts": [],
    "XhyveDiskDriver": "ahci-hd",
    "DockerEnv": null,
    "InsecureRegistry": null,
    "RegistryMirror": null,
    "HostOnlyCIDR": "192.168.99.1/24",
    "HypervVirtualSwitch": "MiniKube",
    "KvmNetwork": "default",
    "DockerOpt": null,
    "DisableDriverMounts": false,
    "NFSShare": [],
    "NFSSharesRoot": "/nfsshares",
    "UUID": "",
    "GPU": false,
    "Hidden": false,
    "NoVTXCheck": false
    },
    "KubernetesConfig": {
    "KubernetesVersion": "v1.14.2",
    "NodeIP": "",
    "NodePort": 8443,
    "NodeName": "minikube",
    "APIServerName": "minikubeCA",
    "APIServerNames": null,
    "APIServerIPs": null,
    "DNSDomain": "cluster.local",
    "ContainerRuntime": "docker",
    "CRISocket": "",
    "NetworkPlugin": "",
    "FeatureGates": "",
    "ServiceCIDR": "10.96.0.0/12",
    "ImageRepository": "",
    "ExtraOptions": null,
    "ShouldLoadCachedImages": true,
    "EnableDefaultCNI": false
    }
    }
    I0605 10:05:31.442731 20616 cache_images.go:307] Attempting to cache image: k8s.gcr.io/kube-scheduler:v1.14.2 at F:.minikube\cache\images\k8s.gcr.io\kube-scheduler_v1.14.2
    I0605 10:05:31.443733 20616 cache_images.go:307] Attempting to cache image: k8s.gcr.io/kube-controller-manager:v1.14.2 at F:.minikube\cache\images\k8s.gcr.io\kube-controller-manager_v1.14.2
    I0605 10:05:31.445732 20616 cache_images.go:307] Attempting to cache image: k8s.gcr.io/k8s-dns-kube-dns-amd64:1.14.13 at F:.minikube\cache\images\k8s.gcr.io\k8s-dns-kube-dns-amd64_1.14.13
    I0605 10:05:31.443733 20616 cache_images.go:307] Attempting to cache image: k8s.gcr.io/kube-proxy:v1.14.2 at F:.minikube\cache\images\k8s.gcr.io\kube-proxy_v1.14.2
    I0605 10:05:31.445732 20616 cache_images.go:307] Attempting to cache image: k8s.gcr.io/kubernetes-dashboard-amd64:v1.10.1 at F:.minikube\cache\images\k8s.gcr.io\kubernetes-dashboard-amd64_v1.10.1
    I0605 10:05:31.443733 20616 cache_images.go:307] Attempting to cache image: k8s.gcr.io/k8s-dns-sidecar-amd64:1.14.13 at F:.minikube\cache\images\k8s.gcr.io\k8s-dns-sidecar-amd64_1.14.13
    I0605 10:05:31.444741 20616 cache_images.go:307] Attempting to cache image: k8s.gcr.io/kube-apiserver:v1.14.2 at F:.minikube\cache\images\k8s.gcr.io\kube-apiserver_v1.14.2
    I0605 10:05:31.444741 20616 cache_images.go:307] Attempting to cache image: k8s.gcr.io/coredns:1.3.1 at F:.minikube\cache\images\k8s.gcr.io\coredns_1.3.1
    I0605 10:05:31.444741 20616 cache_images.go:307] Attempting to cache image: k8s.gcr.io/pause:3.1 at F:.minikube\cache\images\k8s.gcr.io\pause_3.1
    I0605 10:05:31.444741 20616 cache_images.go:307] Attempting to cache image: k8s.gcr.io/etcd:3.3.10 at F:.minikube\cache\images\k8s.gcr.io\etcd_3.3.10
    I0605 10:05:31.444741 20616 cache_images.go:307] Attempting to cache image: k8s.gcr.io/k8s-dns-dnsmasq-nanny-amd64:1.14.13 at F:.minikube\cache\images\k8s.gcr.io\k8s-dns-dnsmasq-nanny-amd64_1.14.13
    I0605 10:05:31.445732 20616 cache_images.go:307] Attempting to cache image: k8s.gcr.io/kube-addon-manager:v9.0 at F:.minikube\cache\images\k8s.gcr.io\kube-addon-manager_v9.0
    I0605 10:05:31.442731 20616 cache_images.go:307] Attempting to cache image: gcr.io/k8s-minikube/storage-provisioner:v1.8.1 at F:.minikube\cache\images\gcr.io\k8s-minikube\storage-provisioner_v1.8.1
    I0605 10:05:31.513733 20616 cluster.go:81] Skipping create...Using existing machine configuration
  • Tip: Use 'minikube start -p ' to create a new cluster, or 'minikube delete' to delete this one.
    [executing ==>] : C:\WINDOWS\System32\WindowsPowerShellv1.0\powershell.exe -NoProfile -NonInteractive ( Hyper-V\Get-VM minikube ).state
    I0605 10:05:32.715624 20616 cache_images.go:304]
    I0605 10:05:32.734628 20616 cache_images.go:304]
    I0605 10:05:32.839622 20616 cache_images.go:304]
    I0605 10:05:32.886626 20616 cache_images.go:304]
    I0605 10:05:32.891629 20616 cache_images.go:304]
    I0605 10:05:32.900623 20616 cache_images.go:304]
    I0605 10:05:32.904625 20616 cache_images.go:304]
    I0605 10:05:32.933626 20616 cache_images.go:304]
    I0605 10:05:32.970630 20616 cache_images.go:304]
    I0605 10:05:32.970630 20616 cache_images.go:304]
    I0605 10:05:33.015622 20616 cache_images.go:304]
    I0605 10:05:33.032622 20616 cache_images.go:304]
    [stdout =====>] :
    [stderr =====>] : Hyper-V\Get-VM : Hyper-V was unable to find a virtual machine with name "minikube".

E0605 10:05:35.578756 20616 start.go:529] StartHost: start: exit status 1
I0605 10:05:35.589747 20616 utils.go:122] non-retriable error: start: exit status 1
I0605 10:05:35.586748 20616 cache_images.go:304]
W0605 10:05:35.589747 20616 exit.go:100] Unable to start VM: start: exit status 1

X Unable to start VM: start: exit status 1

I faced this issue in hyper on windows 10:

it seems to be minikube delete not working correctly,
minikube thinks there is a minikube vm on hyperv but there isnt any !

The exact command to reproduce the issue:
minikube delete

and

minikube start --vm-driver hyperv --hyperv-virtual-switch=primary-virtual-switch

The full output of the command that failed (start output):

minikube start --vm-driver hyperv --hyperv-virtual-switch=primary-virtual-swtich --alsologtostderr -v=8
I0605 14:40:36.914362     984 notify.go:128] Checking for updates...
* minikube v1.1.0 on windows (amd64)
I0605 14:40:37.091641     984 downloader.go:60] Not caching ISO, using https://storage.googleapis.com/minikube/iso/minikube-v1.1.0.iso
I0605 14:40:37.094636     984 start.go:721] Saving config:
{
    "MachineConfig": {
        "MinikubeISO": "https://storage.googleapis.com/minikube/iso/minikube-v1.1.0.iso",
        "Memory": 2048,
        "CPUs": 2,
        "DiskSize": 20000,
        "VMDriver": "hyperv",
        "ContainerRuntime": "docker",
        "HyperkitVpnKitSock": "",
        "HyperkitVSockPorts": [],
        "XhyveDiskDriver": "ahci-hd",
        "DockerEnv": null,
        "InsecureRegistry": null,
        "RegistryMirror": null,
        "HostOnlyCIDR": "192.168.99.1/24",
        "HypervVirtualSwitch": "primary-virtual-swtich",
        "KvmNetwork": "default",
        "DockerOpt": null,
        "DisableDriverMounts": false,
        "NFSShare": [],
        "NFSSharesRoot": "/nfsshares",
        "UUID": "",
        "GPU": false,
        "Hidden": false,
        "NoVTXCheck": false
    },
    "KubernetesConfig": {
        "KubernetesVersion": "v1.14.2",
        "NodeIP": "",
        "NodePort": 8443,
        "NodeName": "minikube",
        "APIServerName": "minikubeCA",
        "APIServerNames": null,
        "APIServerIPs": null,
        "DNSDomain": "cluster.local",
        "ContainerRuntime": "docker",
        "CRISocket": "",
        "NetworkPlugin": "",
        "FeatureGates": "",
        "ServiceCIDR": "10.96.0.0/12",
        "ImageRepository": "",
        "ExtraOptions": null,
        "ShouldLoadCachedImages": true,
        "EnableDefaultCNI": false
    }
}
I0605 14:40:37.100685     984 cache_images.go:307] Attempting to cache image: k8s.gcr.io/k8s-dns-kube-dns-amd64:1.14.13 at C:\Users\admin\.minikube\cache\images\k8s.gcr.io\k8s-dns-kube-dns-amd64_1.14.13
I0605 14:40:37.113634     984 cache_images.go:307] Attempting to cache image: k8s.gcr.io/k8s-dns-sidecar-amd64:1.14.13 at C:\Users\admin\.minikube\cache\images\k8s.gcr.io\k8s-dns-sidecar-amd64_1.14.13
I0605 14:40:37.114634     984 cache_images.go:307] Attempting to cache image: k8s.gcr.io/k8s-dns-dnsmasq-nanny-amd64:1.14.13 at C:\Users\admin\.minikube\cache\images\k8s.gcr.io\k8s-dns-dnsmasq-nanny-amd64_1.14.13
I0605 14:40:37.100685     984 cache_images.go:307] Attempting to cache image: k8s.gcr.io/kube-proxy:v1.14.2 at C:\Users\admin\.minikube\cache\images\k8s.gcr.io\kube-proxy_v1.14.2
I0605 14:40:37.100685     984 cache_images.go:307] Attempting to cache image: k8s.gcr.io/kube-scheduler:v1.14.2 at C:\Users\admin\.minikube\cache\images\k8s.gcr.io\kube-scheduler_v1.14.2
I0605 14:40:37.100685     984 cache_images.go:307] Attempting to cache image: k8s.gcr.io/kube-controller-manager:v1.14.2 at C:\Users\admin\.minikube\cache\images\k8s.gcr.io\kube-controller-manager_v1.14.2
I0605 14:40:37.100685     984 cache_images.go:307] Attempting to cache image: k8s.gcr.io/kube-apiserver:v1.14.2 at C:\Users\admin\.minikube\cache\images\k8s.gcr.io\kube-apiserver_v1.14.2
I0605 14:40:37.100685     984 cache_images.go:307] Attempting to cache image: k8s.gcr.io/pause:3.1 at C:\Users\admin\.minikube\cache\images\k8s.gcr.io\pause_3.1
I0605 14:40:37.113634     984 cache_images.go:307] Attempting to cache image: gcr.io/k8s-minikube/storage-provisioner:v1.8.1 at C:\Users\admin\.minikube\cache\images\gcr.io\k8s-minikube\storage-provisioner_v1.8.1
I0605 14:40:37.115664     984 cache_images.go:307] Attempting to cache image: k8s.gcr.io/coredns:1.3.1 at C:\Users\admin\.minikube\cache\images\k8s.gcr.io\coredns_1.3.1
I0605 14:40:37.115664     984 cache_images.go:307] Attempting to cache image: k8s.gcr.io/kubernetes-dashboard-amd64:v1.10.1 at C:\Users\admin\.minikube\cache\images\k8s.gcr.io\kubernetes-dashboard-amd64_v1.10.1
I0605 14:40:37.115664     984 cache_images.go:307] Attempting to cache image: k8s.gcr.io/etcd:3.3.10 at C:\Users\admin\.minikube\cache\images\k8s.gcr.io\etcd_3.3.10
I0605 14:40:37.115664     984 cache_images.go:307] Attempting to cache image: k8s.gcr.io/kube-addon-manager:v9.0 at C:\Users\admin\.minikube\cache\images\k8s.gcr.io\kube-addon-manager_v9.0
I0605 14:40:37.117630     984 cluster.go:81] Skipping create...Using existing machine configuration
* Tip: Use 'minikube start -p <name>' to create a new cluster, or 'minikube delete' to delete this one.
[executing ==>] : C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe -NoProfile -NonInteractive ( Hyper-V\Get-VM minikube ).state
[stdout =====>] :
[stderr =====>] : Hyper-V\Get-VM : Hyper-V was unable to find a virtual machine with name "minikube".
At line:1 char:3
+ ( Hyper-V\Get-VM minikube ).state
+   ~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidArgument: (minikube:String) [Get-VM], VirtualizationException
    + FullyQualifiedErrorId : InvalidParameter,Microsoft.HyperV.PowerShell.Commands.GetVM


I0605 14:40:37.727393     984 cluster.go:100] Machine state:
* Restarting existing hyperv VM for "minikube" ...
[executing ==>] : C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe -NoProfile -NonInteractive Hyper-V\Start-VM minikube
[stdout =====>] :
[stderr =====>] : Hyper-V\Start-VM : Hyper-V was unable to find a virtual machine with name "minikube".
At line:1 char:1
+ Hyper-V\Start-VM minikube
+ ~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : ObjectNotFound: (:) [Start-VM], VirtualizationException
    + FullyQualifiedErrorId : ObjectNotFound,Microsoft.HyperV.PowerShell.Commands.StartVM


E0605 14:40:38.299426     984 start.go:529] StartHost: start: exit status 1
I0605 14:40:38.301395     984 utils.go:122] non-retriable error: start: exit status 1
W0605 14:40:38.307395     984 exit.go:100] Unable to start VM: start: exit status 1

X Unable to start VM: start: exit status 1

* Sorry that minikube crashed. If this was unexpected, we would love to hear from you:
  - https://github.com/kubernetes/minikube/issues/new

The full output of the command that failed (delete output):

minikube delete --alsologtostderr -v=8
I0605 14:41:28.419401    8500 notify.go:128] Checking for updates...
[executing ==>] : C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe -NoProfile -NonInteractive ( Hyper-V\Get-VM minikube ).state
[stdout =====>] :
[stderr =====>] : Hyper-V\Get-VM : Hyper-V was unable to find a virtual machine with name "minikube".
At line:1 char:3
+ ( Hyper-V\Get-VM minikube ).state
+   ~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidArgument: (minikube:String) [Get-VM], VirtualizationException
    + FullyQualifiedErrorId : InvalidParameter,Microsoft.HyperV.PowerShell.Commands.GetVM


I0605 14:41:29.137685    8500 cluster.go:161] host is in state
* Deleting "minikube" from hyperv ...
[executing ==>] : C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe -NoProfile -NonInteractive ( Hyper-V\Get-VM minikube ).state
[stdout =====>] :
[stderr =====>] : Hyper-V\Get-VM : Hyper-V was unable to find a virtual machine with name "minikube".
At line:1 char:3
+ ( Hyper-V\Get-VM minikube ).state
+   ~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidArgument: (minikube:String) [Get-VM], VirtualizationException
    + FullyQualifiedErrorId : InvalidParameter,Microsoft.HyperV.PowerShell.Commands.GetVM


[executing ==>] : C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe -NoProfile -NonInteractive Hyper-V\Remove-VM minikube -Force
[stdout =====>] :
[stderr =====>] : Hyper-V\Remove-VM : Hyper-V was unable to find a virtual machine with name "minikube".
At line:1 char:1
+ Hyper-V\Remove-VM minikube -Force
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : ObjectNotFound: (:) [Remove-VM], VirtualizationException
    + FullyQualifiedErrorId : ObjectNotFound,Microsoft.HyperV.PowerShell.Commands.RemoveVM


W0605 14:41:30.256764    8500 exit.go:100] Failed to delete cluster: exit status 1

X Failed to delete cluster: exit status 1

* Sorry that minikube crashed. If this was unexpected, we would love to hear from you:

The output of the minikube logs command:

minikube logs

```
X command runner: getting ssh client for bootstrapper: Error creating new ssh host from driver: Error getting ssh host name for driver: Host is not running

```

@sgiovinetti @sneevand I was able to bypass the issue by deleting the .minikube folder

could you please try to delete the folder under C:\Users\medya\.minikube and do minikube delete and minikube start ?

@medyagh . Yes deleting the folder solved the issue.

Closing, as unable to find a virtual machine with name "minikube" errors are not relevant to the original report.

Eu tive o mesmo problema, eu lembro de j谩 ter instalado anteriormente o minikube e funcionou, nessa segunda vez que surgiu o problema, mas apagando a pasta .minikube resolveu, grato.

rerun Enable-WindowsOptionalFeature-Online -FeatureName Microsoft-Hyper-V -All and restart computer immediately base on the PowerShell cmd request, then run minikue start --driver=hyperv solved my problem
minikube version: v1.9.2

deleted .minikube folder and ran minikube start not able to see virtual machine name minikube.
Below is output.

! minikube v1.9.2 on Microsoft Windows 10 Home Single Language 10.0.18362 Build 18362

  • Automatically selected the hyperv driver
  • Downloading VM boot image ...

minikube-v1.9.0.iso.sha256: 65 B / 65 B [--------------] 100.00% ? p/s 1s
minikube-v1.9.0.iso: 174.93 MiB / 174.93 MiB 100.00% 807.90 KiB p/s 3m42

  • Starting control plane node m01 in cluster minikube
  • Creating hyperv VM (CPUs=2, Memory=2200MB, Disk=20000MB) ...
    panic: runtime error: index out of range [0] with length 0

goroutine 60 [running]:
github.com/docker/machine/drivers/hyperv.hypervAvailable(0xc0005eced0, 0xc000706ab0)
/go/pkg/mod/github.com/machine-drivers/[email protected]/drivers/hyperv/powershell.go:64 +0x105
github.com/docker/machine/drivers/hyperv.(Driver).PreCreateCheck(0xc00025e480, 0x0, 0x0)
/go/pkg/mod/github.com/machine-drivers/[email protected]/drivers/hyperv/hyperv.go:171 +0x3b
k8s.io/minikube/pkg/minikube/machine.(
LocalClient).Create(0xc000734100, 0xc00025e4e0, 0x0, 0x0)
/app/pkg/minikube/machine/client.go:229 +0x3f5
k8s.io/minikube/pkg/minikube/machine.timedCreateHost.func2(0x1e08b00, 0xc000734100, 0xc00025e4e0, 0xc00020daa0, 0xc0006e10a0)
/app/pkg/minikube/machine/start.go:170 +0x42
created by k8s.io/minikube/pkg/minikube/machine.timedCreateHost
/app/pkg/minikube/machine/start.go:169 +0x10e

Was this page helpful?
0 / 5 - 0 ratings