When Updating XenDesktops Pooled Machine Catalog Old Base Disk is not Deleted

When Updating XenDesktops Pooled Machine Catalog Old Base Disk is not Deleted

book

Article ID: CTX210024

calendar_today

Updated On:

Description

When updating XenDesktop 7.x  pooled Machine Catalog the old Base disk is not deleted.
No errors are seen or logged.

Resolution

There are a couple of solutions for this issue.

1. Create a new Machine Catalog in XenDesktop. 

or

2. Use the search node in Citrix Studio and select the filter "Pending Update" is "True". Any machines listed in this state are still referencing an old image which will prevent the image from being deleted. Start (or restart) all the machines listed and wait until there are no machines in this state. Once that is the case the old images will be cleaned up by a background task, this process can take 6-8 hours as the checking process is only run periodically.

NOTE: You can fine tune this background process to suit your environment using PowerShell.
 
From PowerShell you want to use the Set-ProvServiceConfigurationData cmdlet and the set the following values
 
  • DiskReaper_retryInterval - this defines how often each disk is checked, format is hh:mm:ss.ff, where the seconds (ss) and fractions (ff) are optional. (Default is 6 hours.)
 
  • DiskReaper_heartbeatInterval - defines how often the check process runs to see if there is any pending work, in the same format, this will be constrained to be at most 1/5 of the retry interval so that there are at least 5 checks performed within the larger time space (it also cannot be 0). (Default is 1 hour.)
 
NOTE:  the basic behavior (with the default time) is that a background process runs every hour and checks if there are any disks that haven't been checked for more than 6 hours. If there are then those disks are checked to see if it is safe to remove them (i.e. all VMs that were previously using the disk have now been updated to use a newer disk). If there are no VMs remaining for a given disk it will be deleted.
 
So, if you want the system to check more often you can set the heartbeat lower and if you want the disks to disappear faster after the last machine then reduce the retry.

Problem Cause

Caused by existing machines still referencing the old image.

Issue/Introduction

When Updating XenDesktops Pooled Machine Catalog Old Base Disk is not Deleted.

Additional Information

Solution provide from our forums

Problem with MCS Base Disk deletion

http://discussions.citrix.com/topic/331755-problem-with-mcs-base-disk-deletion/