How to revive dropped Azure PostgreSQL flexible server with databases and data?
Testing some backup/recovery scenarios for my deployment.
One of them would be accidentally destroying an environment via terraform destroy
, including a flexible server for PostgreSQL with relevant data running in there.
Now, according to Azure's documentation you can do that via the API up to five days after the deletion, and you can specify a point in time there (for which you are supposed to take the timepoints of the destruction event, plus 5 or 10 minutes, doc is inconsistent there).
Then there is the CLI documentation with revive-dropped
where you can not specify a point in time - my assumption would be it just restores to the latest known state before deletion.
Both methods work, the deleted server reappears. But: no databases or data is present from before the deletion. I have tried multiple times, with/without UTC conversion, via the API (with 0/5/10 minutes added to deletion events, or using a time in point before the deletion), with the CLI. Every time, the server reappears 'empty', i.e. only with the system databases.
How do I restore the databases before the deletion event? Am I missing something?