I followed this tutorial to create a multi-node MySQL Cluster deployed on AWS EC2 instances.
I can query the master node using:
mysql -u root -D mydb -h <master_ip> -P 3306
But if I do the same but with a slave node IP, I get:
ERROR 2002 (HY000): Can't connect to server on '3.86.164.48' (115)
Here's my /etc/mysql/my.cnf
file for the master node:
!includedir /etc/mysql/conf.d/
!includedir /etc/mysql/mysql.conf.d/
[mysqld]
# Options for mysqld process:
ndbcluster # run NDB storage engine
bind-address=0.0.0.0
skip-grant-tables
[mysql_cluster]
# Options for NDB Cluster processes:
ndb-connectstring=<master-ip-internal> # location of management server
And the /etc/my.cnf
file for the slave nodes:
[mysql_cluster]
# Options for NDB Cluster processes:
ndb-connectstring=<master-ip-internal> # location of cluster manager