CI: plugins/manifest is flaking
Our manifest job on Drone seems to fail unpredictably with the following message:
2020/02/07 19:46:14 pushing by spec
time="2020-02-07T19:46:15Z" level=error msg="Error trying v2 registry: http: unexpected EOF reading trailer"
time="2020-02-07T19:46:15Z" level=fatal msg="Inspect of image \"grafana/loki:master-675a5f3-amd64\" failed with error: http: unexpected EOF reading trailer"
2020/02/07 19:46:15 exit status 1
Some research of the problem suggested that primary issue is a large number of image tags. We've added a pruning stage to remove master build images after 90 days, but the error is still happening. Help figuring this out would be appreciated!
Do we need to delete old manifests too?
I don't think so? If the error really is about too many tags, we're deleting both image and manifest tags with the new prune job. We still have ~800 tags for Loki right now based on the last time the prune job ran. It could be that that's still too many or it could also mean the error has nothing to do with the amount of tags. 🤷♂
This is where the first error comes from and the second one is coming from here.
I was looking into this a few days ago but nothing stood out at me for explaining why we're getting EOFs.
We've added a pruning stage to remove master build images after 90 days
Are we deleting them from the CI machine or are we deleting them from dockerhub? If its dockerhub then it's setting people up for outages, as if we delete the image and if the pod is rescheduled it'll cause an outage. What is the reasoning behind choosing to remove the tags?
@gouthamve They're being deleted from Docker Hub. The reasoning to delete them so far has been to try to get the manifest job to not flake, since some results online implied the number of tags would cause manifest-tool to have issues. We've since deleted more extremely old non-release tags from Loki (which were non-release tags from a non-master branch) and manifest-tool seems to be working consistently again, at least for now, so it does seem like the problems are related to the number of published tags.
On it causing outages, we (Ed and I) agreed to treat non-release tags as ephemeral, and recommend that users don't pin their cluster to using them.
On it causing outages, we (Ed and I) agreed to treat non-release tags as ephemeral, and recommend that users don't pin their cluster to using them.
Hrm, but what I am afraid is that people will end up pinning the cluster to get a new shiny unreleased feature and will complain after it causes an outage. I don't know of any other project that nukes docker images and this is a very unique case. Can we rather fix the manifest-tool rather than work around the bug by nuking the tags?
This issue has been automatically marked as stale because it has not had any activity in the past 30 days. It will be closed in 7 days if no further activity occurs. Thank you for your contributions.
This happened again recently, going to mark this as keepalive.
@rfratto I think you mentioned there may be a fix for this soon?
Not sure if my problem is directly related to this but that's my hunch. We are using Weaveworks Flux as a Gitops operator on our K8s cluster. We have helm release deployments via their HelmRelease Custom Resource to deploy a promtail, loki and Grafana stack. Whenever flux attempts to refresh the promtail and loki images it floods the logs with errors like:
manifest for tag master-993044e missing in repository grafana/loki" impact="flux will fail to auto-release workloads with matching images, ask the repository administrator to fix the inconsistency"
This, it does for numerous tags on both the promtail and loki repos. I'm attaching two lists with all the tags I found raising this warning. Could it be a product of the same issue?
Missing manifests - loki.txt Missing manifests - promtail.txt
I'm having same issue as @christopher-grech.
Any solutions for it please?
The error messages is likely correct, we prune old master-***** image from dockerhub after 60 days, they are meant to be ephemeral.
Are you deploying with master-***** images? Or does this just create a noisy log? I'm afraid I don't really have any suggestions/solutions.
@slim-bean in our case, no we're not using the master-* images. The issue is that the automated orchestrator monitors the entire grafana/loki and grafana/promtail repos and finds this "incorrect" images, which results in the mentioned logs. Since there are a couple of hundred images (for both promtail and loki) at a time, we are being flooded with logs every few minutes.
Running docker manifest returns nothing for the said images, which seems to correlate with the errors we're seeing.
> docker manifest inspect grafana/loki:master-fc6c5c0
no such manifest: docker.io/grafana/loki:master-fc6c5c0
Is it possible that you start pushing the manifest for these images?
Any comment on my suggestion please?
Having the exact same issue as @christopher-grech
Same issue as @christopher-grech
Also having the same as @christopher-grech
This issue has been automatically marked as stale because it has not had any activity in the past 30 days. It will be closed in 7 days if no further activity occurs. Thank you for your contributions.
Also having the same as @christopher-grech