Windows Autopilot Error Code 0x800705b4 Preparing device for mobile management

%3CLINGO-SUB%20id%3D%22lingo-sub-2310077%22%20slang%3D%22en-US%22%3EWindows%20Autopilot%20Error%20Code%200x800705b4%20Preparing%20device%20for%20mobile%20management%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2310077%22%20slang%3D%22en-US%22%3E%3CP%3EWe%20are%20implementing%20a%20number%20of%20Windows%20Autopilot%20via%20Lenovo%20Thinkbook%2015-ITL.%20These%20are%20being%20deployed%20to%20authorised%20users%20whether%20they%20are%20at%20home%20connected%20to%20their%20home%20broadband%20or%20in%20the%20office%20connect%20to%20the%20Wide%20Area%20Network.%26nbsp%3B%20Despite%20lots%20of%20testing%2C%20we%20randomly%20see%20the%20the%20error%20(see%20attached).%26nbsp%3B%20If%20we%20wipe%20the%20device%20a%20couple%20of%20times%2C%20it%20seems%20to%20remedy%20the%20issue.%26nbsp%3B%20I've%20tried%20to%20look%20online%20about%20this%20about%20various%20posts%20talk%20about%20the%20TPM%2C%20which%20it%20is%20not.%20I've%20tried%20to%20look%20through%20the%20logs%20from%20the%20device%20-%20what%20a%20minefield%20of%20information%20that%20means%20something%20to%20someone.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EHas%20anyone%20any%20ideas%3F%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EThanks%3C%2FP%3E%3CP%3EMartin%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-2310077%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EAutopilot%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3Eerror%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3Epreparing%20your%20device%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2310477%22%20slang%3D%22en-US%22%3ERe%3A%20Windows%20Autopilot%20Error%20Code%200x800705b4%20Preparing%20device%20for%20mobile%20management%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2310477%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F364363%22%20target%3D%22_blank%22%3E%40martin_macf%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EHi%2C%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EThis%20error%20could%20mean%20a%20Time%20Out%20error%20...%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EThe%20error%20itself%20is%20normally%20due%20to%20a%20tpm%20error%3A%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22Rudy_Ooms_0-1619785020593.png%22%20style%3D%22width%3A%20400px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F277040iC59D851A18A943F8%2Fimage-size%2Fmedium%3Fv%3Dv2%26amp%3Bpx%3D400%22%20role%3D%22button%22%20title%3D%22Rudy_Ooms_0-1619785020593.png%22%20alt%3D%22Rudy_Ooms_0-1619785020593.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%3CP%3EAre%20you%20using%20Autopilot%20or%20Autopilot%20white%20glove%3F.%20If%20using%20white%20glove%2C%20make%20sure%20you%20have%20checked%20if%20the%20tpm%20also%20support%20attestation%3A%26nbsp%3B%3CSPAN%3ETpmtool%20getdeviceinformation%3C%2FSPAN%3E%3C%2FP%3E%3CP%3EBut%20just%20like%20you%20told%20us%2C%20after%20a%20few%20reinstalls%20it%20works....%20Did%20you%20also%20tried%20to%20clear%20the%20tpm%20before%20a%20reinstall%3F%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2311715%22%20slang%3D%22en-US%22%3ERe%3A%20Windows%20Autopilot%20Error%20Code%200x800705b4%20Preparing%20device%20for%20mobile%20management%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2311715%22%20slang%3D%22en-US%22%3EHi%2C%3CBR%20%2F%3E%3CBR%20%2F%3EI%20will%20place%20my%20money%20on%20the%20timeout%20problem...%20for%20now..%3CBR%20%2F%3EYou%20could%20open%20tpm.msc%20and%20clear%20the%20tpm%20on%20the%20right%20side..%20maybe%20it%20would%20trigger%20something%3CBR%20%2F%3EBut%20if%20you%20are%20installing%20the%20same%20device%20multiple%20times%20and%20af%20the%204th%20time%2C%20its%20working...%20it%20looks%20like%20timeout%2Ffirewall%20settings%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2318591%22%20slang%3D%22en-US%22%3ERe%3A%20Windows%20Autopilot%20Error%20Code%200x800705b4%20Preparing%20device%20for%20mobile%20management%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2318591%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F364363%22%20target%3D%22_blank%22%3E%40martin_macf%3C%2FA%3E%26nbsp%3BThis%20has%20been%20happening%20to%20us%20and%20I've%20basically%20narrowed%20it%20down%20to%20our%20task%20sequence%20which%20installs%20the%20sccm%20client%20during%20the%20%22existing%20autopilot%20devices%22%20flow.%20When%20I%20disable%20%22Setup%20windows%20and%20config%20manager%22%20step%2C%20provisioning%20doesn't%20get%20hung%20up%20at%20%22preparing%20your%20device%20for%20mobile%20management%22.%20When%20%22setup%20windows%20and%20configmgr%22%20is%20enabled%20in%20the%20task%20sequence%2C%20autopilot%20invariably%20gets%20stuck%2C%20even%20though%20I%20have%20implemented%20steps%20later%20to%20remove%20the%20client.%20In%20terms%20of%20the%20removal%2C%20I've%20tried%20both%20ccmsetup.exe%20%2Funinstall%20as%20well%20as%20the%20task%20sequence%20step%20%22prepare%20configmgr%20client%20for%20capture%22%20-%20neither%20seems%20to%20work.%20The%20%22ccmsetup.exe%20%2Funinstall%22%20was%20working%20just%20fine%20for%20us%20before%2C%20and%20it%20all%20of%20a%20sudden%20stopped%20working%2C%20so%20I%20can%20only%20imagine%20it's%20a%20code-change%20on%20the%20Intune%20side.%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2320635%22%20slang%3D%22en-US%22%3ERe%3A%20Windows%20Autopilot%20Error%20Code%200x800705b4%20Preparing%20device%20for%20mobile%20management%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2320635%22%20slang%3D%22en-US%22%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F1043971%22%20target%3D%22_blank%22%3E%40derekuoft%3C%2FA%3E%20we%20do%20not%20use%20SCCM%20for%20this%20setup.%20Does%20anyone%20really%20understand%20why%20it%20times%20out%3F%20This%20area%20of%20Autopilot%20does%20seem%20to%20be%20a%20bit%20hit%20and%20miss%2C%20which%2C%20when%20you%20are%20using%20this%20solution%20to%20rollout%20laptops%20to%20our%20user%20community%2C%20is%20not%20really%20what%20I%20expect.%20When%20the%20laptops%20have%20been%20sent%20out%20to%20the%20users%2C%20it%20is%20very%20difficult%20to%20break%20into%20the%20process%20as%20an%20administrator%20and%20clear%20the%20TPM%20that%20%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F620702%22%20target%3D%22_blank%22%3E%40Rudy_Ooms%3C%2FA%3E%20suggests.%20The%20only%20outcome%20seems%20to%20be%20keeping%20trying%20-%20wipe%20and%20start%20again%20and%20repeat%20until%20it%20completes%20it%20process.%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2320859%22%20slang%3D%22en-US%22%3ERe%3A%20Windows%20Autopilot%20Error%20Code%200x800705b4%20Preparing%20device%20for%20mobile%20management%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2320859%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F620702%22%20target%3D%22_blank%22%3E%40Rudy_Ooms%3C%2FA%3E%26nbsp%3BHi%2C%20We%20have%20a%202%20hour%20timeout.%3C%2FP%3E%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22martin_macf_0-1620118744890.png%22%20style%3D%22width%3A%20400px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F277794i42FEDF41E19E2C0E%2Fimage-size%2Fmedium%3Fv%3Dv2%26amp%3Bpx%3D400%22%20role%3D%22button%22%20title%3D%22martin_macf_0-1620118744890.png%22%20alt%3D%22martin_macf_0-1620118744890.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%3CP%3EAlso%20we%20have%201%20app%20to%20install%20during%20the%20process.%26nbsp%3B%20All%20others%20apps%20installed%20afterwards.%3C%2FP%3E%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22martin_macf_1-1620118814423.png%22%20style%3D%22width%3A%20400px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F277795iD0B37E6EF528379B%2Fimage-size%2Fmedium%3Fv%3Dv2%26amp%3Bpx%3D400%22%20role%3D%22button%22%20title%3D%22martin_macf_1-1620118814423.png%22%20alt%3D%22martin_macf_1-1620118814423.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%3CP%3ESo%20really%20there%20is%20no%20reason%20for%20timing%20out%26nbsp%3B%20at%20all.%26nbsp%3B%20It%20should%20be%20a%20quick%20and%20simple%20process.%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2320922%22%20slang%3D%22en-US%22%3ERe%3A%20Windows%20Autopilot%20Error%20Code%200x800705b4%20Preparing%20device%20for%20mobile%20management%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2320922%22%20slang%3D%22en-US%22%3EHi%2C%3CBR%20%2F%3E%3CBR%20%2F%3EBlock%20device%20until%20these%20requried%20apps%20are%20installed%2C%20does%20not%20mean%20no%20other%20apps%20will%20be%20installed%20%3A)%3C%2Fimg%3E%20..%20It%20only%20makes%20sure%20the%20forticlient%20VPN%20client%20is%20installed%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2320936%22%20slang%3D%22en-US%22%3ERe%3A%20Windows%20Autopilot%20Error%20Code%200x800705b4%20Preparing%20device%20for%20mobile%20management%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2320936%22%20slang%3D%22en-US%22%3EThat's%20right%2C%20once%20the%20user%20logs%20in%20and%20authenticates%20-%20via%20the%20VPN%20client%2C%20it%20starts%20installing%20the%20other%20apps.%20However%20I%20think%20it%20has%20already%20started%20installing%20the%20apps%20in%20the%20background.%20So%20the%20only%20stipulation%20we%20have%20is%20that%20as%20long%20as%20the%20VPN%20client%20is%20installed%20-%20which%20is%20needed%20for%20users%20to%20authenticate%20against%20our%20onpremise%20domain%20controller%20-%20it%20should%20be%20a%20really%20easy%20autopilot%20setup.%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2320958%22%20slang%3D%22en-US%22%3ERe%3A%20Windows%20Autopilot%20Error%20Code%200x800705b4%20Preparing%20device%20for%20mobile%20management%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2320958%22%20slang%3D%22en-US%22%3EHi%3CBR%20%2F%3E%3CBR%20%2F%3Eyes%2C%20that's%20default%20behaviour.%20How%20many%20apps%20are%20configured%20as%20required%3F%20As%20an%20example%20the%20laptop%20could%20already%20be%20installing%20the%20office365%20apps%20before%20it%20reaches%20the%20forticlient%20app.%3CBR%20%2F%3E%3C%2FLINGO-BODY%3E
Occasional Contributor

