0XC00D0009

FIX: NS_E_CANNOTOFFLINEDISK (0xC00D0009) Disk Offline Error

Hardware – Hard Drives Intermediate 👁 0 views 📅 May 27, 2026

This error pops up when trying to take a disk offline in Disk Management. Usually it's because the disk is the system or boot drive.

You're in Disk Management, right-click a disk, pick 'Offline,' and bam — error NS_E_CANNOTOFFLINEDISK (0xC00D0009). Maybe you're prepping a drive for removal, or testing a backup disk. This error usually hits on the system disk (C: drive) or the boot disk (the one with Windows boot files).

What's Actually Happening

Windows won't let you offline a disk that's currently holding critical system files. That includes the page file, hibernation file, or active system partitions. The OS is smart enough to protect itself — it won't let you yank the rug out from under it. The error code 0xC00D0009 basically means "I can't do that, Dave."

But sometimes you're trying to offline a secondary disk — say a 2TB data drive — and it still fails. That's usually because that disk has a hidden system partition, like a System Reserved partition or a recovery partition. Windows sees that and treats the whole disk as critical.

Prerequisites

You'll need to log in as an administrator. If you're on a domain-joined machine, make sure your account has local admin rights. Standard users can't offline disks at all — they just get access denied.

Fix: Identify and Remove the Stubborn Partition

Here's the real fix — we'll find the partition that's blocking you and move it off the disk. I've done this dozens of times. It works.

  1. Open Disk Management. Press Win + X and pick 'Disk Management.'
  2. Find the problem disk. Look at the list of disks at the bottom. The one giving you error 0xC00D0009 — note its disk number (e.g., Disk 2).
  3. Open an elevated Command Prompt. Press Win + R, type cmd, hold Ctrl + Shift, and hit Enter. Yes, that's important — without admin rights, diskpart won't work.
  4. Start diskpart. Type diskpart and press Enter. You'll see a new prompt: DISKPART>. After you type it, you should see "Microsoft DiskPart version ..."
  5. Select your disk. Type select disk 2 (replace 2 with your disk number). You'll see "Disk 2 is now the selected disk."
  6. List all partitions. Type list partition. You'll see a list like this:
    Partition ###  Type              Size     Offset
    -------------  ----------------  -------  -------
    Partition 1    Recovery          500 MB   1024 KB
    Partition 2    System            100 MB   501 MB
    Partition 3    Primary           931 GB   601 MB
    Look for any partition that says "Recovery" or "System" (not the primary data partition). Those are your culprits.
  7. Select the recovery partition. Type select partition 1 (if that's your recovery partition).
  8. Delete it. Type delete partition override. The override flag forces deletion even if Windows thinks it's protected. After you press Enter, you should see "DiskPart successfully deleted the partition."
  9. Repeat for system partitions. If there's a System partition (usually 100MB or 50MB), select it and run delete partition override as well. But be careful — if this is your system disk's only system partition, don't delete it. If it's on a secondary disk, it's safe.
  10. Now try to offline the disk again. Go back to Disk Management, right-click the disk, and choose 'Offline.' This time it should work. You'll see the disk status change to 'Offline.'

What If It Still Fails?

If you're still getting 0xC00D0009, here are the usual culprits:

  • Active page file. If the disk has a page file on it, Windows won't let it go offline. Check under System Properties > Advanced > Performance > Virtual memory. If it's using this disk, move the page file to another disk, reboot, and try again.
  • Active shadow copies. Open an admin command prompt and run vssadmin list shadows. If you see shadows on the disk, delete them with vssadmin delete shadows /all. Then retry.
  • Disk is a dynamic disk with shared data. Dynamic disks that are part of a spanned or striped volume can't be offlined individually. You'd need to break the volume first — which deletes data. Back up first.
  • It's the actual system disk. If you're trying to offline C: drive — you can't while Windows is running. You'd need to boot from another drive or a recovery environment. There's no workaround for that.

Honestly, 9 times out of 10, the fix is deleting that leftover recovery or system partition. Microsoft puts them on every drive by default — even secondary drives — and they cause exactly this headache. Once it's gone, the disk behaves like a normal data drive and offlines without a fuss.

Was this solution helpful?