Search code examples
postgresqlgoogle-cloud-platformgoogle-cloud-sql

How to restore multiple databases on a single Google Cloud SQL for PostgreSQL instance to the same point in time?


I have 2 separate PostgreSQL databases in Google Cloud SQL for PostgreSQL. The databases should be separate due to security concerns, but they can reside in the same database instance. When restoring from a backup, it is important for me to have the databases restored to the same point in time, due to data relations.

I tried to understand how the backup works. I tried to research the backup documentation and restore one, but found no clue.

Can I be sure that restoring an instance would bring all its databases to the same point in time?


Solution

  • If you restore a Cloud SQL instance backup, it will restore all the databases in that instance to the point when backup was taken. One thing to note here is that if you restore the backup in the same instance it will overwrite the current data with the one in backup.

    You can see the General tips about performing a restore to further help you understand the restoration.