We are implementing a number of Windows Autopilot via Lenovo Thinkbook 15-ITL. These are being deployed to authorised users whether they are at home connected to their home broadband or in the office connect to the Wide Area Network.  Despite lots of testing, we randomly see the the error (see attached).  If we wipe the device a couple of times, it seems to remedy the issue.  I've tried to look online about this about various posts talk about the TPM, which it is not. I've tried to look through the logs from the device - what a minefield of information that means something to someone.

 

Has anyone any ideas?

 

Thanks

Martin 

21 Replies
Just to add if I look in Endpoint Manager against the device, it has been assigned the same machine name for associated Intune device and Azure AD device and the enrollement state is Enrolled.

@martin_macf 

 

Hi,

 

This error could mean a Time Out error ... 

 

The error itself is normally due to a tpm error: 

 

Rudy_Ooms_0-1619785020593.png

Are you using Autopilot or Autopilot white glove?. If using white glove, make sure you have checked if the tpm also support attestation: Tpmtool getdeviceinformation

But just like you told us, after a few reinstalls it works.... Did you also tried to clear the tpm before a reinstall?

 

 

 

We are using Autopilot OOBE. The TPM is an odd thing because we have 100+ Lenovo laptops. Eventually it does go through but if it is connected to our Wide Area Network if tends to fail at this stage and there are no ports being blocked that we can see. When you say clear the TPM before a reinstall what do you mean by that?

