Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Copy images between registries / Error: invalidData #833

Closed
remarkov opened this issue May 28, 2024 · 7 comments
Closed

Copy images between registries / Error: invalidData #833

remarkov opened this issue May 28, 2024 · 7 comments
Labels
question Further information is requested

Comments

@remarkov
Copy link

Probably more a question, not an issue. I hope this can be useful for others too.

When having more than one local image registry in the network, what would be the best way to copy/sync images between the registries without tart pull and further tart push?
So far I tried using Skopeo which works most of the times but sometimes the copied image gets corrupt and tart clone or tart pull give an error during the progress

pulling disk (160.6 GB compressed)...
9%
Error: invalidData

Most likely this is because Tart image format is not fully compatible with Docker images but that's just a guess. Any advice will be much appreciated.

@fkorotkov
Copy link
Contributor

Do you have a hard requirement of having different registries? Have you considered a single registry with several read through proxies?

@fkorotkov fkorotkov added the question Further information is requested label May 28, 2024
@edigaryev
Copy link
Collaborator

Error: invalidData

Which Tart version are you using to generate the VM images?

This error seems to be coming from the LZ4 decompressor and could be caused by the Skopeo reordering the manifest layers, which is an issue in the older V1 disk format.

@remarkov
Copy link
Author

thanks for quick response!

@fkorotkov yes, unfortunately we need separate registries located in different locations/networks but some may share some of the images, not necessarily all.

@edigaryev that's on Tart 0.38.0. Do you by any chance know some workaround to prevent the layers reordering? Does it make sense to try other tools like regclient or this is something Tart-specific?

@fkorotkov
Copy link
Contributor

We don't have experience with Skopeo or similar tools. Some other tools in our experience were Docker exclusive and not fully OCI compliment until the latest versions.

Another concerning part is that this issue is transient and only sometimes things getting corrupted. Definitely points to something fishy in the tooling. Hope you'll figure it out!

@fkorotkov
Copy link
Contributor

I just doble checked and Disk V2 also depends on ordering but we can fix it in backward compatible way.

@edigaryev
Copy link
Collaborator

edigaryev commented May 31, 2024

@remarkov I've tried reproducing this using a simple script that does tart push, skopeo copy and tart pull in a loop to no avail on the latest Tart version (2.11.0). So the initial premise that this issue is related to layer order is probably wrong.

Could try pulling your corrupted image using the latest Tart to see if the issue still persists? Ideally, push a new VM image using the tart push to get the newer V2 disk image.

It has countless improvements over the older version, including the V2 disk images. We've also just merged #835 to nail this error further down if it ever occurs again.

@remarkov
Copy link
Author

@edigaryev Thanks for your time, I will try to do the tests with the newer version too.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

3 participants