Call4Cloud

Retry Lola Retry

I decided to pull out a part from the IMECache blog as the blog itself was becoming too large.

Troubleshooting Win32 Apps IME | Retry Failed Win32App GRS (call4cloud.nl)

This part was mentioning how you could force a retry when a Win32app failed to install.

1. Triggering the Reinstallation

Of course, we need to trigger the installation, again and again, to determine the root cause when a Win32app fails to install. So what options do we have when we want to retry the failed app to reinstall? After the 3 times for 5 minutes have taken place it will wait 24 hours before the GRS / “Global re-evaluation schedule” will kick in is just plain awful

  1. Waiting
  2. Company Portal
  3. The Registry
  4. GRS Manager
  5. A PowerShell Tool

1.1. Waiting

We could wait 24 hours and hopefully, the GRS would kick in to try to reinstall the app someday, sometime.

I guess that’s not the best option we got! But if you don’t care about waiting… this option is the easiest one!

1.2. Company Portal

Of course, everyone uses the Wonderfull Company App and everyone has also assigned the Apps as available so end users can install the apps or reinstall the apps on their own?. When the apps are also made available, we could trigger a reinstallation from the Company App?

Even when your device is “shared” you could initialize a reinstall?

Please note: When triggering the reinstall, first the detection phase will be launched and you guess what happens when it detects the program! The reinstallation will be skipped!

When you don’t want to wait until the company portal app gives you the possibility to reinstall the app as shown above (sorry for the Dutch words) there is still another method available to speed things up!

1.3. The Registry

The best way you could trigger the immediate reinstallation of a Win32App that failed to install is by opening the registry and browsing the IntuneManagementExtension key

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\IntuneManagementExtension\Win32Apps\{SID}\{App Id GUID}

First, you will need to find the Win32 App you are after. But to do so, you will need the have the right App ID. Again you have multiple options to find the needed GUID!

  • You could start looking in the Intune Management Extension event log. As we noticed earlier, it will mention the download and the corresponding App ID
  • The second option you have to find this GUID, is by opening the Endpoint Manager and clicking on the App that needs to be reinstalled. When you selected the App you can make a copy of the GUID in the URL after /appId/.

When we have the App id we are good to go. Just search for it and open the corresponding registry key. When you are sure the app is failing (as an example exit code 1603) you need to remove the whole subkey “159aeebd-fe8a-4571-98ef-de8c72ff5ed5” just like I have marked with a nice red square and restart the Intune Management Extension.

If you want to know more about how these exit codes work and how detection rules work please read this blog as it should tell you more about it

If you don’t want to wait, just delete the whole AppId key it’s also enough to modify the “DownloadStartTimeUTC” in the past 24 hours and wait for the installation will be retried by the GRS schedule.

Please read part 1.4 as it mentions an important update in the WIn32app Install retry flow!

1.4 GRS Manager

It looks like deleting only that key isn’t enough anymore after the Intune Management Extension service got updated some time ago. After you delete the reg key, as shown above, we need to take a look at the IME log with the CMtrace tool. Inside the IME log, GRSManager will tell you that the App with a specific hash is not expired.

We will also notice that the ReevaluationScheduleManager is also mentioning the same hash we noticed earlier! So please make sure after deleting the first GUID you also delete that specific GRS key!

1.5 A PowerShell Tool

Removing the registry key could take up some of your time and we all know time is valuable, so why not use a tool to do so?

Mathias Melkerson is creating a wonderful tool to do so. Please note it looks like with the GRS update it isn’t working as expected. When stumbling upon that GRS key I immediately reached out to Mattias and Andrew (@AndrewZtrhgf) / Twitter. Andrew made sure he added some extra code to make sure it also fetches the hash!

function for getting Intune Win32App GRS hash from Intune log file · GitHub

Conclusion

Having the possibility to retry failed apps is great! Hopefully, you also have read part 1.4 that is mentioning the GRS manager key. Sometimes Microsoft updates the IME and with it, some things change.!

Updates GIFs - Get the best GIF on GIPHY

Leave a Reply

Your email address will not be published. Required fields are marked *

7  +    =  17