0

I have SonarQube MySQL DB (450GB) running and I want to Migrate to PostgreSQL DB.

I tried to migrate using MySQL-migrator (https://github.com/SonarSource/mysql-migrator), it takes long time and fails, we cannot RESUME as well. What is the simple and best way to Migrate from MySQL to PostgrSQl?

Mohan
  • 31
  • 1
  • 4

1 Answers1

1

500 GB is not large these days.

You should first try to get the schema definition right. Try to migrate without the data, that will be fast, and you can debug the migration of indexes, constraints, views and stored code. Once you have that, try to migrate the data (but of course you migrate the data before creating constraints and indexes).

I have no experience with the tools available, but you could investigate mysql_fdw. A foreign data wrapper has the advantage that you can migrate data in one step, without the need for intermediary storage. Also, it is easy to migrate several tables in parallel.

Laurenz Albe
  • 209,280
  • 17
  • 206
  • 263