Closed MichielvanBeers closed 8 months ago
Hi @MichielvanBeers, thanks for bringing this up!
If you are going to restore to a database which already exists, you have to:
firebase firestore:databases:delete '(default)'
to accomplish this.Thanks for your answer @rwhogg. What would be your recommended way to do this with a production database? Since first deleting the whole database and then hoping that the restore will go correctly, feels a bit risky to me 😅
@MichielvanBeers sorry for the delay, the recommendations are now available here: https://firebase.google.com/docs/firestore/restore-in-place
Hi @rwhogg, that is great news, thank you! I will give this a try :)
Environment info
firebase-tools: 13.4.0
Platform: Windows
Test case
Steps to reproduce
(default)
firebase firestore:backups:schedules:create --recurrence DAILY --retention 7d
firebase firestore:backups:list
firebase firestore:backups:get projects/[project_id]/locations/eur3/backups/[backup_id]
firebase firestore:databases:restore --database '(default)' --backup projects/[project_id]/locations/eur3/backups/[backup_id]
Expected behavior
Actual behavior
Error: HTTP Error: 409, Database already exists. Please use another database_id
Output of command, including --debug flag
Thank you in advance!