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

Storages: Only print errno instead of its string when CPU affinity of SegmentReader bind fail #8694

Merged
merged 6 commits into from
Jan 31, 2024

Conversation

JinheLin
Copy link
Contributor

@JinheLin JinheLin commented Jan 17, 2024

What problem does this PR solve?

Issue Number: close #9389

Problem Summary: printing the strerrno may cause data race under the new CI pipeline

      0x1141614e	StackTrace::StackTrace() [gtests_dbms+289497422]
       0x7e6baa4	fault_signal_handler(int) [gtests_dbms+132561572]
  0x7f054334c400	<unknown symbol> [libc.so.6+222208]
  0x7f054334f2bd	getenv [libc.so.6+234173]
  0x7f0543346e2e	__dcigettext [libc.so.6+200238]
  0x7f05433a2cde	strerror_r [libc.so.6+576734]
       0xdf52693	DB::DM::SegmentReader::setCPUAffinity() [gtests_dbms+234170003]
       0xdf52329	DB::DM::SegmentReader::run() [gtests_dbms+234169129]
       0xdf55de9	decltype(*(static_cast<DB::DM::SegmentReader*>(fp0)).*fp()) std::__1::__invoke<void (DB::DM::SegmentReader::*)(), DB::DM::SegmentReader*, void>(void (DB::DM::SegmentReader::*&&)(), DB::DM::SegmentReader*&&) [gtests_dbms+234184169]
       0xdf55d6e	void std::__1::__thread_execute<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, void (DB::DM::SegmentReader::*)(), DB::DM::SegmentReader*, 2ul>(std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, void (DB::DM::SegmentReader::*)(), DB::DM::SegmentReader*>&, std::__1::__tuple_indices<2ul>) [gtests_dbms+234184046]
       0xdf55a82	void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, void (DB::DM::SegmentReader::*)(), DB::DM::SegmentReader*> >(void*) [gtests_dbms+234183298]
  0x7f0543901ea5	start_thread [libpthread.so.0+32421]
  0x7f0543414b0d	clone [libc.so.6+1043213]

What is changed and how it works?

Only print the errno instead of its string

Check List

Tests

  • Unit test
  • Integration test
  • Manual test (add detailed scripts or steps below)
  • No code

Side effects

  • Performance regression: Consumes more CPU
  • Performance regression: Consumes more Memory
  • Breaking backward compatibility

Documentation

  • Affects user behaviors
  • Contains syntax changes
  • Contains variable changes
  • Contains experimental features
  • Changes MySQL compatibility

Release note

None

@ti-chi-bot ti-chi-bot bot added do-not-merge/needs-linked-issue release-note-none Denotes a PR that doesn't merit a release note. size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Jan 17, 2024
@JinheLin
Copy link
Contributor Author

/debug pull-unit-test

@purelind
Copy link
Collaborator

/debug pull-unit-test

The pipeline triggered in the current debug mode will not report the task link. The current triggered pipeline link is: https://do.pingcap.net/jenkins/blue/organizations/jenkins/pingcap%2Ftiflash%2Fpull_unit_test/detail/pull_unit_test/11/pipeline

@JinheLin JinheLin closed this Jan 18, 2024
@JaySon-Huang JaySon-Huang reopened this Jan 30, 2024
@JaySon-Huang
Copy link
Contributor

/debug pull-unit-test

2 similar comments
@JaySon-Huang
Copy link
Contributor

/debug pull-unit-test

@JaySon-Huang
Copy link
Contributor

/debug pull-unit-test

@JaySon-Huang JaySon-Huang changed the title Storages: Not set CPU affinity of SegmentReader in unittest Storages: Only print errno instead of its string when CPU affinity of SegmentReader bind fail Jan 31, 2024
Comment on lines +1564 to +1566
// Some old formats does not support ingest DMFiles.
if (mode == TestMode::V1_BlockOnly)
return;
Copy link
Contributor

Choose a reason for hiding this comment

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

comes from #8737 (comment)

@ti-chi-bot ti-chi-bot bot added needs-1-more-lgtm Indicates a PR needs 1 more LGTM. approved labels Jan 31, 2024
@ti-chi-bot ti-chi-bot bot added lgtm and removed needs-1-more-lgtm Indicates a PR needs 1 more LGTM. labels Jan 31, 2024
Copy link
Contributor

ti-chi-bot bot commented Jan 31, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: JaySon-Huang, Lloyd-Pottiger

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:
  • OWNERS [JaySon-Huang,Lloyd-Pottiger]

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

Copy link
Contributor

ti-chi-bot bot commented Jan 31, 2024

[LGTM Timeline notifier]

Timeline:

  • 2024-01-31 07:53:45.486816461 +0000 UTC m=+1552067.051114150: ☑️ agreed by JaySon-Huang.
  • 2024-01-31 08:39:44.641388278 +0000 UTC m=+1554826.205685983: ☑️ agreed by Lloyd-Pottiger.

@JaySon-Huang
Copy link
Contributor

/run-all-tests

@JaySon-Huang
Copy link
Contributor

/run-unit-test

1 similar comment
@purelind
Copy link
Collaborator

/run-unit-test

@ti-chi-bot ti-chi-bot bot merged commit 17ab097 into pingcap:master Jan 31, 2024
6 checks passed
@Lloyd-Pottiger
Copy link
Contributor

/cherry-pick-release-7.5

@Lloyd-Pottiger
Copy link
Contributor

/cherry-pick release-7.5

ti-chi-bot pushed a commit to ti-chi-bot/tiflash that referenced this pull request Aug 30, 2024
@ti-chi-bot
Copy link
Member

@Lloyd-Pottiger: new pull request created to branch release-7.5: #9388.

In response to this:

/cherry-pick release-7.5

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the ti-community-infra/tichi repository.

ti-chi-bot bot pushed a commit that referenced this pull request Aug 30, 2024
… SegmentReader bind fail (#8694) (#9388)

close #9389

Signed-off-by: ti-chi-bot <[email protected]>
Signed-off-by: Lloyd-Pottiger <[email protected]>

Co-authored-by: jinhelin <[email protected]>
Co-authored-by: Lloyd-Pottiger <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved lgtm release-note-none Denotes a PR that doesn't merit a release note. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Printing the strerrno may cause data race under the new CI pipeline
5 participants