Repository navigation
os/bluestore: unpin an onode in the shard that holds it - #73664
Conversation
|
jenkins test make check arm64 |
|
jenkins test make check |
|
The explanation for the bug is too detailed I think. What is missing the proper handling of the fact of changing I think the better solution would be to create function That way we would get: That way, we have 0 (zero) risk of messing up something between |
7e64833 to
44acf3e
Compare
Shortened, in both the commit message and the PR description.
Agreed, that is cleaner. Moved the body to |
maybe_unpin() takes the lock of the shard a split_cache() may have moved the onode to while the caller waited, but then works on this shard's lru, age_bins and num. An onode unpinned while its PG is split is thus linked and counted in the wrong shard, under the other shard's lock. Move the work to _maybe_unpin_do() and call it on the shard whose lock is held. In the tree since a3057f4 ("os/bluestore: fix onode ref counting"). Fixes: https://tracker.ceph.com/issues/82605 Signed-off-by: Ming Lei <[email protected]>
…oved out of Promote an onode in one shard, then call maybe_unpin() on another shard, as a caller does that read the collection's shard before a PG split moved the onode. The onode must stay with the shard that holds it: its age bin stamp stays there, the other shard's bins stay empty, and the holding shard can still evict it. Signed-off-by: Ming Lei <[email protected]>
44acf3e to
23e3194
Compare
|
This PR has been added to wip-jaya-bs-testing2-18-11-2026. |
|
This is an automated message by src/script/redmine-upkeep.py. I have resolved the following tracker ticket due to the merge of this PR: No backports are pending for the ticket. If this is incorrect, please update the tracker |
maybe_unpin()takes the lock of the shard asplit_cache()may have moved the onode to while the caller waited, but then works on this shard'slru,age_binsandnum. An onode unpinned while its PG is split is thus linked and counted in the wrong shard, under the other shard's lock. In the tree since a3057f4 (v18.1.0).Move the work to
_maybe_unpin_do()and call it on the shard whose lock is held. The unit test promotes an onode in one shard, callsmaybe_unpin()on another, and checks the onode stays with the holding shard.Split out of #73273 at ifed01's suggestion.
Fixes: https://tracker.ceph.com/issues/82605
Checklist