Packages have the option "Automatically uninstall this application when it is no longer required by Deployment Manager policy" however when removed from policy they are not automatically uninstalled as they are supposed to be.
This can be caused for one of two main reasons:
- The schedule file has "AllowedPkgSubtypes=Standard" configured in the Apply Machine Policy event's additional parameters.
One of the packages still in policy fails to download
Both of these stop uninstallation from occurring because a package can only be uninstalled when we're certain that it's not a prerequisite of another package, the two scenarios above prevent certain applications from being installed and so we are unable to identify if the package being installed is a prerequisite or not and so uninstallation is prevented.
Steps to Reproduce
- Add a test package to policy with the "Automatically uninstall this application when it is no longer required by Deployment Manager policy"
- Wait until it's installed on a managed device and confirm it exists in the installation.log
- Remove the package from policy, then once the MD applies policy, check the installation.log for the test package - it should no longer be found.
- Check that the package is still physically installed on the machine
To resolve this issue:
- Remove the AllowedPkgSubtypes option from the Additional Parameters section of the Apply Machine Policy schedule event
- Identify the package still in policy that is not downloading and either re-distribute it or remove it from policy