Checked with diff -r,
I got a message that there is a difference in block special devices such as /home/docker11/overlay2/backingFsBlockDev.
Even after migrating with tar, there is a difference when I look at it with diff.
So I used the dd command to transfer the block special devices, but still there is a difference when I look at it with diff.
Is this a diff problem?
Or is there another way to move the block special device?
The docker engine must be stopped, before the folder is moved, synched or a a tar is created from it.
If the engine is running, you will end up moving files multiple times and destroying the folder structure required for overlay2 to work properly.
The root-data folder can NOT reside on a remote share.
You need to make sure the target ends up using the same storage driver as before. Otherwise, existing images and containers won’t be available, as they are tied to the storage driver.
To be frank: no one actually moves the data-root folder (except it’s on the same host). Instead, we make backups of the content of the docker volumes. Move those backups to the new location, then restore the containers, networks, and volumes from compose files. Then restore the content of the volumes back into the volumes. This way you start with a clean, fresh and reliable setup.
Hello,
Moving your computer stuff is tricky!
You’re trying to move a special folder called “docker” to a new spot. It’s important to do it right, or your computer might get confused.
Let’s figure out how to do it without breaking anything.