Thanks
Martin
Hi,

I will place my money on the timeout problem... for now..
You could open tpm.msc and clear the tpm on the right side.. maybe it would trigger something
But if you are installing the same device multiple times and af the 4th time, its working... it looks like timeout/firewall settings

@martin_macf This has been happening to us and I've basically narrowed it down to our task sequence which installs the sccm client during the "existing autopilot devices" flow. When I disable "Setup windows and config manager" step, provisioning doesn't get hung up at "preparing your device for mobile management". When "setup windows and configmgr" is enabled in the task sequence, autopilot invariably gets stuck, even though I have implemented steps later to remove the client. In terms of the removal, I've tried both ccmsetup.exe /uninstall as well as the task sequence step "prepare configmgr client for capture" - neither seems to work. The "ccmsetup.exe /uninstall" was working just fine for us before, and it all of a sudden stopped working, so I can only imagine it's a code-change on the Intune side. 

@derekuoft we do not use SCCM for this setup. Does anyone really understand why it times out? This area of Autopilot does seem to be a bit hit and miss, which, when you are using this solution to rollout laptops to our user community, is not really what I expect. When the laptops have been sent out to the users, it is very difficult to break into the process as an administrator and clear the TPM that @Rudy_Ooms suggests. The only outcome seems to be keeping trying - wipe and start again and repeat until it completes it process.

