Skip to content

Latest commit

 

History

History
43 lines (23 loc) · 4.35 KB

FAQs.md

File metadata and controls

43 lines (23 loc) · 4.35 KB

FAQs

How can I get the results of synchronization?(如何获得同步的执行结果?)

After synchronization, image-syncer will count the failed and success synchronization tasks(images), outputs like "Finished, <NUMBER OF FAILED TASKS> sync tasks failed, <NUMBER OF GENERATED FAILED TASKS> tasks generate failed" will be print to both Stdout and logs file.

在同步结束之后,image-syncer 会统计成功和失败的同步任务数目(每个同步任务代表一个镜像),并在标准输出和日志中打印 "Finished, <NUMBER OF FAILED TASKS> sync tasks failed, <NUMBER OF GENERATED FAILED TASKS> tasks generate failed" 的字样,从而可以获得同步的结果

How can I deal with the failed sync tasks?(同步失败的任务如何处理?)

Failed tasks caused by occasional network problems will be restored by retries generally, if number of retries is enough. If number of retries is not large enough and synchronization is ended, you can just run image-syncer twice in the same way twice, synchronized images will be skipped as synchronization is incremental (with the same records file).

偶发网络问题导致的同步任务失败,在重试次数足够的情况下(默认为2次),通常会被重试机制恢复。如果重试次数不够多,并且程序结束时还有同步失败的任务,先排查是否是偶发的问题,如果是,可以直接重新再次以相同的方式运行程序,已同步的镜像会被跳过(依赖之前生成records文件)。

Find "Put manifest ... unknown blob error" in logs during synchronization, while there is no error with PUT actions of specific blobs?(传输过程中遇到了"Put manifest ... unknown blob error"问题,但是put对应blob的时候没有错误)

This problem may happens if the records file that already exists was not generated by yourself, this records file may includes the image blobs you have not synchronized. Use another records file path to generate a new one if you are not sure which is the correct records file, this may cause a much more longer synchronization.

在用错了records文件的情况下可能会发生,这个错误的records文件记录了之前没有同步过的镜像blog。如果不确定正确的records文件在哪,可以用个新的records文件路径生成一个新的records文件,但是这样同步会耗费更长的时间。

image-syncer remove the dependence of records file after v1.1.0

image-syncer 在 >= v1.1.0 版本中移除了对于records文件的依赖

Occasional network problems(常见的偶发网络问题)

"read: connection reset by peer" happens if the source of registry has network limits; "TLS handshake timeout" happens if network delay gets high; "DIGEST_INVALID" happens if image blobs is damaged in network traffic;

"read: connection reset by peer"这种大概是源仓库所在registry的网络限流,连接被断掉了;"TLS handshake timeout"在网络延迟比较高的时候会出现;"DIGEST_INVALID"表示在网络传输过程中由于传输错误,镜像blob损坏;

“ACR get tags failed”

As getting tags of a ACR private repository needs to authenticate in another way defer from username/password, if you want to synchronize sources of ACR private repository, you need to specify all the tags that you want to synchronize.

由于image-syncer现在不支持password/username之外的认证方式,而如果要获取ACR私有仓库所有的tags,需要进行额外的认证;如果你需要以ACR私有仓库作为源同步镜像,需要手动指定所有需要同步的tag。

“500 Internal Server Error”

When you are confused with such error logs of image-syncer, check if some of manifests in your docker images are schema V1 (which was deprecated by docker) first. As this tool doesn't support auto-transformation of manifest for schema V1 to schema V2, you cannot synchronize a docker image with schema V1 manifest to a registry which doesn't support it (e.g., Harbor, etc.).

当出现这种报错时,首先检查是否是镜像是旧版本,并且manifest类型为 Schema 1(已被docker弃用)。由于本工具不支持manifest类型的自动转换,并且目前新版本harbor不再支持类型为 Schema 1 的manifest,所以无法通过本工具将manifest类型为 Schema 1 的docker镜像同步到不支持该类型manifest的镜像存储中(比如harbor)