Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
DAOS-14679 pool: Report on stopping sp_stopping #14374
DAOS-14679 pool: Report on stopping sp_stopping #14374
Changes from 4 commits
d2b0df9
d7ebda8
4358fdd
f1b991c
9078e35
4076db0
5713c2a
9ad231f
00bc5de
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
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.
If the sponsor of ds_pool_stop() is not the last user for the ds_pool, then the other reference holders may still use related pool_child. Under such case, is it possible to cause some race?
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.
Yes, I thought about this question too. I think if there's no other bug, there should be no other user of this
ds_pool
object. Moreover, if there were such a user, there was nods_pool_child
pointer inds_pool
. So, although that user might encounter some error, he should not encounter serious problems like segfaults.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.
The race may happen, for example, during
ds_pool_tgt_map_update
(), someone triggersds_pool_stop
() as to somepool_child
is released before collective tasks fords_pool_tgt_map_update
completed, such asdtx_resync
may get failure. It is risky for that becausedtx_resync
is global operation, if miss somepool_child
, it will affect DTX check result as to the decision. Further more, if the DTX leader wants to commit or abort some DTX, but related pool shard is closed, then it may leave orphan DTX entry on related pool shard. If the pool will be destroyed, it's OK; otherwise, it will be trouble. I am not aware of some know segmentation fault issues under such case, but really not sure for that.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.
I think I can pull in one more change originally planned for future work: Wait for all other
ds_pool
references to be released. If we do that before callingpool_child_delete_all
, the situation should become easier for otherds_pool
reference holders.The
dtx_resync
concern sounds like a different problem. Let's chat to understand where the problem is.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.
The root reason for
dtx_resync
trouble is not related with the patch, but the changes in this patch will increase the risk to expose thedtx_resync
trouble.