Support Tip: Mandatory user profiles and App-V integration with Configuration Manager


Hi everyone, Luke Ramsdale here with a tip for you on using mandatory user profiles in an integrated App-V/ConfigMgr environment.

There are a number of scenarios where an organization may require that the user profiles on their workstations not be stored locally. For example, maybe mandatory profiles are configured or the profiles are deleted after the user logs off, or VDI machines are in use and are not persistent. When an organization uses Microsoft Application Virtualization (App-V) integrated with Configuration Manager, this scenario can lead to problems when deploying virtual applications to collections of users. This is because when the user profile is returned to its mandatory state, or it is deleted after logging off, the App-V files stored in the user profile are also deleted. This proves problematic when the users eventually log back on to the machines because the shortcuts and part of the virtual applications are not available until the application deployment evaluation cycle runs, which is by default every 7 days.

There are a couple of ways to work around this issue which will allow a user to access these applications automatically when logging on for a second time or any subsequent attempts:

The first option is to run the application deployment evaluation cycle programmatically via a script every time a user logs in to a machine. Note that this needs to be evaluated carefully because there are network and client performance implications of performing this action at scale.

An example of the command line you would need to run would be:

WMIC.exe /namespace:\\root\ccm path sms_client CALL TriggerSchedule “{00000000-0000-0000-0000-000000000121}” /NOINTERACTIVE

The second option is to run this PowerShell script via a traditional package and program using the following method:

1. Create a new package and configure the PowerShell script as the source.

2. Create a standard program with the following command line:

%WinDir%\Sysnative\WindowsPowerShell\v1.0\powershell.exe -ExecutionPolicy Bypass -File .\Republish_App-V_5_package_script.ps1

3. Configure the program to run “hidden”.

4. Configure it to run with administrative rights and to “only run when a user is logged on”:

clip_image001

5. When the package has been configured and deployed to the distribution point, deploy the package program as required with a date-time and a “Log on” assignment schedule, and ensure the rerun behavior is configured to “Always rerun program”:

clip_image002

All other deployment settings can be left at the default values.

That’s it! Once this is deployed, App-V shortcuts and the associated files should be available every time the user logs on.

Note that this applies to Microsoft System Center 2012 R2 Configuration Manager (ConfigMgr 2012 R2) but should also apply newer versions as well (current branch).

Luke Ramsdale, Support Escalation Engineer
Microsoft Enterprise Cloud Group


Comments (2)

  1. Craig D says:

    Thank you for the update. How does the PowerShell script cope with ‘Available’, rather than ‘Required’ App-V apps that users have elected to install from the Software Center?

Skip to main content