# Data Migration Tools: Which One Fits the Job? | gen2.dev

> Change data capture with Debezium, online schema changes with gh-ost, loading into PostgreSQL with pgloader and AWS DMS: which tool fits which migration step.

Source: https://gen2.dev/guide/data-migration-tools/

---

Field Guide

# Data migration tools: copy, replicate or change in place

Pick the tool by the job: moving data once, keeping two stores in step, or changing a live table without blocking it.

![Slide: three jobs for data tools: copy once, replicate continuously and change a live table, each with a named tool.](https://gen2.dev/img/data-migration-tools.png)

Most data migrations need more than one of these, in order: load the history, keep the new store current, then switch. The [dual write](https://gen2.dev/guide/dual-write/) and [expand and contract](https://gen2.dev/guide/expand-and-contract/) pages cover the sequence; this page covers the tools.

## The options

Job

Tool

What it says it does

Keep a second store current from the database log

Debezium

Change data capture: it reads changes and publishes them as events

Change a live MySQL table

gh-ost

"a triggerless online schema migration solution for MySQL"

Load into PostgreSQL

pgloader

"loads data from various sources into PostgreSQL"

A managed migration service

AWS DMS

"makes it possible to migrate relational databases, data warehouses, NoSQL databases, and other types of data stores"

## Change data capture

Instead of the application writing twice, a tool reads the source database's transaction log and replays each change. It sees every write, including batch jobs and scripts nobody remembers. The price is another piece of infrastructure and a copy that lags slightly.

## Online schema change

gh-ost describes itself as "testable" with "pausability, dynamic control/reconfiguration, auditing, and many operational perks." It builds a copy of the table, applies the change there and swaps it in, so the table stays usable during the work.

## Bulk loading

pgloader reads files, including CSV and fixed formats, and databases including SQLite, MySQL, MS SQL Server, PostgreSQL and Redshift, and "manages errors by filling a pair of reject.dat and reject.log files." Read those files. Rejected rows are the migration's real test results.

## When not to use it

-   **An outage of an hour is acceptable** and the data is small. Dump, restore and verify.
-   **The platform already offers it.** A managed database's own copy or replica feature may be enough.
-   **Nobody will operate the tool.** A running pipeline needs monitoring.
-   **The data needs rewriting by business rules.** A tool moves rows; your code decides what they mean.

## Checklist

-   The history is loaded and rerunnable.
-   The new store is kept current, and lag is measured.
-   Row counts, totals and samples are compared, as in [verification](https://gen2.dev/guide/dual-write/).
-   Rejected rows have an owner.
-   There is a date to turn the tool off.

## Sources

1.  [Debezium documentation - features](https://debezium.io/documentation/reference/stable/features.html) - change data capture from database logs
2.  [github/gh-ost - README](https://github.com/github/gh-ost) - triggerless online schema migration for MySQL
3.  [pgloader documentation - Introduction](https://pgloader.readthedocs.io/en/latest/intro.html) - loading data into PostgreSQL from files and other databases
4.  [What is AWS Database Migration Service? - AWS documentation](https://docs.aws.amazon.com/dms/latest/userguide/Welcome.html) - a managed service for migrating databases

Last updated November 29, 2026.

## Field Guide

-   [Rewrite vs refactor](https://gen2.dev/guide/rewrite-vs-refactor/)
-   [The 7 Rs](https://gen2.dev/guide/seven-rs/)
-   [Characterization tests](https://gen2.dev/guide/characterization-tests/)
-   [Estimating a rewrite](https://gen2.dev/guide/estimating-a-rewrite/)
-   [Strangler fig pattern](https://gen2.dev/guide/strangler-fig/)
-   [Monolith to microservices](https://gen2.dev/guide/monolith-to-microservices/)
-   [Lift and shift](https://gen2.dev/guide/lift-and-shift/)
-   [Second-system effect](https://gen2.dev/guide/second-system-effect/)
-   [Branch by abstraction](https://gen2.dev/guide/branch-by-abstraction/)
-   [Anti-corruption layer](https://gen2.dev/guide/anti-corruption-layer/)
-   [Parallel run](https://gen2.dev/guide/parallel-run/)
-   [Shadow traffic](https://gen2.dev/guide/shadow-traffic/)
-   [Dual write and data migration](https://gen2.dev/guide/dual-write/)
-   [Expand and contract](https://gen2.dev/guide/expand-and-contract/)
-   [Data migration tools](https://gen2.dev/guide/data-migration-tools/)
-   [The cutover](https://gen2.dev/guide/cutover/)
-   [Feature flags and dark launches](https://gen2.dev/guide/feature-flags-and-dark-launches/)
-   [Big-bang cutover](https://gen2.dev/guide/big-bang-cutover/)
-   [API versioning](https://gen2.dev/guide/api-versioning/)
-   [Running two systems](https://gen2.dev/guide/running-two-systems/)
-   [Killing Gen 1](https://gen2.dev/guide/killing-gen-1/)
-   [Rewriting a mobile app](https://gen2.dev/guide/rewriting-a-mobile-app/)
-   [Selling a rewrite](https://gen2.dev/guide/selling-a-rewrite/)
-   [AI-written code](https://gen2.dev/guide/ai-written-code/)

## Should we rewrite it?

Sixteen questions about your system. A recommendation, and the reasoning behind it.

[Start the questions](https://gen2.dev/should-we-rewrite/)
