Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Review CreatePartitions Scripts Recovery Size #76

Closed
aisgbnok opened this issue Oct 16, 2023 · 3 comments · Fixed by #80
Closed

Review CreatePartitions Scripts Recovery Size #76

aisgbnok opened this issue Oct 16, 2023 · 3 comments · Fixed by #80
Assignees
Labels
Health Repository health and maintenance Next Version Relating to an upcoming release Planning Initiation and concept planning

Comments

@aisgbnok
Copy link
Owner

aisgbnok commented Oct 16, 2023

It is time to review the CreatePartitions scripts. Specifically, the recovery sizes. Do they make sense for 2023-2024?

Microsoft Recovery Scripts

Here are some scripts I pulled from Surface Recovery Images. I usually use these are reference for determining what make sense. Given I have a Surface Laptop 3, I have outdated scripts. Unfortunately, you need a working serial number to pull them, so I went to Best Buy and grabbed the display unit's serial numbers 🤪🤫. These should be more up-to-date.

Surface Laptop Studio 2 (SurfaceLaptopStudio2_BMR_12010_2023.619.823):

convert gpt
create partition efi size=260
format quick fs=fat32 label="System"
assign letter=S
create partition msr size=16
create partition primary
shrink minimum=1152
gpt attributes=0x0000000000000000
format quick fs=ntfs label="Local Disk"
assign letter=W
create partition primary size=1152
set id=DE94BBA4-06D1-4D40-A16A-BFD50179D6AC
gpt attributes=0x8000000000000001
format quick fs=ntfs label="Windows RE tools"
assign letter=T
rescan
exit
@aisgbnok aisgbnok added Next Version Relating to an upcoming release Planning Initiation and concept planning Health Repository health and maintenance labels Oct 16, 2023
@aisgbnok aisgbnok self-assigned this Oct 16, 2023
@aisgbnok
Copy link
Owner Author

I am not sure if over 1GB makes sense yet. I don't mind the slight bump from 910MB to 940MB. So here is a preliminary update I am considering.

rem == CreatePartitions-UEFI.txt ==
rem == These commands are used with DiskPart to create four partitions for a UEFI/GPT-based device.
rem == Adjust the partition sizes as necessary.

rem == Clean Disk ==
rem == Clear all information on disk and convert to gpt.
select disk 0
clean
convert gpt

rem == 1. System Partition ==
rem == For Advanced Format 4Kn drives, change this value to size=260.
create partition efi size=260
format quick fs=fat32 label="System"
assign letter=S

rem == 2. Microsoft Reserved (MSR) Partition ==
create partition msr size=16

rem == 3. Windows Partition ==
rem == Create the Windows partition.
create partition primary

rem == Create space for the recovery tools
rem == Update this size to match the size of the recovery tools (winre.wim) plus some free space.
shrink minimum=940

rem == Prepare Windows Partition
gpt attributes=0x0000000000000000
format quick fs=ntfs label="Local Disk"
assign letter=W

rem == 4. Recovery Partition ==
create partition primary size=940
set id=DE94BBA4-06D1-4D40-A16A-BFD50179D6AC
gpt attributes=0x8000000000000001
format quick fs=ntfs label="Recovery"
assign letter=R

rem == Rescan Disks and Exit ==
rescan
exit

Unfortunately, my local Best Buy did not have a Surface Laptop Studio 2 on display. I will check back in November and progress from there. I also have to determine if for regular clean installs it makes sense to upgrade the recovery size. The recovery size only needs to be larger for OEM scripts, or any additional updates that come to Windows down the road.

@aisgbnok
Copy link
Owner Author

I ended up going back to BestBuy in December. They had a Surface Laptop Studio 2 on display.

convert gpt
create partition efi size=260
format quick fs=fat32 label="System"
assign letter=S
create partition msr size=16
create partition primary
shrink minimum=1152
gpt attributes=0x0000000000000000
format quick fs=ntfs label="Local Disk"
assign letter=W
create partition primary size=1152
set id=DE94BBA4-06D1-4D40-A16A-BFD50179D6AC
gpt attributes=0x8000000000000001
format quick fs=ntfs label="Windows RE tools"
assign letter=T
rescan
exit

You'll notice it sets the Recovery to 1152 MB just like the Surface Laptop 5 script.

@aisgbnok
Copy link
Owner Author

Given winre.wim is approximately 665 MB I decided that 1152 MB is fine. Devices have more storage space now and 665 MB is getting close to the current 910 MB. Additionally with Windows 11 24H2 (or Windows 12) on the horizon it's a good idea to leave extra space for Windows Recovery updates / size increase.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Health Repository health and maintenance Next Version Relating to an upcoming release Planning Initiation and concept planning
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant