JavaScript is required to for searching.
Skip Navigation Links
Exit Print View
Oracle Solaris Cluster Data Service for MySQL Cluster Guide     Oracle Solaris Cluster 4.1
search filter icon
search icon

Document Information

Preface

1.  Installing and Configuring HA for MySQL Cluster

A.  Files for Configuring HA for MySQL Cluster

B.  Deployment Example: Installing MySQL Cluster in the Global Zone

Target Cluster Configuration

Software Configuration

How to Install MySQL Cluster Software

Setting up the MySQL Cluster Control

How to Configure the Management Server on Both Nodes

How to Configure the Data Nodes on Both Nodes

How to Initialize the MySQL Server

How to Create the HA for MySQL Cluster Configuration With Scalable Services

Example Configuration Files for Installation in the Global Zone

config.ini File for Both Nodes to Store in /mgm-data

my.cnf File for the Data Nodes to Store in /ndbd-data

my.cnf File for the First SQL Node phys-schost-1 to Store in /mysql-data

my.cnf File for the Second SQL Node phys-schost-2 to Store in /mysql-data

mysql_config File for the First SQL Node phys-schost-1 to Store in /temp/cluconfig

mysql_config File for the Second SQL Node phys-schost-2 to Store in /temp/cluconfig

mysql_ndb_mgmd_config File for the First Node phys-schost-1

mysql_ndb_mgmd_config File for the Second Node phys-schost-2

mysql_ndbd_config File for the First Node phys-schost-2

mysql_ndbd_config File for the Second Node phys-schost-2

ndbd_shutdown_config File for One Node

ha_mysql_config File for One Node

Index

How to Configure the Data Nodes on Both Nodes

  1. Create the configuration.
    1. On both nodes create the data directory for the management server.
      phys-schost-1:/ # mkdir /ndbd-data
      phys-schost-2:/ # mkdir /ndbd-data
    2. Copy the my.cnf_ndbd file from /temp/cluconfig in the ndbd-data directory.
      phys-schost-1:/ # cp /temp/cluconfig/my.cnf_ndbd /ndbd-data/my.cnf
      phys-schost-2:/ # cp /temp/cluconfig/my.cnf_ndbd /ndbd-data/my.cnf
    3. Modify the my.cnf_ndbd file from /temp/cluconfig.

      Alternatively, copy the content from my.cnf File for the Data Nodes to Store in /ndbd-data and overwrite the copied file.

  2. Start the data nodes and verify the settings.
    phys-schost-1:/ # cd /ndbd-data
    phys-schost-2:/ # cd /ndbd-data
    
    phys-schost-1:/ndbd-data # /usr/local/mysql/bin/ndbd \
    > --defaults-file=/ndbd-data/my.cnf \
    > --ndb-connectstring=phys-schost-1-p:1186,phys-schost-2-p:1186 --ndb-nodeid=3
    phys-schost-2:/ndbd-data # /usr/local/mysql/bin/ndbd \
    > --defaults-file=/ndbd-data/my.cnf \
    > --ndb-connectstring=phys-schost-1-p:1186,phys-schost-2-p:1186 --ndb-nodeid=4
  3. On one node, check the data nodes.
    phys-schost-1:/ndbd-data # /usr/local/mysql/bin/ndb_mgm \
    > --ndb-connectstring=phys-schost-1-p,phys-schost-2-p -e show

    Note - Repeat the show command until both ndbd processes are fully up and running.


    Example output:

    phys-schost-1:/ # /usr/local/mysql/bin/ndb_mgm 
    > --ndb-connectstring=phys-schost-1-p,phys-schost-2-p -e show
    Connected to Management Server at: phys-schost-1-p:1186
    Cluster Configuration
    ---------------------
    [ndbd(NDB)]   2 node(s)
    id=3  @172.16.4.2 (mysql-5.1.35 ndb-7.0.7, Nodegroup: 0, Master)
    id=4  @172.16.4.1 (mysql-5.1.35 ndb-7.0.7, Nodegroup: 0)
    
    [ndb_mgmd(MGM)] 2 node(s)
    id=1  @172.16.4.2 (mysql-5.1.35 ndb-7.0.7)
    id=2  @172.16.4.1 (mysql-5.1.35 ndb-7.0.7)
    
    [mysqld(API)]  2 node(s)
    id=7 (not connected, accepting connect from phys-schost-1)
    id=8 (not connected, accepting connect from phys-schost-2)