mysql集群配置全过程让你轻松学
mysql集群配置全过程让你轻松学
给两个文件赋权限:
chmod -R 1777 /var/lib/mysql
chmod -R 1777 /var/lib/ mysql-cluster
//------------------------------------------------------------------以这个结束
管理节点安装:
MySQL-Cluster-gpl-management-7.0.9-0.rhel4.x86_64.rpm;
MySQL-Cluster-gpl-tools-7.0.9-0.rhel4.x86_64.rpm;
Rpm –ivh MySQL-Cluster-gpl-management-7.0.9-0.rhel4.x86_64.rpm
Rpm –ivh MySQL-Cluster-gpl-tools-7.0.9-0.rhel4.x86_64.rpm
vi /var/lib/mysql-cluster/config.ini
[ndbd default]
NoOfReplicas=2
DataMemory=80M
IndexMemory=18M
[tcp default]
SendBufferMemory=2M
ReceiveBufferMemory=2M
[NDB_MGMD DEFAULT]
PortNumber=1186
Datadir=/var/lib/mysql-cluster
[ndb_mgmd]
Id=1
HostName= 192.168.1.14
[ndbd]
Id=2
HostName=192.168.1.15
datadir=/var/lib/mysql/data
[ndbd]
Id=3
HostName= 192.168.1.11
datadir=/var/lib/mysql/data
[mysqld]
Id=14
HostName=192.168.1.15
[mysqld]
Id=15
HostName=192.168.1.11
[mysqld]
Id=16