Skip to content
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-16916 container: use ABT mutex to serialize cont open #15742

Open
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

wangdi1
Copy link
Contributor

@wangdi1 wangdi1 commented Jan 17, 2025

Use ABT mutex to serialize cont open.

Before requesting gatekeeper:

  • Two review approvals and any prior change requests have been resolved.
  • Testing is complete and all tests passed or there is a reason documented in the PR why it should be force landed and forced-landing tag is set.
  • Features: (or Test-tag*) commit pragma was used or there is a reason documented that there are no appropriate tags for this PR.
  • Commit messages follows the guidelines outlined here.
  • Any tests skipped by the ticket being addressed have been run and passed in the PR.

Gatekeeper:

  • You are the appropriate gatekeeper to be landing the patch.
  • The PR has 2 reviews by people familiar with the code, including appropriate owners.
  • Githooks were used. If not, request that user install them and check copyright dates.
  • Checkpatch issues are resolved. Pay particular attention to ones that will show up on future PRs.
  • All builds have passed. Check non-required builds for any new compiler warnings.
  • Sufficient testing is done. Check feature pragmas and test tags and that tests skipped for the ticket are run and now pass with the changes.
  • If applicable, the PR has addressed any potential version compatibility issues.
  • Check the target branch. If it is master branch, should the PR go to a feature branch? If it is a release branch, does it have merge approval in the JIRA ticket.
  • Extra checks if forced landing is requested
    • Review comments are sufficiently resolved, particularly by prior reviewers that requested changes.
    • No new NLT or valgrind warnings. Check the classic view.
    • Quick-build or Quick-functional is not used.
  • Fix the commit message upon landing. Check the standard here. Edit it to create a single commit. If necessary, ask submitter for a new summary.

Use ABT mutex to serialize cont open.

Signed-off-by: Di Wang <[email protected]>
@wangdi1 wangdi1 requested review from a team as code owners January 17, 2025 04:44
@wangdi1 wangdi1 requested a review from NiuYawei January 17, 2025 04:44
Copy link

github-actions bot commented Jan 17, 2025

Ticket title is 'ds_cont_local_open() Assertion 'hdl->sch_cont->sc_open == 1' failed: Unexpected open count for cont c6822a9a: 307'
Status is 'In Review'
https://daosio.atlassian.net/browse/DAOS-16916

