Repository navigation
crimson/os/seastore: implement generational GC - #46436
Conversation
|
This pull request can no longer be automatically merged: a rebase is needed and changes have to be manually resolved |
604eb24 to
fedad75
Compare
ea760ba to
4aa9fb3
Compare
It seems that, after the first 1500 secs, the number of segments whose utilization is under dropping, could you allow the test to keep running longer so that the stable segment usage distribution can emerge? And could you elaborate a little bit about the test environment and the segment usage distribution graph? like how large the seastore disk space and the rbd image is, what the curves in the graphs represent. It seems that the total number of segments in you seastore disk is about 5000~6000, so I guess you are not using the default seastore configuration, right? |
Do you mean that the bimodel distribution in the second graph is done by rewrites caused by journal trimming? |
No, I mean metadata and data, or generation 0, 1, 2 have different probabilities/rates to become invalid. If we split write them into different segments, the ideal bimodel distribution can be formed automatically. |
The disk and rbd image sizes are all 50G, the graph also shows the total number of segments is 800.
See ceph/src/crimson/os/seastore/segment_cleaner.h Lines 843 to 866 in 3b983cc The graph lines are stacked, so that the space between the two lines is the actual number of segments that falls in the according bucket. |
Ah, so the segment usage distribution is showing the number of segments whose utilization is under a specific percentage, right? |
Yes, and how they were evolved by time. |
31469d8 to
8c3a638
Compare
|
ready for review |
8c3a638 to
a1ec396
Compare
|
jenkins test api |
1 similar comment
|
jenkins test api |
|
This pull request can no longer be automatically merged: a rebase is needed and changes have to be manually resolved |
Place extents into the dedicated RecordSubmitter by their data-category and reclaimed-count. Segments of different data-category or reclaimed-count should have different locality in the access patterns, which is the foundation to form a desired bimodal distribution of segment utilizations, so that GC can be more efficient. Signed-off-by: Yingxin Cheng <[email protected]>
Signed-off-by: Yingxin Cheng <[email protected]>
Signed-off-by: Yingxin Cheng <[email protected]>
* record_header_t to store the average modify time for dirty extents. * Drop tracking rewrite-time. * Drop the last-modify field in extent_info_t. * Maintain modify-time during rewriting. * Introduce 3 GC policies: greedy, benefit, and cost-benefit. Signed-off-by: Yingxin Cheng <[email protected]>
Journal trimming may consume unexpected number of segments when the available ratio limit is reached with user transactions blocked, causing ceph_abort(). So increase the limit as a simple workaround. Signed-off-by: Yingxin Cheng <[email protected]>
a1ec396 to
f150c20
Compare
|
|
jenkins test make check |


This PR has 2 parts: generational-GC and policy-improvements.
I. Generational GC
Classify segments into 2 dimensions --- data category (data, metadata) and generation (0, 1, 2), totally 6 types of segments --- to improve the locality of block placements. This is the foundation to form a desired bimodal distribution of
segment utilizations for more efficient GC.
The profiling with rbd-fio (zipf-0.6) proves that the desired bimodal distribution has been formed. Note that reclaiming has been delayed as late as possible (see #46437), so that the first ~1500 seconds won't involve reclaiming, and the utility distribution below is accurate before 1500s:
II. Policy improvements
record_header_tto store the average modify time instead of the commit time to consider dirty extents.extent_info_t, which seems unnecessary right now.Final performance improvements with rbd-fio, zipf-0.6, 5400s
Policy selection
There are 3 GC policies available:
In theory, GREEDY policy should be the least efficient as it only considers segment utility. The result reclaim WAFs in rbd-fio(zipf-0.6, 5400s) are:
For reference, the original reclaim WAFs were:
Contribution Guidelines
To sign and title your commits, please refer to Submitting Patches to Ceph.
If you are submitting a fix for a stable branch (e.g. "pacific"), please refer to Submitting Patches to Ceph - Backports for the proper workflow.
Checklist
Show available Jenkins commands
jenkins retest this pleasejenkins test classic perfjenkins test crimson perfjenkins test signedjenkins test make checkjenkins test make check arm64jenkins test submodulesjenkins test dashboardjenkins test dashboard cephadmjenkins test apijenkins test docsjenkins render docsjenkins test ceph-volume alljenkins test ceph-volume toxjenkins test windowsFootnotes