8000 image gc improvement · Issue #3772 · rkt/rkt · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
This repository was archived by the owner on Feb 24, 2020. It is now read-only.

image gc improvement #3772

Closed
sanicheev opened this issue Aug 10, 2017 · 11 comments
Closed

image gc improvement #3772

8000 sanicheev opened this issue Aug 10, 2017 · 11 comments

Comments

@sanicheev
Copy link

Currently i'm in a situation when i have several rkt images stored on disk with the same name. It can be that i will have 10,15 rkt images which consume disk space and gc operations will not clean them.

That's why i would like to consult if this situation it expected?
Because i would like to improve image gc operation that it will store only N images with the same name and prepare pull request.

So the question is this feature should be implemented or am i doing something wrong?

@sanicheev
Copy link
Author

I'll prepare a PR in short time anyway.

sanicheev pushed a commit to sanicheev/rkt that referenced this issue Aug 22, 2017
…ration is unable to process whole image tree
@sanicheev
Copy link
Author

Continue should be used instead of break. Otherwise when running image has been found the loop will stop and doesn't traverse whole image tree.

@euank
Copy link
Member
euank commented Aug 22, 2017

It's possible the original behavior you saw was due to the "grace period"? Would rkt image gc --grace-period=0 have accomplished the right thing here?

That doesn't handle th 8000 e idea of leaving the most recent of duplicate images, and maybe there would be some value for rkt image gc --deduplicate or such which does that.
I personally don't think I'd use it, especially since I treat tags as immutable and thus just never have duplicate images.

Based on the above, does setting an appropriate grace period accomplish what you wanted, or would you still like to propose an additional feature allowing

@sanicheev
Copy link
Author

@euank, no. I have tested it by setting grace-period=0. According to the breakpoints which i set it exited the loop after this block and never processed the rest of the stack:
if isInSet(ai.BlobKey, runningImages) {
continue
}
If you want i can send you more output of what's happening and which images i have and where the loop breaks.

sanicheev pushed a commit to sanicheev/rkt that referenced this issue Aug 23, 2017
…ration is unable to process whole image tree
@ghost
Copy link
ghost commented Oct 31, 2017

What's the status of this issue? We're experiencing the same probleim in rkt 1.28.1.

@iaguis
Copy link
Member
iaguis commented Nov 1, 2017

This is pending #3778

We could merge the fix now and do the test later (creating an issue so we don't forget). What do you think, @sanicheev?

@sanicheev
Copy link
Author

@iaguis, sorry for a long response. Yes i think so. I'll try to fix tests scenario this weekend. Hope will find some time for this. Can you assign a newly created issue on me?

@ghost
Copy link
ghost commented Nov 21, 2017

bump

@iaguis
Copy link
Member
iaguis commented Nov 21, 2017

I submitted a PR with @sanicheev's commit only #3858

I created an issue to track the missing test: #3859

@iaguis
8000 Copy link
Member
iaguis commented Nov 21, 2017

Fixed via #3858

@iaguis iaguis closed this as completed Nov 21, 2017
@ghost
Copy link
ghost commented Nov 28, 2017

Thank you for fixing this. When will there be a release including the fix?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants
0