6.11.2.2. Installing Cassandra Replication (INI Method)

INI configuration of the replication deployment to Cassandra is done by specifying a different INI configuration for the master and slave hosts.

  1. Configure the ini parameters for the master replicator service:

    [defaults]
    user=tungsten
    install-directory=/opt/replicator
    replication-port=3306
    profile-script=~/.bashrc
    skip-validation-check=HostsFileCheck
    start-and-report=true
    
    [alpha]
    master=mysqldb01
    members=mysqldb01,cassandra01
    replication-user=tungsten
    replication-password=secret
    disable-relay-logs=true
    enable-heterogeneous-service=true
    
    

    The description of each of the options is shown below; click the icon to hide this detail:

    Click the icon to show a detailed description of each argument.

  2. Configure the ini parameters for the slave host that will apply the events to Cassandra:

    [defaults]
    user=tungsten
    install-directory=/opt/replicator
    replication-port=3306
    profile-script=~/.bashrc
    skip-validation-check=HostsFileCheck
    skip-validation-check=InstallerMasterSlaveCheck 
    skip-validation-check=DatasourceDBPort \
    skip-validation-check=DirectDatasourceDBPort \
    skip-validation-check=ReplicationServicePipelines \
    start-and-report=true
    
    [alpha]
    batch-enabled=true
    batch-load-language=js
    batch-load-template=cassandra
    datasource-type=file
    master=ubuntuheterosrc
    members=cassandra
    property=replicator.datasource.applier.csvType=cassandra
    property=replicator.datasource.global.csvType=cassandra
    property=replicator.stage.q-to-dbms.blockCommitInterval=5s
    property=replicator.stage.q-to-dbms.blockCommitRowCount=1000
    replication-password=secret
    replication-user=tungsten
    svc-applier-filters=dropstatementdata
    start-and-report=true
    

    This configures the Cassandra slave to accept replication data from the master.

    The description of each of the options is shown below; click the icon to hide this detail:

    Click the icon to show a detailed description of each argument.

  3. Using the INI method requires that the following steps be performed on EVERY node:

    1. Unpack the Tungsten Replicator distribution in the staging directory:

      shell> tar zxf tungsten-replicator-tungsten-replicator-5.3.3-604.tar.gz
    2. This step should only be performed on any replicator slave node that will be applying to Cassandra.

      Locate the Cassandra JDBC driver. This can be downloaded separately from the Cassandra website. The driver will need to be copied into the Tungsten Replication lib directory.

      shell> cp cassandra-jdbc-7.1.2-0.jar tungsten-replicator-5.3.3-604/tungsten-replicator/lib/
    3. Change into the staging directory:

      shell> cd tungsten-replicator-tungsten-replicator-5.3.3-604
    4. Install the services:

      shell> ./tools/tpm install

If you encounter problems during the installation, check the output of the /tmp/tungsten-configure.log file for more information about the root cause.

Once the service is configured and running, the service can be monitored as normal using the trepctl command. See Section 6.11.3, “Management and Monitoring of Cassandra Deployments” for more information.