Skip to content

Innodb Cluster FAQs

klouddb edited this page Sep 16, 2020 · 9 revisions

1. When you invoke shell.connect('clusterusr@node1:3306') it does not ask password from second time . Why is it so ? Where does Innodb cluster save its passwords ?

It stores the password in vault (similar to what config_editor does) during the first connection . From second connection it does not prompt for password

You can use mysql_config_editor --print all to check what is already stored

2. Can we use 2 nodes in Innodb cluster instead of 3 nodes ?

It is recommended to have odd number of nodes .In order to be able to avoid split brain, a cluster needs an odd number of members.
So start with 3 nodes to avoid any split-brain situations

3. Router Vs ProxySQL - What is the difference ?

ProxySQL supports query routing (read/write splitting) , query caching etc.. It is level 7 proxy where as router is level 4

4. How to change primary node ?

In 5.7 you can not change the primary of a given cluster easily. Lets say you have node A, node B and node C in a cluster . Currently node A is the primary node in cluster and you want to promote node C as master now , only way to do that is to run “stop group_replication” until the desired node is master . Or another way of approaching it in 5.7 is by changing the weight of member

In version 8.0 you can do that by using ‘select group_replication_set_as_primary(member_uuid);’

5. Which ports need to be open for Innodb cluster ?

3306 --> MySQL port
33060 --> MySQL X port
33061 --> Group replication communication port

6. How do you check the status of Innodb cluster - How to know the primary node ?

To find out which server is currently the primary when deployed in single-primary mode, use the MEMBER_ROLE column in the performance_schema.replication_group_members table. For example:

mysql> SELECT MEMBER_HOST, MEMBER_ROLE FROM performance_schema.replication_group_members;
+-------------------------+-------------+
| MEMBER_HOST             | MEMBER_ROLE |
+-------------------------+-------------+
| remote1.example.com     | PRIMARY     |
| remote2.example.com     | SECONDARY   |
| remote3.example.com     | SECONDARY   |
+-------------------------+-------------+

7. How to stop/start Innodb cluster for maintenance ?

8. How to identify the node that is ahead of other members ?

9. What are some of the limitations of Innodb cluster ?

10. What engines are supported by Innodb cluster ?