Automating Citrix PVS Image Creation with MDT

30 Shares

PVS and MCS are designed for delivery of the gold image, they are not a replacement for automating the creation of that image. What’s going to happen in those environments where the gold image has been built manually and it either needs to be recreated or the delivery mechanism needs to be changed? That manual image has become a black box that will be difficult to reverse engineer.

Aaron Parker

My Automation Framework 3.0 was released last week, but unfornatly it doesn’t have support for Windows 10. The reason is that Microsoft have not yet released Microsoft Deployment Toolkit 2013 Update 1 (ETA August 2015) which will fully support Windows 10 deployments.

Now, while I wait for that I have some time to test the upcoming Citrix Provisioning Services 7.7 Tech Preview and something called Base Image Script Framework (BIS-F).

I was tipped about BISF at Citrix Synergy / E2EVC 2015 by Jonathan Pitre which is a customer and a big fan of the Automation Framework.

Like the amazing App-V Scheduler replaced my custom App-V Powershell script, I wanted to support BISF in my Automation Framework because it’s way more powerful, feature rich and has much better logging. Let’s get started!

First of, there’s a big bug with licensing so you need to install the Citrix Licensing Server on the Citrix Provisioning Server 7.7 itself. Thanks to Carl Webster for pointing that out.

Citrix PVS Server

Citrix PVS Target Device

Citrix XenConvert

BIFS

There´s currently a bug in BISF looking for XenConvert.exe in the Provisioning Services folder. Until this is fixed you simply copy the exe to that folder.

If you´re using the Windows 8 and Server 2012 Optimization Guide script you need to reenable some services required by XenConvert.

Automating Citrix PVS Image Creation with MDT 07

Edit PrepareBaseImage.cmd to configure silent mode.

You also need to specify the path to your PVS Write Cache Disk. I prefer using Group Policy, simply set and forget.

Automating Citrix PVS Image Creation with MDT 08

Microsoft Deployment Toolkit Configuration

Now run a Command Line with Administrator permissions as per BISF documentation.

Automating Citrix PVS Image Creation with MDT 05

Automating Citrix PVS Image Creation

For VMware select to Boot to BIOS.

Automating Citrix PVS Image Creation with MDT 02

Set the Boot Order to 1st CD-Rom and 2nd to Network Boot.

Automating Citrix PVS Image Creation with MDT 03

Grab the MAC address and add it to PVS.

Automating Citrix PVS Image Creation with MDT 09

Make sure it’s set to Boot from Hard Disk.

Automating Citrix PVS Image Creation with MDT 10

Start the VM on the MDT Boot Image and select your Task Sequence.

Automating Citrix PVS Image Creation with MDT 06

After the deployment starts you need to change the ISO from the MDT Boot Image to your Citrix Provisioning Services BDM image.

If you’re using PXE boot I guess you don’t need to do anything, but this haven´t been tested in my lab though.

I prefer to use BDM instead of interferring with other PXE services.

Automating Citrix PVS Image Creation with MDT 01

You can automated it even more by adding the MACAddress to CustomSettings.

That’s Automating Citrix PVS Image Creation with MDT and BISF.

All my blog posts about Automation is already part of my Automation Framework and are Ready To Go. You can now buy the Automation Framework as a standalone product.

Automation Framework 03

30 Shares

Automation Framework Community Edition

The fastest way to build your lab environment.

Virtual Expo

Friday 30th of September 2022

9 thoughts on “Automating Citrix PVS Image Creation with MDT”

  1. I Support this message 😀 Thanks Eric for taking the time to integrate BIS-F into you’re automation framework, much appreciated.

    Reply
  2. Hey Trond.

    Great post with a lot of goodies. I wanted to find out from you regarding the BISF installation in the task sequence. In you’re screenshot it appears that you have a file called setup.exe installing BISF, then in you’re task sequence folder you have a task sequence step called “Base Image Script Framework” followed by “Start BISF”.

    Is the first on “Base Image Script Framework” just doing a copy to the C:\Scripts folder on the base image and then once that is done it starts the script?

    Reply
  3. If you run a P2PVS conversion from within a MDT task sequence won’t your BaseImage contain the MDT folders (MININT and _SMSTaskSequence)?

    Reply
    • By default yes, but some custom code fixes that.

      Echo Removing remnants of MDT from the PVS vDisk…

      IF EXIST D:\MININT SET PVSvDisk=D
      IF EXIST E:\MININT SET PVSvDisk=E
      IF EXIST F:\MININT SET PVSvDisk=F
      IF EXIST G:\MININT SET PVSvDisk=G

      IF EXIST “%PVSvDisk%:\MININT” RD /Q /S “%PVSvDisk%:\MININT”
      IF EXIST “%PVSvDisk%:\_SMSTaskSequence” RD /Q /S “%PVSvDisk%:\_SMSTaskSequence”
      IF EXIST “%PVSvDisk%:\ProgramData\Microsoft\Windows\Start Menu\Programs\Startup\LiteTouch.lnk” DEL /Q “%PVSvDisk%:\ProgramData\Microsoft\Windows\Start Menu\Programs\Startup\LiteTouch.lnk”

      Reply

Leave a Comment