Reset a user profile
When a profile is reset, although the user’s folders and files are saved and copied to the new profile, most user profile data is deleted (for example, the registry is reset and application settings might be deleted).
- From Director, search for the user whose profile you want to reset and select this user’s session.
- Click Reset Profile.
- Instruct the user to log off from all sessions.
- Instruct the user to log back on. The folders and files that were saved from the user’s profile are copied to the new profile.
If the user has profiles on multiple platforms (such as Windows 8 and Windows 7), instruct the user to log back on first to the same desktop or app that the user reported as a problem. This ensures that the correct profile is reset. If the profile is a Citrix user profile, the profile is already reset by the time the user’s desktop appears. If the profile is a Microsoft roaming profile, the folder restoration might still be in progress for a brief time. The user must stay logged on until the restoration is complete.
The preceding steps assume you are using Citrix Virtual Desktops (Desktop VDA). If you are using Citrix Virtual Desktops (Server VDA) you need to be logged on to perform the profile reset. The user then needs to log off, and log back on to complete the profile reset.
If the profile is not successfully reset (for example, the user cannot successfully log back on to the machine or some of the files are missing), you must manually restore the original profile.
The folders (and their files) from the user’s profile are saved and copied to the new profile. They are copied in the listed order:
In Windows 8 and later, cookies are not copied when profiles are reset.
How reset profiles are processed
Any Citrix user profile or Microsoft roaming profile can be reset. After the user logs off and you select the reset command (either in Director or using the PowerShell SDK), Director first identifies the user profile in use and issues an appropriate reset command. Director receives the information through Profile management, including information about the profile size, type, and logon timings.
This diagram illustrates the process following the user log on, when a user profile is reset.
The reset command issued by Director specifies the profile type. The Profile management service then attempts to reset a profile of that type and looks for the appropriate network share (user store). If the user is processed by Profile management, but receives a roaming profile command, it is rejected (or vice versa).
- If a local profile is present, it is deleted.
- The network profile is renamed.
The next action depends on whether the profile being reset is a Citrix user profile or a Microsoft roaming profile.
For Citrix user profiles, the new profile is created using the Profile management import rules, and the folders are copied back to the network profile, and the user can log on normally. If a roaming profile is used for the reset, any registry settings in the roaming profile are preserved in the reset profile. You can configure Profile management so that a template profile overrides the roaming profile, if required.
For Microsoft roaming profiles, a new profile is created by Windows, and when the user logs on, the folders are copied back to the user device. When the user logs off again, the new profile is copied to the network store.
To manually restore a profile after a failed reset
- Instruct the user to log off from all sessions.
- Delete the local profile if one exists.
- Locate the archived folder on the network share that contains the date and time appended to the folder name, the folder with a .upm_datestamp extension.
- Delete the current profile name; that is, the one without the upm_datestamp extension.
- Rename the archived folder using the original profile name; that is, remove the date and time extension. You have returned the profile to its original, pre-reset state.
To reset a profile using PowerShell SDK
You can reset a profile using the Broker PowerShell SDK.
Creates a command queued for delivery to a specific user, session, or machine. For more information about this cmdlet, see https://citrix.github.io/delivery-controller-sdk/Broker/New-BrokerMachineCommand/.
See the following examples for details about how to use the PowerShell cmdlets to reset a profile:
Reset a Profile Management profile
- Suppose you want to reset the profile for user1. Use the New-BrokerMachineCommand PowerShell command. For example:
New-BrokerMachineCommand -Category UserProfileManager -CommandName "ResetUpmProfile" -DesktopGroups 1 -CommandData $byteArray -SendTrigger logon -user domain1\user1
CommandData $byteArraymust be in the following format:
<SID>[,<backup path>]. If you do not provide the backup path, Profile Management generates a backup folder named by current date and time.
Reset a Windows roaming profile
- Suppose you want to reset the roaming profile for user1. Use the New-BrokerMachineCommand PowerShell command. For example:
New-BrokerMachineCommand -Category UserProfileManager -CommandName "ResetRoamingProfile" -DesktopGroups 1 -CommandData $byteArray -SendTrigger logon -user domain1\user1