Windows - Linux - Powershell
In January of 2024, Microsoft released KB5034441 after little to no testing. This update when ran against a default installation of Windows 10 would fail due to a lack of free space in the Windows Recovery Environment partition. This page contains the steps to correct this issue.
Microsoft did offer instructions, however they contain a technical error and are hard to understand. Original instructions: https://support.microsoft.com/en-us/topic/kb5028997-instructions-to-manually-resize-your-partition-to-install-the-winre-update-400faa27-9343-461c-ada9-24c8229763bf
WARNING
Proceed with caution, I take no responsibility for any damage that may occur. Please note these instructions only apply to systems with a WinRE partition at the end of the hard disk.
Check disk and recovery environment status
reagentc /inforeagentc /disablereagentc /infoShrink the OS partition and remove the old WinRE partition
diskpartlist disksel disk <OS disk index>. This should be the same disk index as WinRE.list partsel part <OS partition index>shrink desired=400 minimum=400sel part <WinRE partition index>delete partition overrideCreate new recovery partition
list disk. Check if there is an asterisk character (*) in the “Gpt” column.create partition primary id=de94bba4-06d1-4d40-a16a-bfd50179d6acformat quick fs=ntfs label="Windows RE tools"gpt attributes =0x8000000000000001create partition primaryformat quick fs=ntfs label="Windows RE tools"set id=27list part and list volRe-enable WindowsRE
exitreagentc /enablereagentc /infoRead all steps before attempting. In this scenario, you will have to:
shrink command step to be shrink desired=950 minimum=950