Skip to content

Instantly share code, notes, and snippets.

@jmfernandez
Last active January 30, 2023 12:59
Show Gist options
  • Save jmfernandez/04f00c9a3d7de1edff89d1db446f4eda to your computer and use it in GitHub Desktop.
Save jmfernandez/04f00c9a3d7de1edff89d1db446f4eda to your computer and use it in GitHub Desktop.
Moving the recovery partition on Windows 10

These instructions were found at https://superuser.com/questions/1453790/how-to-move-the-recovery-partition-on-windows-10

  1. See the status of the recovery partition
    In Windows 10: reagentc /info

  2. Deregister the recovery partition
    In Windows 10: reagentc /disable

  3. (Optional) Backup recovery partition

    1. In Windows 10: diskpart in order to assign a drive letter to the partition
    DISKPART> list disk
    DISKPART> select disk <the-number-of-disk-where-current-recovery-partition-locate>
    DISKPART> list partition
    DISKPART> select partition <the-number-of-current-recovery-partition>
    DISKPART> assign letter=O
    
    1. In Windows 10: Capture the contents of the partition in an image:
    Dism /Capture-Image /ImageFile:C:\recovery-partition.wim /CaptureDir:O:\ /Name:"Recovery"
    
    1. (Optional) In Windows 10: Restore the contents in a new drive:
    Dism /Apply-Image /ImageFile:C:\recovery-partition.wim /Index:1 /ApplyDir:N:\
    
  4. In Linux use gparted to move the recovery partition using the "Move/Resize" option, assuming there is unassigned space before / after the recovery partition. Align to none.

  5. In Windows 10: Re-register the recovery partition with reagentc /enable, so Windows recovery can work.

See also https://docs.microsoft.com/en-us/windows-hardware/manufacture/desktop/capture-and-apply-windows-system-and-recovery-partitions

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment