question

Gangadhara M.B avatar image
Gangadhara M.B asked Erick Ramirez commented

What is the best way to migrate from Postgres to Cassandra?

What is the best way or tools to use to migrate Postgres database on to Cassandra , without or with minimal downtime

Prod Postgres total database size comes around 250GB , there are 05 database each DB size comes around 50GB

Customer having majority of prod databases on Postgres(9.8.x) and few on Mysql(5.7.x) targeting to migrate them to Nosql databases Cassandra or MongoDB

Thanks

Gangadhara

migration
10 |1000

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

1 Answer

Erick Ramirez avatar image
Erick Ramirez answered Erick Ramirez commented

The easiest way is to export the data into CSV format from the source database(s). Once you have the raw CSV files, you need to do some transformation so you have CSV data that maps to each Cassandra table.

You can then use the DataStax Bulk Loader (DSBulk) tool to bulk load data in CSV format to a Cassandra table. Here are some references with examples to help you get started quickly:

DSBulk is open-source so it's free to use. Cheers!

2 comments Share
10 |1000

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

Gangadhara M.B avatar image Gangadhara M.B commented ·
If we try to use/follow the method/step you mentioned it is going to involve down time (from the time export the data from the source Postgres DB and import CSV data onto target Cassandra).

Are there any tools which does online data migration with no or minimal down time for the entire migration activity ?


Thanks

Gangadhara

0 Likes 0 ·
Erick Ramirez avatar image Erick Ramirez ♦♦ Gangadhara M.B commented ·
No. Otherwise, I would've mentioned them. :)
0 Likes 0 ·