Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for cross-region copy of incremental snapshots #19773

Closed
jamesc opened this issue Oct 4, 2021 · 11 comments
Closed

Support for cross-region copy of incremental snapshots #19773

jamesc opened this issue Oct 4, 2021 · 11 comments
Assignees
Labels
Compute az vm/vmss/image/disk/snapshot feature-request Ignite-2021-Nov

Comments

@jamesc
Copy link

jamesc commented Oct 4, 2021

Resource Provider
Microsoft.Compute

Description of Feature or Work Requested
Support CopyStart of incremental snapshots of managed disks via CLI. The REST API changes introduces a new option called CopyStart for the creationOption for creating snapshots of managed disks.

{ 
  "id": "/subscriptions/sub/resourceGroups/rg1e47ff76-fc12-483f-9c76-4b74673669ef/providers/Microsoft.Compute/disks/slowDisk",    
  "name": "slowDisk"    
  "type": "Microsoft.Compute/snapshots",    
  "location": "westus",    
  "sku": {    
    "name": "Standard_LRS",    
    "tier": "Standard"    
  },    
  "properties": {    
    "osType": "Windows",    
    "creationData": {    
      "createOption": "CopyStart", 
      "sourceResourceId": "/subscriptions/sub/resourceGroups/resg/providers/Microsoft.Compute/snapshots/mySnapshot
    }
  },    
  "tags": {    
    "department": "Development",    
    "project": "ManagedDisks"    
  }   
  "provisioningState": "Pending",  
  "completionPercent": 75 // readonly: ignored on inputs 
}   

Minimum API Version Required

Swagger Link

Example: https://github.com/rytruong/azure-rest-api-specs/blob/1f561a67f29460998e4ff8020e0691779ff50756/specification/compute/resource-manager/Microsoft.Compute/stable/2021-04-01/examples/CreateASnapshotFromAnExistingSnapshotInDifferentRegion.json

Target Date
Ignite

@ghost ghost added the needs-triage This is a new issue that needs to be triaged to the appropriate team. label Oct 4, 2021
@ghost ghost removed the needs-triage This is a new issue that needs to be triaged to the appropriate team. label Oct 4, 2021
@yonzhan yonzhan added Compute az vm/vmss/image/disk/snapshot needs-triage This is a new issue that needs to be triaged to the appropriate team. labels Oct 4, 2021
@ghost ghost removed the needs-triage This is a new issue that needs to be triaged to the appropriate team. label Oct 4, 2021
@yonzhan yonzhan added this to the Oct 2021 (2021-11-02) milestone Oct 4, 2021
@yonzhan
Copy link
Collaborator

yonzhan commented Oct 4, 2021

@zhoxing-ms for awareness

@zhoxing-ms
Copy link
Contributor

@jamesc So CLI needs to add a new parameter to support Copy Start, right? Could you provide the design which includes specific commands and parameters that need to be modified?

@evelyn-ys
Copy link
Member

May I know what's the difference between "createOption": "CopyStart" and "createOption": "Copy". For current CLI design, we identify createOption smartly from user input. Is it correct that:

  • The createOption is Copy if the target location is the same with the source resource's location
  • The createOption should be CopyStart if the target location is different from the source resource's location

@jamesc @grizzlytheodore @rytruong Can you help answer?

@evelyn-ys evelyn-ys self-assigned this Oct 11, 2021
@vikramd-ms
Copy link

Not necessarily. Copy can only be used within the same region. CopyStart can be used when source and target regions are different as well as when they are the same. There are important scenarios (copying across zones, copying from main region to edge location and other way around) where it is necessary to use CopyStart within the same region so CLI should allow it.

@ramankumarlive
Copy link

ramankumarlive commented Oct 11, 2021

@evelyn-ys you are correct, CLI should smartly use Copy and CopyStart. Here are the different scenarios:

  1. Cross-region copy of snapshot: Azure CLI calls DiskRP's Create Snapshot API by specifying createOption=CopyStart, customers dont have to know about it.

         az snapshot create -g MyResourceGroup -n MySnapshot2 --source MySnapshot1  --Region yourTargetRegion
    
  2. Create instantaneous snapshot by copying a disk in the same region: This is the current experience when CLI calls DiskRP's create snapshot API by specifying createOption=Copy.

         az snapshot create -g MyResourceGroup -n MySnapshot2 --source MyDisk
    
  3. Create snapshot by hard copying a disk to have hardened snapshots on ZRS in the same region. In this case, customers explicitly specify CopyStart as the creation option.

         az snapshot create -g MyResourceGroup -n MySnapshot2 --source MyDisk --CopyStart
    

@evelyn-ys
Copy link
Member

evelyn-ys commented Oct 12, 2021

Thanks @vikramd-ms @ramankumarlive. So we will autodetect CopyStart for cross-region scenario and provide an extra --copy-start to specify forcibly.

I found that createOption is a shared parameter for az disk create and az snapshot create. Do both az disk create and az snapshot create need to change or only az snapshot create need this?

@vikramd-ms
Copy link

CopyStart only applies to snapshots.

@arorasam
Copy link

arorasam commented Oct 25, 2021

This is a great facility! Few of question about CopyStart:

  1. When will this feature be avaialable worldwide as GA ?
  2. Any performance numbers how long CreateCopy operation takes to copy first snapshot (which should be full as none exists on the remote region) for Azure Storage pairs?
  3. Is this available in any regions right now (Oct 25) to try out, even as preview?

@evelyn-ys
Copy link
Member

Hi @arorasam, if you are asking CLI's release date, then it will be 11/02. I believe it's GAed from service side.
Leave other questions to service team @ramankumarlive @vikramd-ms

@ramankumarlive
Copy link

@arorasam

#1: We expect to announce the GA of the feature by the end of this month or early March.
#2: We dont have the performance numbers to share now. We can share the number by the end of April 2022.
#3: You can find the list of regions here: https://docs.microsoft.com/en-us/azure/virtual-machines/disks-incremental-snapshots?tabs=azure-cli#restrictions-1

@ramankumarlive
Copy link

@arorasam the feature in GA now worldwide.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Compute az vm/vmss/image/disk/snapshot feature-request Ignite-2021-Nov
Projects
None yet
Development

No branches or pull requests

8 participants