Unable to bootstrap Node 1 of Pecona XtraDB cluster 8.0

Hi,

I have installed PXC 8.0 on 2 nodes (Ubuntu 20). After sufficient configuration to my.cnf file I am trying to bootstrap Node 1 as below:

systemctl start mysql@bootstrap.service

The command stuck for 1-2 mins and while looking into logs from another terminal it shows that node is now synced and ready for connection. But after 2-3 mins the command gets failed with below error:

Job for mysql@bootstrap.service failed because a timeout was exceeded.

See “systemctl status mysql@bootstrap.service” and “journalctl -xe” for details.

And log shows “Received shutdown signal” and then it shutdown completely.

I tried disabling MySQL Apparmor profile also, but no luck. I am not getting where is the issue.

Please help!

Below is the status check for failed service command:

systemctl status mysql@bootstrap.service

  • mysql@bootstrap.service - Percona XtraDB Cluster with config /etc/default/mysql.bootstrap

    Loaded: loaded (/lib/systemd/system/mysql@.service; disabled; vendor preset: enabled)

    Active: failed (Result: timeout) since Tue 2020-10-13 17:05:41 EDT; 3min 42s ago

    Process: 430436 ExecStartPre=/usr/bin/mysql-systemd start-pre (code=exited, status=0/SUCCESS)

    Process: 430483 ExecStartPre=/bin/sh -c systemctl unset-environment _WSREP_START_POSITION (code=exited, status=0/SUCCESS)

    Process: 430485 ExecStartPre=/bin/sh -c VAR=bash /usr/bin/mysql-systemd galera-recovery; [ $? -eq 0 ] && systemctl set-environment _WSREP_START_POSITION=$VAR || exit 1 (code=exited, >

    Process: 430533 ExecStart=/usr/sbin/mysqld $EXTRA_ARGS $_WSREP_START_POSITION (code=exited, status=0/SUCCESS)

    Process: 430666 ExecStopPost=/usr/bin/mysql-systemd stop-post (code=exited, status=0/SUCCESS)

    Main PID: 430533 (code=exited, status=0/SUCCESS)

Oct 13 17:03:55 db1.xyz.com systemd[1]: Starting Percona XtraDB Cluster with config /etc/default/mysql.bootstrap…

Oct 13 17:05:26 db1.xyz.com systemd[1]: mysql@bootstrap.service: start operation timed out. Terminating.

Oct 13 17:05:41 db1.xyz.com mysql-systemd[430666]: WARNING: mysql pid file /var/lib/mysql/mysqld.pid empty or not readable

Oct 13 17:05:41 db1.xyz.com mysql-systemd[430666]: WARNING: mysql may be already dead

Oct 13 17:05:41 db1.xyz.com systemd[1]: mysql@bootstrap.service: Failed with result ‘timeout’.

Oct 13 17:05:41 db1.xyz.com systemd[1]: Failed to start Percona XtraDB Cluster with config /etc/default/mysql.bootstrap.

Hello,

I had similar issues while I was testing the cluster on LXC.

check the configuration variables in /etc/mysql/my.cnf -

  • wsrep_node_address, wsrep_cluster_name, wsrep_node_name
  • check if the machines are reachable to each other

check the listening IP/port of the nodes (netstat -apn, for example) and its reachability machine <-> machine (use telnet

  • for example)

if you are testing on LXC/LXD, please try to set security nesting to containers (on LXDlxc config set sql5 security.nesting true

  • and restart the containers)

If it is was not helpful, can you please post full /etc/mysql/my.cnf and the output of cat /var/log/mysql/error.log?

Regards,

Martin