How I Finally Got Ubuntu Running Alongside Windows — After Windows Refused to Give Up Space
A practical, no-fluff guide to dual booting Ubuntu on a 512 GB SSD when Windows’ Shrink Volume tool fights back. Before we start, make sure…
How I Finally Got Ubuntu Running Alongside Windows — After Windows Refused to Give Up Space
A practical, no-fluff guide to dual booting Ubuntu on a 512 GB SSD when Windows’ Shrink Volume tool fights back. Before we start, make sure to back up important files as we are playing around with disks here.
The Goal
I wanted to carve out space on my 512 GB SSD to install Ubuntu alongside Windows —to explore re-explore the world of linux and to try out open source contributions. My C: drive had 277 GB free. Should be simple, right?
It wasn’t.
The Problem: Windows Only Offered 21 GB to Shrink
When I opened Disk Management → Right-click C: → Shrink Volume, Windows offered me just 21 GB — on a drive with over 270 GB free. After disabling hibernation, the page file, and system restore, it crept up to ~23 GB. After defrag and disk cleanup, it plateaued at ~41 GB. Still nowhere near enough.
Starting state: C: drive at 453 GB with 225 GB free. Plenty of space — yet Shrink Volume wouldn’t cooperate.
Windows Explorer confirming 248 GB free on C: — and yet Windows refused to shrink more than ~23 GB.
The reason is a warning Windows shows every time you try to shrink:
“You cannot shrink a volume beyond the point where any unmovable files are located.”
These are system files Windows cannot relocate during a normal shrink operation — regardless of how much free space you have.
Step 1: Disable Hibernation
Open Command Prompt as Administrator and run:
powercfg /h off
This deletes hiberfil.sys — a hidden file that can consume 8–30 GB depending on your RAM size. No reboot needed after this step.
Step 2: Disable the Page File
- Search “Adjust the appearance and performance of Windows”
- Go to Advanced → Change (under Virtual Memory)
- Uncheck “Automatically manage paging file size for all drives”
- Select C: drive → choose No paging file → Set
- Click OK — don’t reboot yet
Step 3: Disable System Protection & Delete Restore Points
- Search “Create a restore point”
- Select C: drive → click Configure
- Select Disable system protection → Apply
- Delete all existing restore points when prompted
Step 4: Run Disk Cleanup
Search Disk Cleanup, run it as Administrator, then click “Clean up system files”.
Disk Cleanup: safe to check — Thumbnails, Temporary files, Delivery Optimization Files, Recycle Bin. Do NOT remove Windows Defender — it’s your only antivirus and barely takes up space.
The big wins here are Windows Update Cleanup (5–20 GB) and Delivery Optimization Files (3–10 GB). After running cleanup, restart your PC.
Step 5: Defrag & Optimize
Open Defragment and Optimize Drives, select C:, and click Optimize. Or via Admin CMD:
defrag C: /U /V
This moves files toward the beginning of the disk, potentially freeing up contiguous space at the end. No restart needed after defrag — go straight to trying the shrink again.
The Result After All Steps: Still Stuck at ~41 GB
After disabling hibernation + page file + system restore: shrink jumped from 21 GB to 23,436 MB — a small improvement but far from enough.
After defrag and disk cleanup: capped at 41,479 MB (~41 GB). The unmovable file warning persists no matter what.
A closer look at the wall Windows hits — 41 GB available, unmovable files blocking everything beyond.
Multiple attempts, different states — the number barely moves. Windows simply cannot relocate certain system files.
Even with 277 GB free on C:, Windows stubbornly caps the shrink at ~41 GB.
Investigating the Real Blocker: Event Viewer
To find exactly which file was blocking the shrink, open Event Viewer:
- Press Win + R → type
eventvwr.msc→ Enter - Navigate to Windows Logs → Application
- Filter by source: Defrag
- Open the latest entry and look for the unmovable file path
The log revealed:
The last unmovable file appears to be: \$Mft::$DATA
Shrink potential target (LCN address): 0x2c0474b
$Mft is the NTFS Master File Table — the index of every file on the drive. It had settled near the end of the disk and Windows has absolutely no way to move it natively.
You can confirm the exact cluster with the fsutil command shown in the log:
fsutil volume querycluster \\?\Volume{your-volume-guid} 0x672609f
Pro tip from the community: If your Event Viewer shows
C:\$Extend\$UsnJrnl:$J:$DATAinstead of$Mft, you can fix it with just:
*fsutil usn delete journal /n C:*
This safely deletes the NTFS change journal (used by backup/indexing software, not the filesystem itself). No data loss, no reboot — and it often unlocks significantly more shrink space immediately.
The Fix: MiniTool Partition Wizard (Free)
Windows’ built-in Shrink Volume cannot move $Mft. You need a third-party partition manager that operates before Windows fully loads — allowing it to relocate even unmovable system files.
Download: partitionwizard.com — use the Free version. Decline any bundled offers during installation.
Steps in MiniTool:
- Open MiniTool Partition Wizard
- Click on the C:OS partition to select it
- In the left panel, click “Move/Resize Partition”
- Drag the right edge leftward to free your desired space
- To free 160 GB, set “Unallocated Space After” to
163840MB
- Click OK
- Click Apply (top left) → confirm
MiniTool showing the full disk layout. Important: use “Move/Resize Partition” from the left panel — NOT “Extend Partition” (that makes C: bigger, not smaller — an easy mistake to make!).
What happens on Apply:
- MiniTool prompts you to reboot. Make sure to be plugged in during this process — any crash during this may corrupt data. It is important to back important files up.
- On reboot you’ll see a black screen with a progress bar — completely normal
- The resize happens before Windows loads, bypassing all unmovable file restrictions
- Takes roughly 10–20 minutes — do not power off during this
- PC boots back into Windows normally once complete
Before You Apply: Back Up What Matters
MiniTool is reliable and widely used, but no partition operation is completely risk-free — especially one that moves the Master File Table. A power cut mid-operation could corrupt the partition table.
You don’t need a full system image. Just copy what matters to an external drive:
- Documents, Desktop, Downloads, Pictures
- Project files and code
- Browser bookmarks (export from browser settings)
- App-specific data: SSH keys, IDE settings, etc.
Windows itself and installed apps can always be reinstalled. Your personal files cannot.
After MiniTool: Unallocated Space Ready for Ubuntu
Once MiniTool finishes and your PC reboots back into Windows, open Disk Management — you’ll see a new unallocated block of your chosen size sitting next to C:. That’s your Ubuntu partition space, ready to go.
Boot from your Ubuntu USB installer and proceed. The Ubuntu installer detects the unallocated space automatically and offers to install alongside Windows.
Quick Reference: What Each Step Actually Does
Disable hibernation — Frees 8–30 GB instantly. No reboot needed. (powercfg /h off)
Disable page file — Frees 4–16 GB. Reboot required before the space shows up.
Delete restore points — Frees 1–10 GB depending on how long the system has been running.
Disk Cleanup (system files) — Frees 2–20 GB. Windows Update Cleanup is the biggest win here.
Defrag — Doesn’t free space directly, but moves files toward the start of the disk to unlock contiguous space at the end.
MiniTool Move/Resize — The nuclear option. Bypasses all unmovable file limits and can shrink up to the full available free space.
TL;DR
Windows’ Shrink Volume gets blocked by unmovable system files — even with hundreds of GB free. Disabling hibernation, the page file, system restore, running Disk Cleanup, and defragging helps but usually isn’t enough. Use Event Viewer → Application → Defrag logs to identify the exact blocking file ($Mft or $UsnJrnl are the most common culprits). For the final mile, use MiniTool Partition Wizard Free — it handles what Windows can't by resizing before the OS loads.
Tested on: Windows 11, ASUS laptop, Micron 2450 512 GB NVMe SSD (MTFDKBA512TFK), Ubuntu 24.04 LTS
메타데이터
- post_id
- b3ad9367edfe
- slug
- how-i-finally-got-ubuntu-running-alongside-windows-after-windows-refused-to-give-up-space-b3ad9367edfe
- url
- https://medium.com/@yellareharsh/how-i-finally-got-ubuntu-running-alongside-windows-after-windows-refused-to-give-up-space-b3ad9367edfe
- canonical_url
- https://medium.com/@yellareharsh/how-i-finally-got-ubuntu-running-alongside-windows-after-windows-refused-to-give-up-space-b3ad9367edfe
- author_url
- https://medium.com/@yellareharsh
- status
- ok
- fetched_at
- 2026-06-15 20:49:13