-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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
Loss of images during GC when Postgresql server runs out of connections #19401
Comments
Is the postgres error |
Hi @chlins, you are correct, I meant retention policies - the ones which are executed for the repositories of a project. For us |
can you share the gc log as well? |
Hi @wy65701436, unfortunately GC logs have been already cleaned up |
This issue is being marked stale due to a period of inactivity. If this issue is still relevant, please comment or remove the stale label. Otherwise, this issue will close in 30 days. |
@dmitry-g Hi, do you also checked the untagged artifact checkbox for the retention policy? |
This issue is being marked stale due to a period of inactivity. If this issue is still relevant, please comment or remove the stale label. Otherwise, this issue will close in 30 days. |
This issue was closed because it has been stalled for 30 days with no activity. If this issue is still relevant, please re-open a new issue. |
Hello,
It has been the second time this month when we faced an issue with image loss during garbage collection. It probably has something to do with error handling, since the issue happens only when our database server runs out of connections.
Retention policy is configured as
For the repositories matching **, retain the most recently pushed 30 artifacts with tags matching **
, but garbage collector deletes the latest artifact, even regardless the fact that the repository had only 3 artifacts in total.Garbage collection starts at the defined schedule
01:00 UTC
Postgresql database runs out of available connections
sorry, too many clients already (SQLSTATE 53300)
Instead of failing/retrying/handling the error, garbage collector choses to delete the latest artifact.
Also in the logs provided below you can see that tags of some artifacts have not been loaded, though all of them were actually tagged.
Image loss on 2023-09-06
Image loss on 2023-09-26
Harbor version
v2.8.1-48a2061d
Thank you
The text was updated successfully, but these errors were encountered: