External Drive Not Ejecting on Mac After Sleep

Mac waking from sleep and showing 'Disk Not Ejected Properly'? Here's why it happens and how to stop it for good on macOS Sonoma and Sequoia.

Mac goes to sleep, Mac wakes up, and there it is: “Disk Not Ejected Properly.” The drive is still physically plugged in, nothing looks wrong, yet macOS is convinced something went sideways. This isn’t a fluke — it’s a well-documented pattern that affects everything from M-chip Mac minis to MacBook Pros, and it’s been showing up in Apple discussions threads since at least Ventura.

Here’s what’s actually happening, and what you can do about it.

Why Sleep Causes Ejection Errors

When your Mac enters sleep, it suspends most processes — but not always in a clean, orderly way. The problem is that macOS can cut power to USB or Thunderbolt buses before properly unmounting the drives attached to them. From the drive’s perspective, the connection just vanished mid-session. macOS detects this on wake and reports it as an improper ejection, even though you never touched the drive.

There are a few specific mechanisms at play:

  • USB bus power suspension. During deep sleep, macOS may cut power to USB ports entirely. Drives that don’t handle this gracefully lose their connection without a proper unmount sequence.
  • Background processes still writing. Spotlight indexing, Time Machine, cloud sync agents, and even Finder can be mid-operation when sleep kicks in. If they’re touching the drive at the wrong moment, the forced suspension looks like a crash to the filesystem.
  • Thunderbolt/USB 3 negotiation on wake. Some drives — particularly external SSDs — have to re-negotiate the connection protocol on wake. If that handshake fails or takes too long, macOS gives up and marks the drive as improperly ejected.

This is closely related to the broader pattern of external drives keeping disconnecting on Mac, but the sleep/wake trigger makes it more predictable and, fortunately, more fixable.

Is It Actually Dangerous?

Seeing the “Disk Not Ejected Properly” alert repeatedly is worth taking seriously. For spinning hard drives, sudden disconnects during writes can cause filesystem corruption. For SSDs, the risk is lower but not zero — incomplete writes can leave files in an inconsistent state.

If you want to understand the real risk profile, Can Unplugging an External Drive Without Ejecting Damage It? covers the mechanics in detail. The short version: occasional sleep-triggered disconnects are unlikely to destroy data, but repeated occurrences — especially during active writes — are a problem worth solving rather than ignoring.

Warning: If your drive is formatted as APFS, filesystem inconsistencies from repeated improper ejections can occasionally require a First Aid repair in Disk Utility. Run Disk Utility → First Aid on the drive if you notice sluggish performance or missing files after a string of these errors.

Step-by-Step Fixes

1. Prevent macOS From Sleeping While the Drive Is Connected

The most reliable fix is to stop the Mac from entering full system sleep when an external drive is attached. This isn’t always practical on a laptop running on battery, but it’s the right answer for a desktop or a Mac used as a workstation.

On macOS Ventura and later:

  1. Open System Settings → Battery (or Energy Saver on desktop Macs).
  2. Enable “Prevent automatic sleeping when the display is off” — or on MacBooks, set this to apply when plugged in.
  3. Set the display to sleep separately under “Turn display off after” — the display can sleep without the system sleeping.

This keeps the USB/Thunderbolt bus active and lets background processes finish cleanly before any power state changes.

2. Disable Power Nap (and Wake for Network Access)

Power Nap lets your Mac perform background tasks while sleeping — but it can also trigger partial wake cycles that interact badly with connected drives.

  1. Go to System Settings → Battery → Options (or Energy Saver → Power Nap).
  2. Turn off Power Nap.
  3. Also disable “Wake for network access” if it’s enabled.

These settings are particularly relevant on M-series Macs, where the efficiency cores stay active during sleep and can resume Spotlight or iCloud sync mid-nap.

3. Identify What Was Using the Drive Before Sleep

If you’d rather keep sleep enabled, the next step is finding out which process was holding the drive open when the Mac went under. This is where most generic advice falls short — “close your apps” doesn’t help when the culprit is a system daemon.

Common offenders in sleep-related ejection failures:

  • Spotlight (mds / mdworker) — indexing a newly connected drive right as sleep kicks in
  • backupd — Time Machine mid-backup
  • cloudd / bird — iCloud Drive syncing files to the drive
  • Finder — thumbnail generation or a lingering file operation

Ejecta shows you exactly which process is holding your drive at any given moment. If you catch the pattern — for example, Spotlight always seems to be active when sleep triggers — you can address that specific process rather than guessing.

4. Exclude the Drive From Spotlight Indexing

Spotlight is one of the most common background culprits. It indexes new or modified files continuously, and if it’s mid-index when sleep hits, the drive gets yanked out from under it.

To exclude a drive from Spotlight:

  1. Open System Settings → Siri & Spotlight → Spotlight Privacy (on older macOS: System Preferences → Spotlight → Privacy).
  2. Click + and add your external drive.

This stops Spotlight from indexing the drive entirely. If you need search on the drive, you can remove it from the exclusion list later — but for drives used purely for media or backups, exclusion is usually the right call. For more on cloud sync agents doing the same thing, see How to Stop iCloud and Dropbox From Blocking Drive Ejection.

5. Check the Drive’s Filesystem Format

Some filesystem formats handle unexpected disconnects more gracefully than others. APFS has journaling that helps recover from improper ejections. exFAT — common on drives shared between Mac and Windows — has no journaling at all, which means a sleep-triggered disconnect is more likely to leave the filesystem in a dirty state.

If your drive is formatted as exFAT and you’re seeing repeated ejection errors after sleep, consider whether you actually need cross-platform compatibility. If the drive is Mac-only, reformatting to APFS is worth it. The APFS vs exFAT comparison covers the trade-offs in full.

6. Update or Replace the Cable and Hub

This sounds too simple, but it’s genuinely responsible for a significant share of sleep-related ejection errors. A marginal cable or a bus-powered hub that loses power during sleep can cause the drive to disconnect at the hardware level — and no software fix will help.

Test by connecting the drive directly to a Mac port with a known-good cable. If the sleep ejection errors stop, the cable or hub was the problem.

Tip: Thunderbolt cables are not the same as USB-C cables, even though they use the same connector. If your external SSD came with a USB-C cable and you’re using it on a Thunderbolt port, try a proper Thunderbolt cable — the negotiation on wake is more reliable.

7. Reset SMC / NVRAM (Intel Macs)

On Intel Macs, the System Management Controller handles USB power states during sleep. A corrupted SMC can cause erratic behavior including improper drive ejections on wake.

  • SMC reset: Shut down, then hold Shift + Control + Option + Power for 10 seconds, release, then power on normally.
  • NVRAM reset: Restart and hold Option + Command + P + R until you hear the startup chime twice (or see the Apple logo appear and disappear twice on newer Intel models).

M-series Macs don’t have an SMC in the traditional sense — a full shutdown (not restart) for 30 seconds achieves a similar effect.

When the Errors Keep Coming Back

If you’ve worked through the list above and the “Disk Not Ejected Properly” alert still appears after every sleep cycle, the issue may be a macOS bug rather than a configuration problem. Apple silicon Macs running Ventura and Sonoma had a documented run of sleep-related USB issues, and some users on Sequoia still report them on specific hardware configurations.

In that case, the most practical workaround is to eject the drive manually before putting the Mac to sleep — and to use a tool that makes that fast. How to Fix ‘Disk Not Ejected Properly’ on Mac covers the full range of recovery steps if you’re already seeing filesystem errors from repeated incidents.

Stop Guessing What’s Blocking Your Drive

The hardest part of fixing sleep-related ejection errors is that macOS never tells you which process was responsible. It just shows the alert and moves on. Ejecta solves that — it sits in your menu bar, shows you every process currently holding your drive open, and lets you quit the blocker and eject safely in one click. No Terminal, no Activity Monitor, no guessing. If you’re tired of unplugging drives and hoping for the best, give it a try.