Docker Community Forums

Share and learn in the Docker community.

Manually edited file in /var/lib/overlay2 folder and now I can't export images

Good Morning to everybody,
I’ve manually edit a file in overlay2 folder and now when I try to export the image I’ve got that error

root@ubuntu:~# docker save tests:2 | gzip > /mnt/test.tar.gz
Error response from daemon: file integrity checksum failed for "opt/dr/check.sh"

If I remove the file:

root@ubuntu:~# docker save  tests:2 | gzip > /mnt/test.tar.gz
Error response from daemon: open /var/lib/docker/overlay2/0732ae0eeb138aacc9d9f51374950cccb21b582ed63798f01745b9260a5b1fef/merged/opt/dr/check.sh: no such file or directory

How can I fix that error? If I run the container it work correctly, but now I need to save that container to move it to production environment.

Thanks to all