Can you explain Snapshots versus generalized images for custom image batch pools

Matt Kotsenas 1 Reputation point
2021-02-19T19:48:24.427+00:00

According to the docs for Batch custom images (https://video2.skills-academy.com/en-us/azure/batch/batch-custom-images#prepare-a-managed-image) it says that only snapshots are recommended:

In Azure, you can prepare a managed image from:

  • Snapshots of an Azure VM's OS and data disks
  • A generalized Azure VM with managed disks
  • A generalized on-premises VHD uploaded to the cloud

To scale Batch pools reliably with a managed image, we recommend creating the managed image using only the first method: using snapshots of the VM's disks.

However later in the same article is a section called "Consideration for using Packer" (https://video2.skills-academy.com/en-us/azure/batch/batch-custom-images#considerations-for-using-packer) which doesn't use VM snapshots, but rather generalizes the VM using Sysprep and then captures the image.

To me this issue appears to be more appropriately asked in GitHub (https://github.com/MicrosoftDocs/azure-docs/issues/45202) however that issue was closed and it suggested to ask here instead.

Can you explain why generalized images are not recommended? And if Packer is supported, how it should be used?

Azure Virtual Machines
Azure Virtual Machines
An Azure service that is used to provision Windows and Linux virtual machines.
7,480 questions
Azure Batch
Azure Batch
An Azure service that provides cloud-scale job scheduling and compute management.
320 questions
{count} votes