我已经安装了Docker,当我运行GUI时,我得到这个错误:

硬件辅助虚拟化和数据执行保护必须 在BIOS中启用

似乎是一个bug,因为Docker在命令行中工作得很好,但我想知道是否有人知道为什么会发生这种情况?

在你问之前,是的,我已经在BIOS中启用了虚拟化,并且英特尔处理器识别实用程序确认它已被激活。Docker, Docker -machine和Docker -compose都可以在命令行中工作,Virtualbox可以,在Debian或Ubuntu虚拟机中运行Docker也可以。

GUI有个奇怪的问题。

我的规格:

Windows 10 Pro x64周年纪念版 英特尔酷睿i5-6300HQ @ 2.30GHz


当前回答

I have tried many suggestions above but docker keeps complaining about hardware assisted virtualization error. Virtualization is enabled in BIOS, and also Hyper-V is installed and enabled. After a few try and errors, I eventually downloaded coreinfo tool and found out that Hypervisor was not actually enabled. Using ISE (64 bit) as admin and run command from above Solution B and that enables Hypervisor successfully (checked via coreinfo -v again). After restart, docker is now running successfully.

其他回答

如果问题仍然存在,可能是系统上的Hyper-V损坏了,所以

进入控制面板->[程序]-> [Windows功能],完全取消选中所有Hyper-V相关组件。重新启动系统。

再次启用Hyper-V。重新启动。

I have tried many suggestions above but docker keeps complaining about hardware assisted virtualization error. Virtualization is enabled in BIOS, and also Hyper-V is installed and enabled. After a few try and errors, I eventually downloaded coreinfo tool and found out that Hypervisor was not actually enabled. Using ISE (64 bit) as admin and run command from above Solution B and that enables Hypervisor successfully (checked via coreinfo -v again). After restart, docker is now running successfully.

通过“设置”开启Hyper-V角色 右键单击Windows按钮/图标,选择“应用程序和功能”。

1-选择右侧相关设置下的“程序和功能”。

2-选择“打开或关闭Windows功能”。

2-选择“Hyper-V”,单击“确定”。

我在安装VMWare后也遇到了同样的问题,我卸载了它,但这并没有解决问题。

我的解决方案:在“打开或关闭窗口功能”中,我关闭了:

hyper - v 容器 Windows Linux分系统

然后重新启动

重启后,我从docker得到了这条消息:

我执行了消息中说的命令

Enable-WindowsOptionalFeature -Online -FeatureName $("VirtualMachinePlatform", "Microsoft-Windows-Subsystem-Linux")

然后重新启动和voilà, Docker就带着WSL2回来了

对我来说,我所要做的就是卸载VMware。

Docker现在正在运行