Autopilot Troubleshooting Why did my PC restart

Autopilot – Why did my PC restart?

Autopilot – Why Did My PC Restart? In this article, we delve into the user-driven Entra hybrid scenario of Autopilot setup and address the issue of PC restarts during the process. Discover the underlying reasons behind this occurrence and gain insights on how to effectively troubleshoot and resolve the problem.

The problem: Autopilot – Why did my PC restart?

While preforming Autopilot – User driven – Microsoft Entra hybrid Join Scenario

After getting the branding page, the user enters his credential, device restarted, then 2-3 mins the process interrupted and the device restarts again, following with this error “Why did my PC restart”

Autopilot Troubleshooting
Why did my PC restart?

Troubleshooting: Autopilot – Why did my PC restart?

Before start to guess what could be the issue, we should collect logs, either from Intune portal if device complete enrollment step or from the device itself

refer to Microsoft document to collect logs from the portal

https://learn.microsoft.com/en-us/mem/intune/remote-actions/collect-diagnostics

If you want to collect logs from the device do the following

Shift + F10 and run the following command

MDMDiagnosticsTool.exe -area “Autopilot;DeviceProvisioning;DeviceEnrollment,TPM” -cab c:\temp\MDMDiagnostics.cab

When troubleshooting Autopilot issues, I prefer to back to the flow so I can confirm every step completed then go to the next step

Referring to the hybrid flow, after the user enters his credential what should happen?

Two things should happen:

  1. The device should complete enrollment to Intune.
  2. The device should get the Offline Domain Join “ODJ” blob to be able to complete joining to on-prem domain.

Hint, the device should then restart to complete joining the on-prem domain and get the new name.

Let’s confirm those two points

First point, confirm if device enrolled:

We can confirm this by checking the event viewer log “microsoft-windows-devicemanagement-enterprise-diagnostics-provider-admin.evtx” and confirm if event 72 exists

Autopilot
Why did my PC restart?

I will write a specific post to troubleshoot enrollment step during Autopilot scenario, once ready will add the link here

Second point, confirm if the device received the ODJ blob

We can confirm if the device got the ODJ blob by checking the same event viewer log “microsoft-windows-devicemanagement-enterprise-diagnostics-provider-admin.evtx”

Just after device enrollment is completed, we will find event 111, stating that device waiting for ODJ blob

Autopilot
Why did my PC restart?

Then within a max of 25 mins, the device should receive the ODJ blob, from the same log we should check for event 107

Autopilot
Why did my PC restart?

So, both steps completed successfully …. Ooh what is the issue then!! ⁠Sad

More Analysis: Autopilot – Why did my PC restart?

As there is an unexpected restart happened, let’s check the system event

1 min after the device received the ODJ blob, I can see the following unexpected restart coming from “CloudExperienceHostBroker.exe”

And after the restart the device reverts to the default name

Autopilot
Why did my PC restart?

Then the next question will be, what causes the device to do this unexpected restart

Let’s check the policies deployed to the device, back to “microsoft-windows-devicemanagement-enterprise-diagnostics-provider-admin.evtx” and make sure there is no any conflicting policy with Autopilot

Check this Microsoft document for the list of policies that can conflict with Autopilot

https://learn.microsoft.com/en-us/autopilot/troubleshooting-faq#troubleshooting-policy-conflicts-with-windows-autopilot

from the log I can find the following event “2800”, The following URI has triggered a reboot (./DEvice/Vendor/MSFT/Policy/COnfig/DeviceGuard/LsaCfgFlags)

Autopilot
Why did my PC restart?

Tried to exclude the device guard policy, but the same issue is still happening.

The Cause: Autopilot – Why did my PC restart?

Continuing checking the policies deployed from Intune, we can find the customer is pushing AppLocker policy, which is one of the conflicting policies with Autopilot

After excluding the policy, the Autopilot process case be completed successfully

The Solution: Autopilot – Why did my PC restart?

As per Microsoft doc, AppLocker policy is not supported

Autopilot
Why did my PC restart?

But the customer still wants to apply it on the devices for security concern, it couldn’t be just excluded

So the solution will be to apply the AppLocker policy after Autopilot completed

For more posts about Autopilot please check Autopilot category in IntuneBytes blog

Tags:

Leave a Reply

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