How To Set Up A Load-Balanced MySQL Cluster - Page 2
3 Set Up The MySQL Cluster Nodes (Storage Nodes)Now we install mysql-max-5.0.19 on both sql1.example.com and sql2.example.com: sql1.example.com / sql2.example.com: groupadd mysql Then we create the MySQL configuration file /etc/my.cnf on both nodes: sql1.example.com / sql2.example.com: vi /etc/my.cnf
Make sure you fill in the correct IP address of the MySQL cluster management server. Next we create the data directories and start the MySQL server on both cluster nodes: sql1.example.com / sql2.example.com: mkdir /var/lib/mysql-cluster (Please note: we have to run ndbd --initial only when the start MySQL for the first time, and if /var/lib/mysql-cluster/config.ini on loadb1.example.com changes.) Now is a good time to set a password for the MySQL root user: sql1.example.com / sql2.example.com: mysqladmin -u root password yourrootsqlpassword We want to start the cluster nodes at boot time, so we create an ndbd init script and the appropriate system startup links: sql1.example.com / sql2.example.com: echo 'ndbd' > /etc/init.d/ndbd
|



Recent comments
1 day 4 hours ago
1 day 13 hours ago
1 day 16 hours ago
1 day 17 hours ago
1 day 18 hours ago
1 day 20 hours ago
1 day 21 hours ago
1 day 23 hours ago
2 days 15 hours ago
2 days 15 hours ago