Any way to shrink "sysprep(ed) install.wim" ?


adu78

Active member
Local time
9:42 PM
Posts
30
OS
Windows 10
Hi,

I took Windows 11 23h2 to audit mode by pressing Shift+F3 in OOBE after running setup on a clean VM.

I "only" pre-installed Word / Excel 2016 and installed updates.

After Sysprep and capturing the "image" with.
dism /capture-image /imagefile:c:\temp\install.wim /capturedir:f:\ /name:"Win11" /description:"Win11" /compress:maximum /checkintegrity /verify /bootable

my install.wim is nearly 11 GB.

The original install.wim is like 5,7 GB.

Before "sysprep" I run the following command in an elevated command-promp and marked everything.
cmd.exe /c Cleanmgr /sageset:65535 & Cleanmgr /sagerun:65535


The Office Setup Files are deleted. Haven't changed anything else so far.

Is there a safe, secure way to shrink the image even more ?

Thank you for your time and stay well.
 

My Computer My Computer

At a glance

Windows 10Ryzen 7 5700X2 x 16 GB DDR 4 - 3200 - G.Skill RipJaws VASUS TUF Gaming GeForce RTX 4070
OS
Windows 10
Computer type
PC/Desktop
Manufacturer/Model
Custom
CPU
Ryzen 7 5700X
Motherboard
Gigabyte B550 Aorus Elite V2
Memory
2 x 16 GB DDR 4 - 3200 - G.Skill RipJaws V
Graphics Card(s)
ASUS TUF Gaming GeForce RTX 4070
Sound Card
OnBoard Realtek
Monitor(s) Displays
2 x Dell S2721DGF
Screen Resolution
2560 x 1440 @ 165 MHZ
Hard Drives
1 TB Kingston KC3000 M.2PCIe 4.0
PSU
be quiet! Pure Power 12 M Modular 80+ Gold
Case
Phanteks Eclipse P600s
Cooling
be quit! Dark Rock Pro 4
Keyboard
Logitech G213 Prodigy
Mouse
Logitech G502 Hero
Internet Speed
1000 MBit Cable DSL
Browser
Firefox
Antivirus
Microsoft Defender
Hi,

I took Windows 11 23h2 to audit mode by pressing Shift+F3 in OOBE after running setup on a clean VM.

I "only" pre-installed Word / Excel 2016 and installed updates.

After Sysprep and capturing the "image" with.
dism /capture-image /imagefile:c:\temp\install.wim /capturedir:f:\ /name:"Win11" /description:"Win11" /compress:maximum /checkintegrity /verify /bootable

my install.wim is nearly 11 GB.

The original install.wim is like 5,7 GB.

Before "sysprep" I run the following command in an elevated command-promp and marked everything.
cmd.exe /c Cleanmgr /sageset:65535 & Cleanmgr /sagerun:65535


The Office Setup Files are deleted. Haven't changed anything else so far.

Is there a safe, secure way to shrink the image even more ?

Thank you for your time and stay well.
Why would you bother. Sysprep does not shrink Windows, only removes hardware drivers etc.

To shrink any further you would have to create a custom install.wim compressing the sysprepped version of Windows.
 

My Computer My Computer

At a glance

Windows 11 Pro + Win11 Canary VM.I9 13th gen i9-13900H 2.60 GHZ16 GB solderedIntegrated Intel Iris XE
OS
Windows 11 Pro + Win11 Canary VM.
Computer type
Laptop
Manufacturer/Model
ASUS Zenbook 14
CPU
I9 13th gen i9-13900H 2.60 GHZ
Motherboard
Yep, Laptop has one.
Memory
16 GB soldered
Graphics Card(s)
Integrated Intel Iris XE
Sound Card
Realtek built in
Monitor(s) Displays
laptop OLED screen
Screen Resolution
2880x1800 touchscreen
Hard Drives
1 TB NVME SSD (only weakness is only one slot)
PSU
Internal + 65W thunderbolt USB4 charger
Case
Yep, got one
Cooling
Stella Artois (UK pint cans - 568 ml) - extra cost.
Keyboard
Built in UK keybd
Mouse
Bluetooth , wireless dongled, wired
Internet Speed
900 mbs (ethernet), wifi 6 typical 350-450 mb/s both up and down
Browser
Edge
Antivirus
Defender
Other Info
TPM 2.0, 2xUSB4 thunderbolt, 1xUsb3 (usb a), 1xUsb-c, hdmi out, 3.5 mm audio out/in combo, ASUS backlit trackpad (inc. switchable number pad)

