Howdy my friend 🙂
This article is a 2nd part of a series regarding WVD deployment.
The first article could be found here:
https://www.azureblog.pl/2020/09/19/windows-virtual-desktop-deployment-1-5/
Today I’d like to walk you through the custom image creation using VHD file stored on a storage account (SA)
Prerequisites
Before we proceed please deploy 2 VM described below:
- VM1: OS: Windows 10 Enterprise multi-session, Version 2004., Disk Type: Unmanaged (on storage account)
VHD as an image source
As you might already know we can deploy VM in azure with unmanaged disks stored on a storage account.
Process for the image creation is depicted on a diagram below
- VM deployment – This is a standard VM deployment with VHD disk.
- VM configuration – this is a part when you configure , optimize and install all line of Business (LOB) applications i.e. Office, Acrobat Reader etc. You need to remember that this part ends up with sysprep (generalize / shutdown).
- Session host deployment – at this stage your VHD disk will be converted to Image and then used for session host deployment. You need to provide URI to the image file
VM Configuration
Our plan is to configure OS (install required updates), install Adobe Acrobat Reader DC (our imitation of the LOB applications) and then run sysprep.
I will skip the OS configuration and application installation and focus on the sysprep part.
Let’s go to the sysprep location (C:\Windows\System32\Sysprep) and run it.
Remember to use Generalize and Shutdown option
After sysprep process your VM will be stopped (not deallocated), so you need to deallocate the VM.
Then you can remove the following resources related to the VM1:
- Virtual machine
- Network Interface
- Public IP (if created)
- NSG (if created)
At the end of this process you should have only storage account with vhd file stored on it.
Copy the VHD file URL. We will use it in a moment during the Session host deployment.
So now we are prepared to deploy the new session host using our ‘GoldenImage’ from VHD source.
Open our host pool (created in previous article), and go to Session hosts configuration under the Manage section
On next screen click Add to launch Add virtual machines to a host pool screen
Skip the basic configuration and go to the Virtual Machines
The configuration is similar to the one which we did in previous article with one small difference. We are going to use Storage blob as an image source, and we want to use managed disks within our session host.
The rest of the configuration is same as it was last time.
During the deployment you might notice that there is a Image resource created under the resource group where you have WVD environment.
If everything went right you should be able to log in to the WVD environment and see Acrobat Reader DC on the screen.
From now you can use this Image during the new session hosts deployment.
You can do this using the following steps:
- During the Virtual Machine deployment chose Image type: Gallery
- Under Image section chose Browse all images and disks
3. Then under Select Image go to My Items tab.
4. From My Images section chose proper image.
The Image stored on a Shared Image Gallery (SIG) method will be a described in a second part of this article.
Comments are closed.