Product Documentation

Profile management and VMware

Dec 04, 2012

This topic applies to Citrix user profiles on virtual machines created with VMware software such as VMware ESX. It addresses an issue where local profile caches become locked.

If you have set up Profile management to delete cached local profiles when users log off from their virtual machines created with VMware (in your XenDesktop or XenApp deployment, say) but the profiles are not deleted, you can use this workaround to overcome the issue.

This issue has been shown to occur when roaming profiles are used on virtual machines created with VMware ESX 3.5 and the Profile management setting Delete locally cached profiles on logoff is enabled.

The issue occurs because the Shared Folders option in VMware Tools adds a file to the profiles, and the file is locked by a running process thereby preventing profiles being deleted at logoff. The file is C:\Documents and Settings\userid\Application Data\VMware\hgfs.dat.

If you have verbose logging enabled in Profile management, the log file may detect this problem with an entry such as:

2009-06-03;11:44:31.456;ERROR;PCNAME;JohnSmith4;3;3640;DeleteDirectory: Deleting the directory <C:\Documents and Settings\<user name>\Local Settings\Application Data\VMware> failed with: The directory is not empty.

To work around this issue in a XenApp deployment on Windows Server 2008:

  1. Log on as Administrator to the XenApp server.
  2. In XenApp deployments, log off all users from the server.
  3. In Control Panel, go to Add/Remove Programs.
  4. Locate VMware Tools and choose the Change option.
  5. Change Shared Folders to This feature will not be available.
  6. Click Next > Modify > Finish.
  7. Restart the server.
  8. Clean up the half-deleted profiles. Use My Computer > Properties > Advanced > User Profiles, select the profiles and delete them. Windows informs you of any errors trying to delete the profiles.
Note: A separate issue in environments running Profile management on VMware can result in the creation of multiple sequential profiles. For information about this issue and how to resolve it, see CTX122501.