jolivier23
jolivier23 previously approved these changes Jan 17, 2025
@@ -71,7 +71,7 @@ struct ds_cont_child {
sc_dtx_delay_reset : 1, sc_dtx_registered : 1, sc_props_fetched : 1, sc_stopping : 1,
sc_destroying : 1, sc_vos_agg_active : 1, sc_ec_agg_active : 1,
/* flag of CONT_CAPA_READ_DATA/_WRITE_DATA disabled */
sc_rw_disabled : 1, sc_scrubbing : 1, sc_rebuilding : 1, sc_open_initializing : 1;
sc_rw_disabled : 1, sc_scrubbing : 1, sc_rebuilding : 1;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

mentioned on your last patch but if you change these to semicolons, clang-format will look better and it's the same behavior.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ah, sure, missed that. Thanks!

NiuYawei
NiuYawei previously approved these changes Jan 17, 2025
Nasf-Fan
Nasf-Fan previously approved these changes Jan 20, 2025
@wangdi1 wangdi1 dismissed stale reviews from Nasf-Fan, NiuYawei, and jolivier23 via 641f9f3 January 23, 2025 19:47
@daosbuild1
Copy link
Collaborator

@daosbuild1
Copy link
Collaborator

Test stage Build on Leap 15.5 with Intel-C and TARGET_PREFIX completed with status FAILURE. https://build.hpdd.intel.com//job/daos-stack/job/daos/view/change-requests/job/PR-15742/3/execution/node/375/log

@daosbuild1
Copy link
Collaborator

Test stage Build RPM on EL 9 completed with status FAILURE. https://build.hpdd.intel.com//job/daos-stack/job/daos/view/change-requests/job/PR-15742/3/execution/node/363/log

@daosbuild1
Copy link
Collaborator

Test stage Build RPM on EL 8 completed with status FAILURE. https://build.hpdd.intel.com//job/daos-stack/job/daos/view/change-requests/job/PR-15742/3/execution/node/358/log

@daosbuild1
Copy link
Collaborator

Test stage Build RPM on Leap 15.5 completed with status FAILURE. https://build.hpdd.intel.com//job/daos-stack/job/daos/view/change-requests/job/PR-15742/3/execution/node/359/log

@daosbuild1
Copy link
Collaborator

Test stage Build DEB on Ubuntu 20.04 completed with status FAILURE. https://build.hpdd.intel.com//job/daos-stack/job/daos/view/change-requests/job/PR-15742/3/execution/node/327/log

NiuYawei
NiuYawei previously approved these changes Jan 24, 2025
Run-GHA: true
Allow-unstable-test: true
Required-githooks: true
@daosbuild1
Copy link
Collaborator

Test stage Build on Leap 15.5 with Intel-C and TARGET_PREFIX completed with status FAILURE. https://build.hpdd.intel.com//job/daos-stack/job/daos/view/change-requests/job/PR-15742/4/execution/node/360/log

@daosbuild1
Copy link
Collaborator

@daosbuild1
Copy link
Collaborator

Test stage Build RPM on EL 8 completed with status FAILURE. https://build.hpdd.intel.com//job/daos-stack/job/daos/view/change-requests/job/PR-15742/4/execution/node/350/log

@daosbuild1
Copy link
Collaborator

Test stage Build RPM on Leap 15.5 completed with status FAILURE. https://build.hpdd.intel.com//job/daos-stack/job/daos/view/change-requests/job/PR-15742/4/execution/node/334/log

@daosbuild1
Copy link
Collaborator

Test stage Build RPM on EL 9 completed with status FAILURE. https://build.hpdd.intel.com//job/daos-stack/job/daos/view/change-requests/job/PR-15742/4/execution/node/354/log

Since cont open process might be yield due if IV fetch needs to fetch
the property remotely, so sc_open counter might be larger than 1 if
property IV fetch failed.

Run-GHA: true
Allow-unstable-test: true
Required-githooks: true
Signed-off-by: Di Wang <[email protected]>
@wangdi1
Copy link
Contributor Author

wangdi1 commented Jan 24, 2025

@Nasf-Fan it looks like those sc_open counter might be larger than 1 if iv fetch failed? so I removed those assertion? thoughts?

@daosbuild1
Copy link
Collaborator

Test stage Build on Leap 15.5 with Intel-C and TARGET_PREFIX completed with status FAILURE. https://build.hpdd.intel.com//job/daos-stack/job/daos/view/change-requests/job/PR-15742/5/execution/node/361/log

@daosbuild1
Copy link
Collaborator

@daosbuild1
Copy link
Collaborator

Test stage Build RPM on EL 8 completed with status FAILURE. https://build.hpdd.intel.com//job/daos-stack/job/daos/view/change-requests/job/PR-15742/5/execution/node/327/log

@daosbuild1
Copy link
Collaborator

Test stage Build RPM on Leap 15.5 completed with status FAILURE. https://build.hpdd.intel.com//job/daos-stack/job/daos/view/change-requests/job/PR-15742/5/execution/node/328/log

@daosbuild1
Copy link
Collaborator

Test stage Build RPM on EL 9 completed with status FAILURE. https://build.hpdd.intel.com//job/daos-stack/job/daos/view/change-requests/job/PR-15742/5/execution/node/359/log

@daosbuild1
Copy link
Collaborator

Test stage Build DEB on Ubuntu 20.04 completed with status FAILURE. https://build.hpdd.intel.com//job/daos-stack/job/daos/view/change-requests/job/PR-15742/5/execution/node/350/log

fix build failure

Run-GHA: true
Allow-unstable-test: true
Signed-off-by: Di Wang <[email protected]>
Copy link

Functional on EL 8.8 Test Results

131 tests   127 ✅  1h 29m 51s ⏱️
 41 suites    4 💤
 41 files      0 ❌

Results for commit abaea27.

Copy link

Functional Hardware Large Test Results

65 tests   65 ✅  31m 5s ⏱️
14 suites   0 💤
14 files     0 ❌

Results for commit abaea27.

Copy link

Functional Hardware Medium Verbs Provider Test Results

55 tests   54 ✅  4h 39m 1s ⏱️
 7 suites   1 💤
 7 files     0 ❌

Results for commit abaea27.

@wangdi1 wangdi1 requested a review from NiuYawei January 25, 2025 05:07
Copy link
Contributor

@NiuYawei NiuYawei left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is a conflict to be resolved.

@@ -1630,59 +1630,55 @@ ds_cont_local_open(uuid_t pool_uuid, uuid_t cont_hdl_uuid, uuid_t cont_uuid,
*/
D_ASSERT(hdl->sch_cont != NULL);
D_ASSERT(hdl->sch_cont->sc_pool != NULL);

hdl->sch_cont->sc_open++;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggestion: simply moving ABT_mutex_lock() before sc_open++ would make code simpler, and you don't have to change the assertions in DTX code.

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

Successfully merging this pull request may close these issues.

5 participants