Skip to content

Instantly share code, notes, and snippets.

@hariel18
Created May 26, 2016 08:00
Show Gist options
  • Star 2 You must be signed in to star a gist
  • Fork 3 You must be signed in to fork a gist
  • Save hariel18/c370bf53fe795bd7aa345937746251b0 to your computer and use it in GitHub Desktop.
Save hariel18/c370bf53fe795bd7aa345937746251b0 to your computer and use it in GitHub Desktop.
OSX: Disable Hibernate mode
#http://www.engadget.com/2011/08/22/why-hibernate-or-safe-sleep-mode-is-no-longer-necessary-in-os/
#https://www.idelta.info/archives/some-hidden-changes-in-os-x-el-capitan/
# disable hibernation
sudo pmset hibernatemode 0
# clear the image file
sudo rm -rf /var/vm/sleepimage
# inhibit file recreation
sudo touch /private/var/vm/sleepimage
sudo chflags uchg /private/var/vm/sleepimage
# additional commands (set to 1 to re-enable)
# reference: https://www.macissues.com/2015/05/08/how-to-fix-your-mac-not-waking-from-sleep/
# Apple’s main standby mode option
sudo pmset standby 0
# implementation required for European energy regulations
sudo pmset autopoweroff 0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment