查询目前已安装的路径
sudo docker info | grep "Docker Root Dir"
备份旧数据到新目录
cp -a /var/lib/docker /path/to/docker
修改配置文件
docker 版本 > 17.05
vim /etc/docker/daemon.json
|
|
重启docker
sudo systemctl restart docker
sudo docker info | grep "Docker Root Dir"
cp -a /var/lib/docker /path/to/docker
vim /etc/docker/daemon.json
|
|
sudo systemctl restart docker