在主机ndb1_mgmd_sqld1上执行如下过程:
shell>; ndb_mgmd -f /var/lib/mysql-cluster/config.ini
在两台主机上执行如下过程:
shell>;/usr/local/mysql/bin/ndbd
启动完ndbd进程后启动sqld进程:
shell>;/etc/init.d/mysql.server start
附:
config.ini中各部分解释:
[COMPUTER]: 定义群集主机.
[NDBD]: 定义群集数据节点.
[MYSQLD]: 定义Sql server节点.
[MGM|NDB_MGMD]: Defines the management server node in the cluster.
[TCP]: Defines TCP/IP connections between nodes in the cluster, with TCP/IP being the default connection protocol.
[SHM]: Defines shared-memory connections between nodes.
在MySQL 4.1.9之前,这个功能必须使用--with-ndb-shm option编译进去, 从MySQL 4.1.9-max版本开始, it is enabled by default。


