Buy Percona ServicesBuy Now!

New Cluster: nodes 2 and 3 don't join but rather start their own clusters

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • New Cluster: nodes 2 and 3 don't join but rather start their own clusters

    Followed the instructions exactly by using copy/paste, changing nothing but the IP addresses involved.

    However. when I start the second node using the instructions above, it comes up not as a member of the cluster but isolated.

    first host:

    +--------------------------+--------------------------------------+
    | Variable_name | Value |
    +--------------------------+--------------------------------------+
    | wsrep_cluster_conf_id | 1 |
    | wsrep_cluster_size | 1 |
    | wsrep_cluster_state_uuid | f28ae440-cabb-11e7-976c-17bca5fe1b6b |
    | wsrep_cluster_status | Primary |
    +--------------------------+--------------------------------------+


    second host:
    +--------------------------+--------------------------------------+
    | Variable_name | Value |
    +--------------------------+--------------------------------------+
    | wsrep_cluster_conf_id | 1 |
    | wsrep_cluster_size | 1 |
    | wsrep_cluster_state_uuid | 9df5f23e-cabc-11e7-b6e2-030d02b0e16b |
    | wsrep_cluster_status | Primary |
    +--------------------------+--------------------------------------+


    Environment: Ubuntu 16.04, fresh install with only apt-get update && apt-get upgrade -y done prior to installing cluster. ufw firewall is disabled

    config from host 1:

    # Template my.cnf for PXC
    # Edit to your requirements.
    [mysqld]
    server-id=1
    datadir=/var/lib/mysql
    socket=/var/run/mysqld/mysqld.sock
    log-error=/var/log/mysqld.log
    pid-file=/var/run/mysqld/mysqld.pid
    log-bin log_slave_updates
    expire_logs_days=7

    # Disabling symbolic-links is recommended to prevent assorted security risks
    symbolic-links=0

    wsrep_provider=/usr/lib/libgalera_smm.so
    wsrep_cluster_name=pxc-cluster
    wsrep_cluster_address=gcomm://192.168.175.141,192.168.168.30
    wsrep_node_name=pxc1
    wsrep_node_address=192.168.175.141
    wsrep_sst_method=xtrabackup-v2
    wsrep_sst_auth=sstuserassw0rd
    pxc_strict_mode=ENFORCING
    binlog_format=ROW
    default_storage_engine=InnoDB
    innodb_autoinc_lock_mode=2


    config from host 2:
    # Template my.cnf for PXC
    # Edit to your requirements.
    [mysqld]
    server-id=2
    datadir=/var/lib/mysql
    socket=/var/run/mysqld/mysqld.sock
    log-error=/var/log/mysqld.log
    pid-file=/var/run/mysqld/mysqld.pid
    log-bin log_slave_updates
    expire_logs_days=7

    # Disabling symbolic-links is recommended to prevent assorted security risks
    symbolic-links=0

    wsrep_provider=/usr/lib/libgalera_smm.so
    wsrep_cluster_name=pxc-cluster
    wsrep_cluster_address=gcomm://192.168.175.141,192.168.168.30
    wsrep_node_name=pxc2
    wsrep_node_address=192.168.168.30
    wsrep_sst_method=xtrabackup-v2
    wsrep_sst_auth=sstuserassw0rd
    pxc_strict_mode=ENFORCING
    binlog_format=ROW
    default_storage_engine=InnoDB
    innodb_autoinc_lock_mode=2


    sst user was created on host 1
    +---------------+-----------+
    | user | host |
    +---------------+-----------+
    | mysql.session | localhost |
    | mysql.sys | localhost |
    | root | localhost |
    | sstuser | localhost |
    +---------------+-----------+
    +----------------------------------------------------------------------------------------+
    | Grants for sstuser@localhost |
    +----------------------------------------------------------------------------------------+
    | GRANT RELOAD, PROCESS, LOCK TABLES, REPLICATION CLIENT ON *.* TO 'sstuser'@'localhost' |
    +----------------------------------------------------------------------------------------+


    Logs are posted to https://pastebin.com/XLUjX7HF

    This seems to be similar to https://www.percona.com/forums/quest...fter-bootstrap and https://www.percona.com/forums/quest...ster-size-of-1 -- neither of which has an answer.


  • #2
    This is interesting, from your second node it says it had found a saved state on boot:

    Code:
    2017-11-16T11:03:01.282066Z mysqld_safe Assigning 9df5f23e-cabc-11e7-b6e2-030d02b0e16b:0 to wsrep_start_position
    Was the second node fresh install or was it part of the cluster before? Can you stop the second node, cleanup the data directory and start it again?
    Our documentation has a lot of answers about common questions on Percona software, have you checked there before posting that question here? http://www.percona.com/forums/core/i...lies/smile.png

    Join us at the annual Percona Live MySQL Users Conference - http://www.percona.com/live/mysql-conference-2014/

    Comment

    Working...
    X