备份流程(Microsoft Hyper-V 2012 R2 和更早版本)
For backup and replication of VMs that reside on SMB3 shares, Veeam Backup & Replication uses a native Hyper-V approach utilizing the Microsoft VSS framework. Veeam Backup & Replication acts as a VSS requestor: it communicates with the VSS framework and triggers a shadow copy of the necessary file share. The Microsoft VSS components create a file share shadow copy and present it to Veeam Backup & Replication that uses this shadow copy as a source for backup.
To properly quiesce VMs on SMB3 shares, Microsoft Hyper-V uses three VSS frameworks. These frameworks work at the level of the Hyper-V host and at the level of the SMB3 file server and communicate with each other:
- VSS framework on the Microsoft Hyper-V host (Hyper-V Host VSS). When Veeam Backup & Replication starts the backup or replication process, it communicates directly with the VSS framework on the Microsoft Hyper-V host where VMs are registered. The Hyper-V host VSS Service initiates creation of the file share shadow copy, freezes VM application writes and passes the request for shadow copy to the VSS for SMB File Shares framework. After the shadow copy is created, the Microsoft Hyper-V host VSS Service returns a path to the shadow copy to Veeam Backup & Replication.
- VSS for SMB File Shares. This framework is Microsoft’s extension to its VSS framework. VSS for SMB File Shares provides application-consistent shadow copies of VMs on SMB3 network shares. To work with shadow copies of file shares, VSS for SMB File Shares uses two components:
- File Share Shadow Copy Provider is a VSS provider for SMB3. The File Share Shadow Copy Provider is invoked on the Microsoft Hyper-V host where VMs are registered. The provider uses VSS APIs to interact with the VSS requestor, File Share Shadow Copy Agent and request creation of file shares shadow copies.
- File Share Shadow Copy Agent is a VSS requestor for SMB3. The File Share Shadow Copy Agent is invoked on the SMB3 file server. The agent interacts with the local VSS framework on the SMB3 file server to create a shadow copy of the requested file share.
- Local VSS framework on the SMB3 file server. This framework is responsible creating a shadow copy of the volume on which the file share is located, and exposing the shadow copy as a file share on the SMB3 server.
Backup of VMs on SMB3 shares is performed in the following way:
- Veeam Backup & Replication interacts with the Microsoft Hyper-V host VSS Service and requests a shadow copy of the necessary file share.
- The Hyper-V host VSS Service sends a request to create a shadow copy to the Microsoft Hyper-V host VSS Writer. The Microsoft Hyper-V host VSS Writer flushes buffers and holds application writes on VMs.
- The Microsoft Hyper-V host VSS Service sends a request for shadow copy creation to the File Share Shadow Copy Provider invoked on the Hyper-V host.
- The File Share Shadow Copy Provider relays the request to the File Share Shadow Copy Agent invoked on the SMB3 file server hosting the necessary file share.
- The File Share Shadow Copy Agent triggers a request for shadow copy creation to the local VSS on the SMB3 file server.
- The local VSS on the SMB3 file server uses the necessary shadow copy provider to create a shadow copy of the volume on which the necessary file share is located. The shadow copy is exposed as a file share on the SMB3 server. After that, application writes on VMs located on the original file share are resumed.
- The File Share Shadow Copy Agent returns a path to the shadow copy to the File Share Shadow Copy Provider.
- The File Share Shadow Copy Provider communicates this information to the Microsoft Hyper-V host VSS Service.
- Veeam Backup & Replication retrieves information about the shadow copy properties from the Microsoft Hyper-V host VSS Service.
- Veeam Backup & Replication uses the created shadow copy as a source for backup. After backup is complete, the file share shadow copy is deleted.
For more information, see Microsoft Docs.