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

MDEV-30418 : Setting wsrep_slave_threads causes thread hang #3205

Open
wants to merge 1 commit into
base: 10.4
Choose a base branch
from

Conversation

janlindstrom
Copy link
Contributor

  • The Jira issue number for this PR is: MDEV-30418

Description

Problem was that wsrep was disconnected and new slave threads tried to connect to cluster but failed as
we were disconnected state.

Allow changing wsrep_slave_threads only when wsrep is enabled and we are connected to a cluster. In other cases report error and issue a warning.

Release Notes

TODO: What should the release notes say about this change?
Include any changed system variables, status variables or behaviour. Optionally list any https://mariadb.com/kb/ pages that need changing.

How can this PR be tested?

TODO: modify the automated test suite to verify that the PR causes MariaDB to behave as intended.
Consult the documentation on "Writing good test cases".

If the changes are not amenable to automated testing, please explain why not and carefully describe how to test manually.

Basing the PR against the correct MariaDB version

  • This is a new feature and the PR is based against the latest MariaDB development branch.
  • [x ] This is a bug fix and the PR is based against the earliest maintained branch in which the bug can be reproduced.

PR quality check

  • [x ] I checked the CODING_STANDARDS.md file and my PR conforms to this where appropriate.
  • [ x] For any trivial modifications to the PR, I am ok with the reviewer making the changes themselves.

Problem was that wsrep was disconnected and new slave
threads tried to connect to cluster but failed as
we were disconnected state.

Allow changing wsrep_slave_threads only when wsrep is enabled
and we are connected to a cluster. In other cases report
error and issue a warning.
@janlindstrom janlindstrom added the Codership Codership Galera label Apr 15, 2024
@robinnewhouse
Copy link
Contributor

This looks good to me! I just added one question, mainly for my own curiosity.

--connection node_2
select @@wsrep_slave_threads;
SET @cluster_address_orig = @@wsrep_cluster_address;
SET GLOBAL wsrep_cluster_address=AUTO;
Copy link
Contributor

Choose a reason for hiding this comment

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

I'm not very familiar with wsrep. Why does setting to AUTO put the node into a disconnected state?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Because AUTO is not correct node address see https://mariadb.com/kb/en/galera-cluster-system-variables/#wsrep_cluster_address, here naturally we intentionally set it incorrectly to get node out of cluster.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Codership Codership Galera
3 participants