You are viewing an older version of this section. View current production version.
Join the MemSQL Community Today
Get expert advice, develop skills, and connect with others.

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 sometimes become time-consuming.

The Replicate configurator is a command-line utility that is an alternative to creating the desired Replicate configuration YAML files by hand. It requires Java 8 to connect to databases and create configuration files, and supports Oracle, PostgreSQL, MySQL, and MemSQL as a source, and only MemSQL as target.

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 sample files generated by the configurator.

Source Connection

Oracle

type: ORACLE

host: localhost
port: 1521

service-name: ORCL

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.