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
Delete tag failed -- size 0 image. #6515
Comments
|
I've experience same issue since since 1.6.1: some tags has "0B" size and can't be deleted. |
|
I have same issue |
|
I had same issue in harbor version v1.6.0. |
|
I have same issue here, since Harbor 1.2.0, today I've 1.7.1 installed. In Harbor Web Console an image Tag are reported with 0 bytes of size and its Manifest has no pointing nor data: |
|
I believe this could be a bug. This problem is very common when I simultaneously delete multiple Tags through the user interface. |
|
We also have this issue when deleting multiple tags at once. Same error as reported, 500 and "unknown error". This bug prevent us from running the GC correctly (as tags still appear). |
|
I think this might be an issue with Docker Registry and not Harbor. curl -X DELETE -H 'Authorization: Bearer xxx' http://registry:5000/v2/myrepo/myimage/manifests/sha256:03d7371cdfd09a41f04cf4f862e1204a91231f80c1bae785231fafd936491097
{
"errors": [
{
"code": "MANIFEST_UNKNOWN",
"message": "manifest unknown"
}
]
}curl -H 'Authorization: Bearer xxx' http://registry:5000/v2/myrepo/myimage/manifests/sha256:03d7371cdfd09a41f04cf4f862e1204a91231f80c1bae785231fafd936491097
{
"errors": [
{
"code": "MANIFEST_UNKNOWN",
"detail": {
"Name": "myrepo/myimage",
"Revision": "sha256:03d7371cdfd09a41f04cf4f862e1204a91231f80c1bae785231fafd936491097"
},
"message": "manifest unknown"
}
]
}I have the path on the filesystem: But it is empty (on others path I have a So I guess that the data is partially deleted. There are still some references in the registry somewhere (which leads to something listed on the UI or when asking for tags listing). |
|
@reasonerjt Just delete multiple tags on the same repo on the web UI , this issue will occur. |
|
could you double check are these tags having duplicate digest? If they are not could you reproduce if you delete 3 tags, can you push these 3 tags to docker hub so I can reproduce? |
|
I hava a try.Firstly I try to delete 3 tags,and then two of them returned failed.Secondly,I try to push these images to harbor,than it was succeed.At the same time , I found these images still presenced in harbor after I have deleted them on the web UI unsuccessfully.In the fact,the result told me "Layer already exists" when I pushed these image to harbor in the seconed step. |
|
@reasonerjt Their digest are different.And if I delete 3 tags, two of them will failed. Below is the error log when I delete 2 tags in the same time. Please check. |
|
@reasonerjt Maybe That's because these tags have common layers that will be deleted? For security, I can not push them to docker hub.Sorry. |
|
Hi all current I'm using 1.7.5 now, the same issue Trying to push the image back then delete it again, nothing changed Does anyone have any idea to fix this issue? Thanks a lot |
|
@judexzhu you should flush registry cache before re-pushing. |
|
root@AWSNX-RC-QA-Dev-harbor-100-104:/var/log/harbor# docker tag busybox awsnx-hub.rongcloud.net/kangyishan-private/fastdfs-proxy:43-20181213181230 Find an image tag > push > overwrite |
|
I've had this issue as well. It turned out that once you have obtained the authorization Bearer token, you can do most of the operations without being required to input your username and password again. So for all GET operations token suffices, but for ta DELETE (and possibly other DELETEs as well) you also need to re-provide user/pass or get 401 unauthorized. |
|
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
|
i got the same issue is there any resolution in this problem |
|
Push the same tag name to the harbor again, and you can delete it from the ui. |
|
we occur the same issue on Harbor 1.10 (But in other context ...) |
|
I'm also getting same error but in my case tag name is also empty so i can't retag it. { Error on UI : Bad argument |
|
These are due to a bug in upstream docker distribution, essentially the blob is not written to the storage but the manifest created successfully and referencing the non-existing blob. The workaround: With the change in v2.0, I believe this problem will not happen in Harbor even the bug remains in distribution. |
|
it look like a docker registry bug。 |
With my Harbor is v1.10.2, that's workaround is working NO more! At beginning Tags were deleted. Now I have a few Zeroed images that can not be removed after this "overlap". My Zerroed images have now the same behavior in issue #2663. |
clean the registry data cached in redis before the steps. |
After stop Harbor, I've removed all redis: When I push an Image with common layers and same Tag name over the Zeroed image, both images are revomed. |
it is not a bug. Harbor will remove all tags with the same digest in one repo when you try to delete one of these tags. it is related to the design of docker registry. and it has been resolved in Harbor 2.0 by redesign the image tag manage system. |
|
this was due to a distribution upstream bug but should not be happening in 2.0 since we use db as single source of truth. Also you can now delete a tag or a set of tags on UI without affecting other tags or the associated digest. Definitely feel free to ask for support on here or open a new ticket if you come across this in v2.0 |
harbor V1.6.0 RC2
reproduce steps:
ui.log:
Dec 11 15:48:59 172.18.0.1 ui[3597772]: 2018-12-11T07:48:59Z [ERROR] [repository.go:298]: failed to delete tag v2: 500 {"errors":[{"code":"UNKNOWN","message":"unknown error","detail":{"Path":
"/docker/registry/v2/repositories/testforrsync/test2/_manifests/tags/v1/current/link","DriverName":"filesystem"}}]}
registry.log:
Dec 11 15:48:59 172.18.0.1 registry[3597772]: time="2018-12-11T07:48:59.125019435Z" level=error msg="response completed with error" auth.user.name=harborAdmin err.code=unknown err.message="fi
lesystem: Path not found: /docker/registry/v2/repositories/testforrsync/test2/_manifests/tags/v1/current/link" go.version=go1.7.3 http.request.host="10.182.2.108:25000" http.request.id=51bbb9
d6-22cc-46d5-a204-c76f28955cb8 http.request.method=DELETE http.request.remoteaddr=10.182.2.120 http.request.uri="/v2/testforrsync/test2/manifests/sha256:3e533db287adef4291610c6186c49efcb808e8
eb76f5b8e8873077a769fd09bc" http.request.useragent="Go-http-client/1.1" http.response.contenttype="application/json; charset=utf-8" http.response.duration=7.86665ms http.response.status=500 h
ttp.response.written=188 instance.id=9c456576-0ef7-4676-9710-fa01b8527d3e service=registry vars.name="testforrsync/test2" vars.reference="sha256:3e533db287adef4291610c6186c49efcb808e8eb76f5b8
e8873077a769fd09bc" version=v2.6.2
i don't know why i delete tag 'v2' and registry try to delete the manifest reference from tag 'v1'.
i search issue in docker registry official, and find the issue distribution/distribution#1755 .
parhaps they are the same issue. please check.
The text was updated successfully, but these errors were encountered: