问题描述
这不是重复
Docker 本机,在 Windows 上,在 Hyper-V 虚拟机中运行.
移动现有的 docker 虚拟机
我必须将 docker 使用的虚拟机移动到所需的位置.我使用 Hyper-V 管理器 的 GUI 完成了这项工作.用于 docker 的 VM 称为 MobyLinuxVM.
- 右击 MobyLinuxVM
- 选择移动
- 选择所需位置
设置未来 Hyper-V 虚拟机的位置
为了确保 Hyper-V 的未来虚拟机将存储在我的辅助驱动器上,我遵循了 那些说明一个>
在 powershell 终端中(目标文件夹必须存在)
SET-VMHOST –计算机名--virtualharddiskpath 'D:Hyper-V_Virtual-Hard_Disks'
SET-VMHOST –计算机名--virtualmachinepath 'D:Hyper-V_VMs'
This is not a duplicate of Change Docker machine location - Windows
I'm using docker native, version 1.12.1-stable (build: 7135) on Windows 10 Pro with Hyper-V enabled.So docker is not running with VirtualBox nor do I have the folder C:Usersusername.docker
I'd like to move docker's images, caches, ... to my secondary drive D:
I guess I should edit the Docker Daemon configuration.
I tried to add "graph": "/D/docker"
. Docker started correctly but I couldn't pull any image because of an error
How to tell docker to use another path to store its images, etc ?
I found a solution here
Docker native, on Windows, runs in a Hyper-V virtual machine.
Move existing docker VM
I have to move the VM used by docker to the desired location.I did this using the GUI of Hyper-V manager.The VM for docker is called MobyLinuxVM.
- Right-click MobyLinuxVM
- Select Move
- Select desired location
Set location of futures Hyper-V VMs
And to be sure futures VMs of Hyper-V will be stored on my secondary drive,I followed those instructions
In a powershell terminal (destination folders must exist)
SET-VMHOST –computername <computer> –virtualharddiskpath 'D:Hyper-V_Virtual-Hard_Disks'
SET-VMHOST –computername <computer> –virtualmachinepath 'D:Hyper-V_VMs'
这篇关于在 Windows 10 Pro 上更改 Docker 本机映像位置的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!