1.首先停止docker服务:
systemctl stop docker.service
2.在 /var/lib/docker/containers/container-ID/config.v2.json 中找到 MountPoints,并修改挂载路径。
vim /var/lib/docker/containers/container-ID/config.v2.json
3.MountPonts内容
"MountPoints":{
"/home":{"Source":"/sda1/xiao/xiehongyan","Destination":"/home","RW":true,"Name":"","Driver":"","Type":"bind","Propagation":"rprivate","Spec":{"Type":"bind","Source":"/sda1/xiao/xiehongyan","Target":"/home"},"SkipMountpointCreation":false},
"/var":{"Source":"/sda1/xiao/DataSets","Destination":"/var","RW":true,"Name":"","Driver":"","Type":"bind","Propagation":"rprivate","Spec":{"Type":"bind","Source":"/sda1/xiao/DataSets","Target":"/var"},"SkipMountpointCreation":false}
}
4.vim下光标移动:
gj:向下移动一物理行(\r\n结尾的可以理解成逻辑行),一行字符太多显示时会做line wrap
gk:向上移动一物理行 ,同gj