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
os/bluestore: Some more plumbing for zone cleaning (WIP) #38641
Conversation
@ifed01 Would appreciate if you could take a look. This is not complete yet, but does this make sense so far? I'm not sure about calling db->submit_transaction from ZonedFreelistManager::zoned_mark_zone... |
Hi @ifed01 -- I hope you had a great winter break. Would appreciate if you could take a look at this when you get a chance. Thanks! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Besides other comments I have a strong desire to simplify the logic of zones cleaning. Can zoned_cleaner_thread access the allocator directly and retrieve a list of zones to clean by itself? Hence avoiding all the tricks to pass the list from do_allocate_write to the thread?
Writes happen in do_allocate_write. That's the only place to detect when to start cleaning. The alternative is for the cleaner thread to poll the allocator every second and start cleaning if there is a need. This can be simpler if you want to go that route. |
@ifed01 Would appreciate if you could take a look. Thanks! |
Hi @ifed01 are you planning to look at this? |
yeah, will do this week. Sorry for delays.... |
May be something like this: Moreover it looks like ZonedAllocator and zoned_cleaner_thread are doing cleanup in-sync and hence ZonedAllocator::cleaning_in_progress_zones container is a sole and static set of zones to clean at a given point of time. Hence there is no need to make any copies of it - the thread can directly use it and pass back the completion indication in a single call to the allocator. |
@ifed01 Please take a look. I tried to simplify it based on your description. Thanks. |
jenkins make check |
jenkins test make check |
@ifed01 @tchaikov I don't see the following error when building on my system with gcc. Do test machines use a different compiler? /home/jenkins-build/build/workspace/ceph-api/build/../src/os/bluestore/BlueStore.cc:5442: undefined reference to |
In my lab this failed to build due to undefined WITH_ZBD. |
Oh, that's because you don't have libzbd installed (https://github.com/westerndigitalcorporation/libzbd). It is installed in the build servers. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Overall looks good except the assertion in ZonedAllocator.
Could you please squash the commits in a more sensible way prior to the merge?
ZonedFreelistManager to mark a zone free. Signed-off-by: Abutalib Aghayev <agayev@psu.edu>
… the number of dead bytes of a zone on which the released extents are located. Signed-off-by: Abutalib Aghayev <agayev@psu.edu>
Signed-off-by: Abutalib Aghayev <agayev@psu.edu>
Signed-off-by: Abutalib Aghayev <agayev@psu.edu>
…on parameter. Signed-off-by: Abutalib Aghayev <agayev@psu.edu>
Signed-off-by: Abutalib Aghayev <agayev@psu.edu>
…at are currently being cleaned; also decrement free space after an allocation. Signed-off-by: Abutalib Aghayev <agayev@psu.edu>
Signed-off-by: Abutalib Aghayev <agayev@psu.edu>
@ifed01 Please take a look. It had a quite a bit of history so I couldn't squash them nicely, but gradually reapplied the whole diff in small commits that indvidually make sense. |
@tchaikov @ifed01 ceph API tests fail because the script that runs it does not specify -DWITH_ZBD=ON. I've created a PR to fix that: ceph/ceph-build#1802 |
jenkins test api |
should have been fixed by #40873 |
@tchaikov not sure that it will but let's see. |
Signed-off-by: Abutalib Aghayev <agayev@psu.edu>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me, just a few minor suggestions to cleanup logging
Signed-off-by: Abutalib Aghayev <agayev@psu.edu>
jenkins test docs |
@tchaikov can you please merge it? Thanks! |
@agayev i'd prefer running this change against the rados suite before merging it. |
Sounds good. Thanks! |
Checklist
Show available Jenkins commands
jenkins retest this please
jenkins test classic perf
jenkins test crimson perf
jenkins test signed
jenkins test make check
jenkins test make check arm64
jenkins test submodules
jenkins test dashboard
jenkins test api
jenkins test docs
jenkins render docs
jenkins test ceph-volume all
jenkins test ceph-volume tox