一、錯誤信息1:解決VM 與 Device/Credential Guard 不兼容
錯誤原因:
1、出現此問題的原因是Device Guard或Credential Guard與Workstation不兼容。
2、Windows系統的Hyper-V不兼容導致。(我在本機Windows10裝了Docker Desk Top,而Docker Desk Top依賴於Hyper-V。)
二、解決方法1:禁用Device Guard & 關閉Hypver-V
步驟一:禁用Device Guard或Credential Guard:
禁用用於啓用Credential Guard的組策略設置。
在主機操作系統上,右鍵單擊“開始” > “運行”,鍵入gpedit.msc,然後單擊“ 確定”。
本地組策略編輯器打開。
轉至本地計算機策略 > 計算機配置 > 管理模板>系統 >Device Guard(或者是: 設備防護) > 啓用基於虛擬化的安全性。
選擇已禁用。
轉到“ 控制面板” >“ 卸載程序” >“ 打開或關閉Windows功能”以關閉Hyper-V。
選擇不重啓。
步驟二:通過命令關閉Hyper-V(控制面板關閉Hyper-V起不到決定性作用,要徹底關閉Hyper-V)
以管理員身份運行Windows Powershell (管理員)(Windows鍵+X)
運行下面命令並重啓電腦:
bcdedit /set hypervisorlaunchtype off
三、錯誤信息2:Failed to start Docker Application Container Engine
這個原因很常見,網上提供的解決方案很多,我先後嘗試了以下方法。
1、刪除並重新安裝Docker
可以參看:https://blog.csdn.net/Hello_World_QWP/article/details/81147307
2、重新安裝devicemapper依賴
使用命令:
yum instal l -y yum-utils device-mapper-persistent-data lvm2
3、修改daemon.json內容(這個方法我沒有嘗試)
可以參看:https://www.cnblogs.com/huhyoung/p/9495956.html
4、設置selinux爲disabled(我用這個方法成功)
vi /etc/sysconfig/selinux 把selinux後面的改爲disabled,重啓一波機器,再重啓docker就可以了