Macrium Reflect Home V8
Office 365 Family (6 users each 1TB onedrive space)
Hyper-V (a vm runs almost as fast as my older laptop)
I guess you took me wrong.
I dont want the original wim to get smaller, or get rid off any drivers.

I just wonder why my custom.wim (with only word / exel added) is nearly twice as big.
 

My Computer My Computer

At a glance

Windows 10Ryzen 7 5700X2 x 16 GB DDR 4 - 3200 - G.Skill RipJaws VASUS TUF Gaming GeForce RTX 4070
OS
Windows 10
Computer type
PC/Desktop
Manufacturer/Model
Custom
CPU
Ryzen 7 5700X
Motherboard
Gigabyte B550 Aorus Elite V2
Memory
2 x 16 GB DDR 4 - 3200 - G.Skill RipJaws V
Graphics Card(s)
ASUS TUF Gaming GeForce RTX 4070
Sound Card
OnBoard Realtek
Monitor(s) Displays
2 x Dell S2721DGF
Screen Resolution
2560 x 1440 @ 165 MHZ
Hard Drives
1 TB Kingston KC3000 M.2PCIe 4.0
PSU
be quiet! Pure Power 12 M Modular 80+ Gold
Case
Phanteks Eclipse P600s
Cooling
be quit! Dark Rock Pro 4
Keyboard
Logitech G213 Prodigy
Mouse
Logitech G502 Hero
Internet Speed
1000 MBit Cable DSL
Browser
Firefox
Antivirus
Microsoft Defender
If you add in products that use different versions of .NET framework, SxS installation will be invoked, removing the compact installation.
 

My Computer My Computer

At a glance

Windows 11 22H2
OS
Windows 11 22H2
Unfortunately, I'm not really aware of anything else that you can do to shrink that image. Once you start adding things to Windows that image can grow in a hurry.

For that reason, among others, I now use a different approach. Rather than using sysprep to deploy Windows I just perform an unattended installation of plain, unmodified Windows, then script the installation of items I want to install after the initial installation. This can, of course, include the installation of Microsoft 365 (formerly Office) products. Winget works great for this.
 

My Computers My Computers

  • At a glance

    Win11 Pro 26H2 (Release Preview)Intel i7-14650HX32 GBNo GPU - Built-in Intel Graphics
    OS
    Win11 Pro 26H2 (Release Preview)
    Computer type
    PC/Desktop
    Manufacturer/Model
    Acemagic Matrix M5
    CPU
    Intel i7-14650HX
    Memory
    32 GB
    Graphics Card(s)
    No GPU - Built-in Intel Graphics
    Sound Card
    Integrated
    Monitor(s) Displays
    Varies as machine will often be moved to locations with different monitors
    Screen Resolution
    Varies
    Hard Drives
    1 x 1TB Gen 4 NVMe SSD
    PSU
    120W Power Brick
    Keyboard
    Corsair K70 Max RGB Magnetic Keyboard
    Mouse
    Logitech MX Master 3
    Internet Speed
    1Gb Up / 1 Gb Down
    Browser
    Edge
    Antivirus
    Windows Defender
  • At a glance

    Win11 Pro 26H2 (Release Preview)Intel i7-1255U16 GBIntel Iris Xe Graphics
    Operating System
    Win11 Pro 26H2 (Release Preview)
    Computer type
    Laptop
    Manufacturer/Model
    Lenovo ThinkBook 13x Gen 2
    CPU
    Intel i7-1255U
    Memory
    16 GB
    Graphics card(s)
    Intel Iris Xe Graphics
    Sound Card
    Realtek® ALC3306-CG codec
    Monitor(s) Displays
    13.3-inch IPS Display
    Screen Resolution
    WQXGA (2560 x 1600)
    Hard Drives
    4 TB 4 x 4 NVMe SSD
    PSU
    USB-C / Thunderbolt 4 Power / Charging Using an Anker 160W Charger
    Keyboard
    Backlit, spill resistant keyboard
    Mouse
    Buttonless Glass Precision Touchpad
    Internet Speed
    1Gb Up / 1Gb Down
    Browser
    Edge
    Antivirus
    Windows Defender
    Other Info
    WiFi 6e / Bluetooth 5.1 / Facial Recognition / Fingerprint Sensor / ToF (Time of Flight) Human Presence Sensor
Back
Top Bottom