1

I'm trying to work out how to Restore the Latest Backup of a Database that is held on Azure Storage Blobs. This container contains other backups from different databases on a server but I'm only interested in Restoring the Latest Full and Diff Backup for a particular Database

I need to do this automatically via powershell or something and schedule it from a job.

I've looked at: Restore-SqlDatabase but can't see how it will use Azure credentials DBATools.io - Again nothing to pass in Azure credentials AzCopy - How do you get the latest Backup? Azure PowerShell - Again as above.

Any pointers would be greatly appreciated.

Thanks In Advance.

1

Restore-DbaDatabase does have -AzureCredential as parameter.

Suggest you to download the latest version of dbatools and try it.

Alternatively, you can try ps_restoregene - which is powershell based script written by Paul brewer. (I have used it and its a life saver :-) )

  • Thanks Kin. I must have missed that parameter :) I'll take another look. – craig king May 2 '18 at 8:10
  • 1
    Wen't with ps_restoregene. Working Great! Thank you so much for the pointer. – craig king May 3 '18 at 10:29

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.