
The Google Cloud resources which are deployed initially are:Īny required APIs for Datastream, Dataflow, Cloud Storage, and Pub/Sub which are currently disabled are enabledĪ Cloud SQL for PostgreSQL destination instanceĪ Cloud Storage bucket to stage the data as it is transferred between Datastream and DataflowĪ Pub/Sub topic and subscription setup with Cloud Storage notifications to notify on the availability new filesĬonnectivity is tested to both the Oracle DB and the Cloud SQL for PostgreSQL instanceīefore you begin, ensure that the database you’d like to migrate is compatible with the usage of Datastream. It will also build several Docker images which are used to run Dataflow, Datastream, Ora2Pg, and Data Validation. The toolkit will deploy a number of resources used in the migration process. This bastion will be used to deploy resources, run Ora2Pg, and run data validation queries. The VM will be used as a bastion and will require access to the Oracle and PostgreSQL databases. Installing the Oracle to Postgres toolkit requires a VM with Docker installed.

This post will walk you through each stage in more detail, outlining the process and considerations we recommend for the best results. For instance, you can migrate one specific application's schema, while leaving the remainder of your application in Oracle. You can also use the toolkit to migrate partial databases. Since the process of migration tends to be iterative, try migrating a single table or single schema in a test environment before approaching production.

It can also be used to ensure downstream objects (like views or PL/SQL) have been translated correctly.Ĭutting over to use PostgreSQL, where the application switches from reading Oracle to Postgres.įollowing these steps will help to ensure a reliable migration with minimal business impact. Validating the data migration, which can be used to ensure all data was migrated correctly and it is safe to begin using the destination database. This allows you to migrate your data in a consistent fashion using CDC for low downtime. As new files are written, a Pub/Sub notification is emitted, and the files are picked up by Dataflow using a custom template to load the data into Cloud SQL for PostgreSQL. The stages of a database migration typically include:ĭeploying and preparing resources, where required resources are deployed and the docker images are built that will be used during the subsequent stages.Ĭonverting the schema with Ora2Pg, which is often an iterative process of converting, rebuilding, reviewing, and revising the schema until it aligns with your needs.Ĭontinuously migrating the data, which leverages Datastream and Dataflow.ĭatastream ingests the data from Oracle by reading the log using LogMiner, then stages the data in Google Cloud Storage. We have worked to simplify them, and created a detailed process with stages that are well-documented and easy to run. Migrations are a multi-step process, and can be complex and iterative. We can now standardize on this process and repeat it for our next databases, regardless of scale.” “Using Datastream's CDC capabilities, we were able to replicate our database securely and with low latency, resulting in minimal downtime to our application.

“As we’re modernizing our applications, replicating the database data reliably out of Oracle and into Cloud SQL for PostgreSQL is a critical component of that process,” says Shawn O’Rourke, manager of technology at MLB. Major League Baseball (MLB) used this toolkit to migrate their data from Oracle to Cloud SQL for PostgreSQL. The Oracle to Postgres toolkit uses a mix of existing open source and Google Cloud services, and our own Google-built tooling to support the process of converting schema, setting up low-latency, ongoing data replication, and finally performing migration validation from Oracle to Cloud SQL for PostgreSQL. To that end, we've built an open source toolkit that can help you migrate Oracle databases into Cloud SQL for PostgreSQL, and do so with minimal downtime and friction.
Postgresql serial repeat upgrade#
These databases are typically locked into on-premises data centers, expensive to upgrade and difficult to maintain. One of the biggest obstacles faced by enterprises pursuing digital transformation is the challenge of migrating off of legacy databases.
