How to migrate one database to another postgres cluster?

If the server with postgresql. There are a lot-many databases-one for client. And then one day some of them will need to move and want to know in advance than to have to face. The Internet was met with the way, offering to make and restore the dump. There is another, perhaps faster, option?
March 19th 20 at 08:37
1 answer
March 19th 20 at 08:39
pg_dump + pg_restore is a very fast, if by "fast" mean overall time on task and minimal problems, not minimal window lost record.

In other cases, the transfer of the database you need some kind of logical replication. Or trigger something based on logical decoding (e.g. logical replication pg10+). Rake with any schema changes in the data set

Boundary case: if one or several databases it is necessary to move to the new cluster. Then do a streaming replica, when restartujete catch up to the wizard and removed her unnecessary of the base.

Find more questions by tags PostgreSQL