@martin_macf 

 

Hi,

You could try to increase the time limit on the enrollment status page...What did you configured as time limit? Did you configured many apps as required?

 

Rudy_Ooms_0-1620115118209.png

 

 

https://oofhours.com/2019/08/21/why-does-preparing-your-device-for-mobile-management-take-longer-wit...

@Rudy_Ooms Hi, We have a 2 hour timeout.

martin_macf_0-1620118744890.png

Also we have 1 app to install during the process.  All others apps installed afterwards.

martin_macf_1-1620118814423.png

So really there is no reason for timing out  at all.  It should be a quick and simple process.

Hi,

Block device until these requried apps are installed, does not mean no other apps will be installed :) .. It only makes sure the forticlient VPN client is installed
That's right, once the user logs in and authenticates - via the VPN client, it starts installing the other apps. However I think it has already started installing the apps in the background. So the only stipulation we have is that as long as the VPN client is installed - which is needed for users to authenticate against our onpremise domain controller - it should be a really easy autopilot setup.
Hi

yes, that's default behaviour. How many apps are configured as required? As an example the laptop could already be installing the office365 apps before it reaches the forticlient app.
OK we have 13 apps that require installing with one one app that actually needs installing before the user logs in. The timeout of 2 hours is very generous. The Autopilot routine seems very hit or miss. Some users successful other gets stuck. Some laptops for everyone. Incredibly frustrating as a solution.
Hi

Maybe some of these apps have some pre requirements and sometimes they are waiting before another app /requirement is installed? Just some random thought...

