我试图在Windows10 Home上安装minikube,但出现此错误。为什么?
C:\WINDOWS\system32>minikube start --driver=hyperv
* minikube v1.11.0 on Microsoft Windows 10 Home 10.0.19041 Build 19041
* Using the hyperv driver based on existing profile
* Starting control plane node minikube in cluster minikube
* Creating hyperv VM (CPUs=2, Memory=4000MB, Disk=20000MB) ...
panic: runtime error: index out of range [0] with length 0
goroutine 60 [running]:
github.com/docker/machine/drivers/hyperv.hypervAvailable(0xc00008cff0, 0xc0002cdd00)
/go/pkg/mod/github.com/machine-drivers/machine@v0.7.1-0.20200323212942-41eb826190d8/drivers/hyperv/powershell.go:64 +0x105
github.com/docker/machine/drivers/hyperv.(*Driver).PreCreateCheck(0xc000439ec0, 0x0, 0x0)
/go/pkg/mod/github.com/machine-drivers/machine@v0.7.1-0.20200323212942-41eb826190d8/drivers/hyperv/hyperv.go:171 +0x3b
k8s.io/minikube/pkg/minikube/machine.(*LocalClient).Create(0xc000043540, 0xc000439f20, 0x0, 0x0)
/app/pkg/minikube/machine/client.go:221 +0x3f5
k8s.io/minikube/pkg/minikube/machine.timedCreateHost.func2(0x1e80ea0, 0xc000043540, 0xc000439f20, 0xc0006c0540, 0xc0004c6af0)
/app/pkg/minikube/machine/start.go:184 +0x42
created by k8s.io/minikube/pkg/minikube/machine.timedCreateHost
/app/pkg/minikube/machine/start.go:183 +0x10e
C:\WINDOWS\system32>minikube status
E0627 09:15:44.982608 38068 status.go:132] The "minikube" host does not exist!
minikube
type: Control Plane
host: Nonexistent
kubelet: Nonexistent
apiserver: Nonexistent
kubeconfig: Nonexistent
C:\WINDOWS\system32>
答案 0 :(得分:1)
$hyperv.State -eq "Enabled"
命令Disable-WindowsOptionalFeature -Online -FeatureName Microsoft-Hyper-V-All
中执行以下命令来禁用Hyper-V(如果正在运行)。重新启动电脑minikube delete
,然后尝试从C:\ Users {您的用户名}中手动删除“ .minikube”文件夹。minikube start
minikube status
命令以验证其正在运行希望这会有所帮助