Umbraco.Cloud.Issues icon indicating copy to clipboard operation
Umbraco.Cloud.Issues copied to clipboard

Database backup runs for a few hours and fail

Open bjarnef opened this issue 10 months ago • 2 comments

Issue description

On a Umbraco Cloud project me and a colleague tried creating a database backup of development database, it was running for 1-2 hours until it failed. Not much reason why, it prompted with a dialog and timeout error IIRC.

image

I connected to SSMS an exported development database using Export data tier application - it took about 8 minutes to complete.

image

bjarnef avatar Apr 19 '24 07:04 bjarnef

This has been solved now. However it took about 30 minutes for Development database and seems faster just connecting to database from SSMS and export database from there, which took about 8 minutes.

I wonder if something slow down the process?

The benefits from portal may be if we need to create backup of databases for each environment or it need to be shared while other developers as they could just download it from the portal.

bjarnef avatar Apr 25 '24 16:04 bjarnef

Howdy there @bjarnef 🤠

I can elaborate a bit on what is going on behind the scenes. When taking a backup from Cloud, we utilize Azure’s existing API, specifically the Point-in-time backup functionality. The benefit of this method is that it does not take resources away from the existing running database and infrastructure. The downside is that this process usually takes a bit longer and is also susceptible to how busy Azure is at the moment and is, and also the underlying operation.

Using the SSMS export tool is definitely still a viable option, but it would max out your DTU during the backup process. Additionally, I can’t find a way to automatically use these commands if we have to trigger them programmatically ;)

I hope that makes sense :)

mclausen avatar Jul 16 '24 13:07 mclausen