Disable Safe Sleep in OSX

While OSX falling asleep, it save all memory into a local disk file, for avoiding data loss caused by batteries running out while sleeping. But it comes with some disadvantages:

  • That file is the same size as your memory. It eats your hard drive. You may not want this on a SSD solution;
  • Writing a so huge file requires more time while entering sleep mode.

And, when is the last time your mac’s battery running out while sleeping? Never, I guess.

Good news is, if you pleased, you can disable this function by running these two commands in terminal window.

sudo rm /private/var/vm/sleepimage
sudo pmset -a hibernatemode 0

These commands above will delete the existed image file and disable the further creation process of this file. Of course, after taking these steps, your computer will not able to resume from sleep while battery running out, by taking a cold boot instead. You may lost all unsaved data in that rare situation.

Leave a Reply

Your email address will not be published. Required fields are marked *