Quick Start

Replicate Configurator

Replicate relies on a series of YAML-based configuration files to copy data from a source database to a destination database. Given the level of control these configuration files afford, crafting them by hand can be time-consuming.

The Replicate configurator command-line utility is an alternative method for creating these configuration files. By asking you a series of questions about your specific replication requirements, the configurator generates the corresponding configuration file(s) based on the answers you provide.

The configurator offers the following options:

Option Function
1. Source connection Creates connection details for a source database.
2. Destination connection Creates connection details for a MemSQL database.
3. Extractor Creates an extractor configuration file that can be used to fine-tune Replicate’s behavior when retrieving data from a source.
4. Applier Creates an applier configuration file that can be used to fine-tune Replicate’s behavior when applying changes to MemSQL.
5. Filter Creates a filter file that can be used to replicate only a specified subset of source data.
6. Mapper Creates a mapper file that can be used to precisely define how the source data is applied to the destination.
7. Command Line Generates the command that can be used to run Replicate based on the information provided in the above options. Note: Change to Replicate’s HOME directory before running the command.
0. Exit Exits the configurator.

Similar to Replicate, the configurator requires Java 8 to connect to databases and create configuration files.

Run the Configurator

  1. Change to the configurator’s HOME directory.

  2. In the configurator’s HOME directory, run:

    ./bin/replicate-configurator 
    

Sample Configurator Files

Below are samples files generated by the configurator.

Source Connection

Oracle

type: ORACLE
host: localhost
port: 1521
service-name: IO
username: 'replicate'
password: 'Replicate#123'
max-connections: 30

MemSQL

type: MEMSQL
host: localhost
port: 3306
username: "replicate"
password: "Replicate#123"
max-connections: 30

Destination Connection

MemSQL
type: MEMSQL
host: localhost
port: 3306
username: "replicate"
password: "Replicate#123"
max-connections: 30

Troubleshooting Replication

Replicate’s logs are stored in one of two directories in the Replicate HOME directory.

  1. If an instance name has not been assigned to Replicate:

    data/default/trace.log

  2. If an instance name has been assigned to Replicate via --id <instance_name>:

    data/<instance_name>/trace.log

The trace log is the best place to troubleshoot any errors experienced when running Replicate. The error messages written to this log will typically provide the required level of information to effectively troubleshoot an issue.