@derekuoft I am also experiencing this. I use the SCCM (MECM) "Deploy autopilot to existing devices" template and it seems to be broken (I'm deploying a 20H2 version of the image).  Same results here. When I disable the steps related to Setup windows and config manager, prepare Config Mgr client and prepare windows for Capture it seems to be fine (because the wim never boots into the OS phase and just remains in the WINPE applying wim stage of OSD).
But if you want to keep all the steps from that template, it seems those steps create something on the image that Intune doesn't agree with and then generates the Error Code 0x800705b4 during the Preparing device for mobile management autopilot step.
Maybe the ccm client isn't removed properly, maybe it isn't sysprepped cleanly. But I've tried letting it boot into the OS and then manually running steps to remove the ccm client and then runnning sysprep /generalize /oobe (various combinations). And yet it still gets the same error in intune.

Maybe a registry key is flagging something that Intune errors out on?



@i_ARQ Yes this is 100% what I'm seeing. I had a ticket open with Microsoft and they said they would reflect this to the technical team. I tried to make it as clear as possible to my support technician and summarized the problem in one sentence. "Prepare Windows and Configmgr" step in the SCCM task sequence breaks autopilot provisioning, no matter what method is used to remove the client.

 

I've had to move our autopilot for existing devices task sequence to the "faster" V2 method which doesn't install the SCCM client or sysprep the machine, and this involved basically rejigging the entire onboarding infrastructure, which we haven't touched in about two years. Having to cast my mind back and re-implement critical infrastructure from years ago was extremely annoying. I really hope Microsoft will acknowledge that this issue exists and provide some form of response. As it stands, their official docs for existing device flow for autopilot is broken. 

I also run the "faster" v2 method but it doesn't really allow me to customize things on the image because it bypasses installing the ccm client and I can't install other apps I want on the base.

But I think I may have found the registry key that might be causing the issue.
When it was at the autopilot "Preparing device for mobile management autopilot" step.. it tends to sit there untill the timeout reaches the limit and it gives that error. I opened a command prompt with Shift +F10 to view the registry and check for keys left by the ccm client.
I deleted some keys and forced a restart during autopilot.. and when it rebooted it finally got passed that step without any errors.
I now added a step in my sccm image to delete the keys at the end of the deployment. Hopefully that resolves the issue when it boots into autopilot.
keep you posted.

That sounds great, please keep me posted.

@derekuoft 
When I open a command prompt (SHIFT + F10) during autopilot,  I found that deleting the following reg keys seemed to help the device get past that error (needed to initiate a restart after deleting the keys though)

 

HKLM\software\microsoft\DeviceManageabilityCSP

HKLM\software\microsoft\ccmsetup

 

Maybe these leftover SCCM reg keys are being flagged by Autopilot and it generates the error we see?

 

Just wondering what version of OS you are using when you image your devices? I'm using 20H2. I know there were issues with 1903 and 1909 that required you to add extra steps to the task sequence. Might need extra steps to remove these reg keys, but I haven't found a way to do that successfully yet.

Another forum said this script https://github.com/robertomoir/remove-sccm  cleanly removes all traces of the SCCM client, which resets the MDM authority. Maybe Autopilot has issues with the SCCM remnants and still sees it as an MDM authority for that device?



@martin_macf 

Recently we're also experiencing this same intermittent error during our User-driven Autopilot profile on 20H2 HP laptops as well. Our scenario is we're early on in a migration from legacy AD-joined and MEMCM managed to Intune co-management with MEMCM. We wipe/reset the devices (either via Company portal or through Windows) to put the device into OOBE and into Autopilot. There isn't any CM Client stuff on there after this wipe or reset.

 

Get-AutopilotDiagnostics for these devices for which this error occurs seems to indicate the Autopilot issue happens very early in the 'Device Preparation' portion. Last event is "Download started" for Sidecar and is only the 4th event in the timeline.

 

Have looked at BIOS/UEFI time, and any profile and app changes we've made recently, also have tried clearing the TPM as part of our wipe (also tried during OOBE), and hasn't consistently helped. Again it's intermittent and some users might get this error, wipe/reset, then go through successfully on the same device.

 

I would agree with @Rudy_Ooms that it is a web filtering/firewall issue, that there are certain Intune services the device can only partially connect to? But having difficulty determining what they are specifically. Have gone through the required Intune URLs and all are open, including those for the TPM (infineon, etc).