none
how to restore databse to last weekly full backup via az cli ? RRS feed

  • Question

  • i want to restore my db to the last weekly fully backup (hopefully it will take the minimum time ), i only undersetand how to restore to any time but how can  i restore to last fully backup? can i know when it happens ? 

    so far i used this command :

     
    az mysql server restore --resource-group <resourc_griup> --name "new_db"  --source-server "prod_db" --restore-point-in-time "2019-09-08T05:24:36Z"


    Sunday, September 8, 2019 11:57 AM

All replies

  • Hi

    For this kind of Point-in-time restorations we just need to mention the timestamp to which we would travel back and azure internally takes care of backup files to be used (Like Weekly full backup/Differential backup/ Transactional Log backup) based on the timestamp we provided to revert back.

    In general backups in Azure databases are taken as below

    • Full Backup - Weekly once
    • Differential Backup - For every 12hrs
    • Log Backup - Changes (Mostly for 5-10 min) based on transaction rate.

    Reference Link for more details.

    Hope the above content answered your question. Let me know if you are looking for any further information.

    Thanks


    If this post helps to resolve your issue, please click the "Mark as Answer" of that post and/or click Answered "Vote as helpful" button of that post. By marking a post as Answered and/or Helpful, you help others find the answer faster.

    Sunday, September 8, 2019 1:16 PM
  • i did not understand how to "mention the timestamp to which we would travel back and azure internally takes care of backup files to be used" , can i see the Full Backup - Weekly once last time ? 
    Sunday, September 8, 2019 1:19 PM
  • Hi

    We cannot see the automatic backup files as those are completely managed by azure.

    We just need to pass the timestamp to the cmd you are using.

    For full detailed query - Please use the Link.

    If you want to use the backup somewhere manually we can create backup using an export option which is quite different when compared with automated backup feature provided by Azure.

    Let me know if you need any further information

    Thank you


    If this post helps to resolve your issue, please click the "Mark as Answer" of that post and/or click Answered "Vote as helpful" button of that post. By marking a post as Answered and/or Helpful, you help others find the answer faster.

    Sunday, September 8, 2019 1:27 PM
  • i see that restore is taking me sometimes 2.5 H and other times 9 H , is there a way of tell how long the restore will take for different times ?  is there a better strategy than take last minute restore ?
    Sunday, September 8, 2019 1:38 PM
  • In general, it depends on the size of the data and database pricing tier.

    Microsoft also not guarantees the time limit. As a better strategy personally I don't go with restoring the databases always until necessary.

    Just to go with current need, try to create a new database rather than updating the existing one will be somewhat beneficial from timing standpoint. However that too don't have hard SLA's offered by Microsoft.

    Hope this helps!

    Thank you


    If this post helps to resolve your issue, please click the "Mark as Answer" of that post and/or click Answered "Vote as helpful" button of that post. By marking a post as Answered and/or Helpful, you help others find the answer faster.

    Sunday, September 8, 2019 1:43 PM
  • Just to provide high level information on latency time for restoration - it works as below.

    The estimated duration for the database to be fully functional after a restore/failover request. † Recovery Point Objective (RPO) - The amount of most recent data changes (time interval) the application could lose after recovery.

    Link for more details on Estimated restore time calculations.

    Thank you


    If this post helps to resolve your issue, please click the "Mark as Answer" of that post and/or click Answered "Vote as helpful" button of that post. By marking a post as Answered and/or Helpful, you help others find the answer faster.

    Sunday, September 8, 2019 2:04 PM
  • Hi

    I am writing to follow up this thread with you. Have you solved your issue? If you have solved your issue, please  mark helpful replies as answers. By doing so, it will benefit all community members who are having this similar issue. 

    Thank you


    If this post helps to resolve your issue, please click the "Mark as Answer" of that post and/or click Answered "Vote as helpful" button of that post. By marking a post as Answered and/or Helpful, you help others find the answer faster.

    Thursday, September 12, 2019 4:38 AM