ora_migrator
ora_migrator · Tools to migrate Oracle databases to PostgreSQL
Overview
| ID | Extension | Package | Version | Category | License | Language |
|---|---|---|---|---|---|---|
| 100133 | ora_migrator | ora_migrator | 1.1.0 | ETL | PostgreSQL | SQL |
PostgreSQL · 10, 11, 12, 13, 14, 15, 16, 17, 18
| Relationships | |
|---|---|
| Requires | db_migrator oracle_fdw |
Usage
Sources:
ora_migrator is the Oracle plugin for db_migrator. It uses oracle_fdw to inspect an Oracle database, stage editable migration metadata, copy data and objects, and optionally run trigger-based change capture for a low-downtime cutover.
Core Workflow
Install the declared dependencies, create an oracle_fdw server and user mapping, then prepare and review the staging schemas before copying anything.
Oracle schema names are normally uppercase, so values passed through only_schemas must use the Oracle spelling. max_long controls the oracle_fdw limit applied to LONG, LONG RAW, and XMLTYPE columns.
Migration and Replication Objects
create_oraviewsbuilds the Oracle dictionary foreign tables used by the plugin.oracle_test_tableandoracle_migrate_test_datacheck for zero bytes, encoding failures, and other data-conversion problems after preparation.db_migrator_callbackintegrates Oracle-specific discovery and translation with the generic migration pipeline.oracle_replication_start,oracle_replication_catchup, andoracle_replication_finishmanage temporary Oracle log tables and triggers plus PostgreSQL staging objects.
Low-Downtime Boundary
For replication, pause Oracle writes while oracle_replication_start and the initial db_migrate_tables transition are established. Catch-up runs at Oracle SERIALIZABLE isolation; perform the final catch-up with writes stopped, then cut the application over. The source user needs dictionary access, and replication needs substantial table and trigger privileges on Oracle. session_replication_role may need to be replica during catch-up to avoid firing target-side triggers and foreign-key checks.
Not every Oracle partitioning feature is supported. Ensure Oracle has enough UNDO for the consistent snapshot, review pgsql_stage.migrate_log, and remember that oracle_replication_finish removes objects on both systems. PostgreSQL 9.5+, oracle_fdw, and db_migrator are upstream prerequisites.