Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Can't load docker from saved tar image

Tags:

docker

I committed my container as an image, then used "docker save" to save the image as a tar. Now I'm trying to load the tar on a GCC Centos 7 instance. I packaged it locally on my Ubuntu machine.

I've tried: docker load < image.tar and sudo docker load < image.tar

I also tried chmod 777 image.tar to see if the issue was permissions related.

Each time I try to load the image I get a variation of this error (the xxxx bit is a different number every time):

open /var/lib/docker/tmp/docker-import-xxxxxxxxx/repositories: no such file or directory

I think it might have something to do with permissions, because when I try to cd into /var/lib/docker/ I run into permissions issues.

Are there any other things I can try? Or is it likely to be a corrupted image?

like image 621
offmyrockerondocker Avatar asked Feb 03 '19 02:02

offmyrockerondocker


People also ask

Is docker image a tar file?

Docker images are just TAR files!


1 Answers

There was a simple answer to this problem

I ran md5 checksums on the images before and after I moved them across systems and they were different. I re-transferred and all is working now.

like image 165
offmyrockerondocker Avatar answered Sep 21 '22 22:09

offmyrockerondocker