question

Max-D-007 avatar image
0 Votes"
Max-D-007 asked Max-D-007 answered

In place upgrade of Win10 1709 (VM) to 20H2 - Failing to mount WIM file (Error 0x80070522)

I've tried every solution I could research to get an in place upgrade of WIN10 (1709):

  • Media Creation Tool

  • Upgrade Assistant

  • 1809 ISO

  • 20H2 ISO

  • 21H1 ISO

  • Disable UAC

  • Disabled all relevant local security policies that may interfere

  • Disabled AV agent

  • SFC / Scannow

  • SetupDiag.exe

But each and every time it fails around the 80-85% mark with the following error

Failed to mount WIM file C:\$WINDOWS.~BT\Sources\SafeOS\winre.wim. Error 0x80070522

I'm a local admin as well as running the setup.exe as admin, but for some reason the DISM command cannot mount the winre.wim file at a crucial stage in the upgrade process, so it simply fails each time.

Can anyone think of something I've missed that would cause the permission error each time?











windows-10-setupwindows-10-hyperv
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Max-D-007 avatar image
1 Vote"
Max-D-007 answered

RESOLVED!

After disabling / relaxing every 'common culprit' local security policy, I bit the bullet and reset all to defaults:

secedit /configure /cfg %windir%\inf\defltbase.inf /db defltbase.sdb /verbose

[https://www.tenforums.com/tutorials/68588-reset-local-security-policy-settings-default-windows.html][1]

I was then able to manually run the DISM command - successfully!

With the #1 issue out of the way, the automated WIN 10 update process ran without an issue.

Dev box is now running 21H1.

5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Max-D-007 avatar image
0 Votes"
Max-D-007 answered

Trying the same in an admin CMD line:


C:\$WINDOWS.~BT\Sources\SafeOS>DISM /Mount-Wim /WimFile:"winre.wim" /index:1 /MountDir:"c:\temp"

Deployment Image Servicing and Management tool
Version: 10.0.16299.1932


Error: 1314

A required privilege is not held by the client.

The DISM log file can be found at C:\windows\Logs\DISM\dism.log

C:\$WINDOWS.~BT\Sources\SafeOS>

5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Max-D-007 avatar image
0 Votes"
Max-D-007 answered

Thanks @Docs-4663 - yes I researched the hell out of that error code and got the gist of it fairly quickly.

I tried relaxing all relevant local security policies with no success.

Also tried running the DISM command manually (from CMD as admin) and rec'd the same error as the build process does when it tries mounting the winre.wim file.

5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Docs-4663 avatar image
0 Votes"
Docs-4663 answered

In case this is helpful: 0x80070522 = Error_privilege_not_held

.
.
.
.
Please remember to vote and to mark the replies as answers if they help.

On the bottom of each post there is:

Propose as answer = answered the question

On the left side of each post: Vote = a helpful post
.
.
.
.

5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Max-D-007 avatar image
0 Votes"
Max-D-007 answered

CMountWIM::DoExecute: Failed to mount WIM file C:\$WINDOWS.~BT\Sources\SafeOS\winre.wim. Error 0x80070522[gle=0x00000522]


I thought I might have resolved the issue after running a WU reset script I found - but after a hopefull 45mins, it still fails with the error above.

The script (in case it helps someone else) is here:

https://www.yourwindowsguide.com/2015/12/reset-windows-update.html#.YSwXJ44zZjE

Appreciate any further advice on this.

It's a VM that contains a lot of dev history and applications. I would rather not have to start re-building the whole environment from scratch if it can be helped.


5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Max-D-007 avatar image
0 Votes"
Max-D-007 answered

123648-setupdiagresults.log



Thanks @Docs-4663 - I've attached the typical log detailing the same result I get each time.


5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Docs-4663 avatar image
0 Votes"
Docs-4663 answered

Please post a share link with the setupdiag results.


https://docs.microsoft.com/en-us/troubleshoot/azure/virtual-machines/in-place-system-upgrade



.
.
.
.
Please remember to vote and to mark the replies as answers if they help.

On the bottom of each post there is:

Propose as answer = answered the question

On the left side of each post: Vote = a helpful post
.
.
.
.

5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.