Jump to content
Allan

Sleep, Hibernation - How it works? and How to use?

4 posts in this topic

Recommended Posts

Advertisement

I'll buy an SSD, is good use the Hibernation mode?

Well, we know that SSDs can boot up very fast in comparison with traditional HDD drivers, and maybe we think when we buy an SSD: "Uh, if i use Hibernation mode, all the things will be more fast!!  :w00t: "

Yes but if you already read about how the new SSD's technologies works, you'll see that use Hibernation mode can destroy your new toy.

But why this happens?

The short explanation: "Hibernation copies everything in RAM into the SSD drive that sometimes results in wearing out the SSDs."

Questions:

#1 - Q: But using SSD + Hibernation mode, will be good to my Battery life, why i need disable it?
A: Using an SSD is very different when you use a HDD drive, consider that using a SSD the power consumption is very low than HDD, you don't need worry about it.  ;)

#2 - Q: I don't care about this stuff, i want use Hibernation mode anyway!!
A: Ok, ok, relax!  ^_^
You can move the sleepimage file to another drive, maybe an old HDD/SSD.

How? Terminal is the answer bro!

Run pmset -g command and you can check the current configuration for hibernate.

 

Screen Shot 2016-03-23 at 6.32.35 PM.png

 

The important informations here are: standbydelay and hibernatefile. The first one say us that our Mac/Hack will wait 4200 seconds before entering the "real' hibernate mode (before any information is written to the disk). The hibernate file is the location where RAM content are stored.

For example I decided just to relocate my sleepimage file.

Create folder on the second driver:

Allans-MacBook-Pro:~ allan$ mkdir -p /Volumes/YourHDD/System/vm

Change the hibernatefile property

sudo pmset -a hibernatefile /Volumes/YourHDD/System/vm/sleepimage

Check your currents settings

Allans-MacBook-Pro:~ allan$ sudo pmset -g 
Active Profiles: 
Battery Power -1* 
AC Power -1 
Currently in use: 
standbydelay 4200 
standby 0 
halfdim 1 
sms 1 
hibernatefile /Volumes/YourHDD/System/vm/sleepimage 
disksleep 10 
sleep 10 
hibernatemode 29 
ttyskeepawake 1 
displaysleep 15 
acwake 0 
lidwake 1

Now any time your Mac/Hack enters in hibernate mode, the RAM content is written in /Volumes/Media drive (your second internal HDD/SSD).

PS: This "other drive" can be an external HD or a USB3 thumb drive.
PS 2: This tip is valid for Mac users that have SSDs.  :)

Creditis to: Simply Meahmed_ais and AskDifferent

Edited by Allan
Updated [08/04/2018] - Text formatting

Share this post


Link to post
Share on other sites

How change Hibernate Mode in El Capitan

 

For OS X El Capitan, you'll need modify the com.apple.PowerManagement.plist.

Type this in Finder > Go > Go to folder/Library/Preferences/SystemConfiguration/com.apple.PowerManagement.plist

 

And find the Hibernate Mode in both section and put the value that you want.

 

UPDATE: If you use "sudo su" in Terminal, and after that run the command that you want, e.g: "pmset -a hibernatemode 0", the hibernation mode will be changed.

Edited by Allan
sudo su

Share this post


Link to post
Share on other sites

  • Recently Browsing   0 members

    No registered users viewing this page.

  • Similar Content

    • By pepitillo
      Hi there, I noticed that my system cannot sleep properly, so I run pmset.
      Here are the results. The strange thing is that I got "sleep   0 (sleep prevented by mds)". What does it mean? Do you think that all other parameters are good to go?
      Recently I managed to fix reboot on shutdown. Maybe its linked with that.
       
      iMac:~ diego$ pmset -g
      System-wide power settings:
      Currently in use:
      standby              1
      Sleep On Power Button 1
      womp                 0
      autorestart          0
      hibernatefile        /var/vm/sleepimage
      powernap             0
      networkoversleep     0
      disksleep            10
      sleep                0 (sleep prevented by mds)
      autopoweroffdelay    28800
      hibernatemode        0
      autopoweroff         1
      ttyskeepawake        1
      displaysleep         0
      tcpkeepalive         1
      standbydelay         10800
       
      Thanks!
    • By DapperDuck
      Quite the title I have chosen for this topic no?
       
      I got my Hackintosh up and running since yesterday. I followed this topic
       and used @MaLd0n 's CLOVER.zip files for kext installation and for the included SSDT's and DSDT. Massive thanks for that btw.
       
      The only *slight* problem I still have is when I have XMP set to profile 1 in the Gigabyte BIOS, and I put my Hackintosh to sleep and I wake it up, I get the message that all USB drives were not ejected properly.
       
      I really don't understand what's causing this problem. I currently have disabled XMP in the BIOS and the USB drives are not getting ejected when my Hack wakes from sleep.
      I use 16GB of Corsair DDR4 Vengeance ram which goes up to 3000MHz. I have XMP profile in CLOVER set to 1. About this Mac reports that my RAM speed is 2998 Mhz. I have a separate SSD drive with Windows on it and I do not think it utilises the full MHz of the RAM because XMP is disabled. 
       
      Hopefully someone is able to help me.
       
      Hackintosh specs:
      Gigabyte Aorus ultimate gaming 
      i7-8700k
      Corsair Vengeance DDR4 3000Mhz RAM (16GB)
      Nvidia GTX 1080
      System def: iMac 18,3
       
      I have my config.plist in the attached files. Hope this gives enough insight. 
      config.plist
    • By Babiloe
      Notebook Asus X550VX i7 - 7700hq
      GTX950MX - UHD630
      A1718086 - 025510ec ALC255 that works only on VoodooHDA 
      RTL8111 LAN
      Hwinfo
      https://drive.google.com/open?id=1n5rHIw-jDPCgocWJtZ0AoVlqIi6Xc7XL
       
      Not work:
      1. White Screen Wake up

       
      EDID not a asolution
      IOREG output http://www.mediafire.com/file/u7odzbaxa7bbb6a/ioregSaved.txt and EDID
      http://www.mediafire.com/file/hqlapgf4luwchdf/DisplayProductID-69c.plist
      Image
      https://ibb.co/faL5wx
      2. Battery info status bar sometimes goes on / off like battery has off
      3. Crackle Sound using   earphone using VoodooHDA
             Still investigation using patched iomatch voodooha info.plist
             The sound card can’t be using AppleALC, no sound came out using layout 3, 13, 17, 18, 27, 28, 99

      I have  (Mald0n) DSDT
      thank you for maldon for helping me
       
      http://www.mediafire.com/file/lmp5yy65rblx9ne/DSDTtitomaldon2.dsl
       
      I have re-patched again for FnKeys and Brighness Key
      http://www.mediafire.com/file/5rs93ij0wco99s6/DSDTtitomaldon2editv2.aml


       
      codec dump linux
      https://drive.google.com/file/d/1pg2y76WvFYsO8vFY-2B_2OLyKMmkQ8Tg/view
       
       
      latest debug
      http://www.mediafire.com/file/2pjny4eq5r64ed8/debug_1383 (1).zip
       
      clover and kext
      https://drive.google.com/open?id=1n5rHIw-jDPCgocWJtZ0AoVlqIi6Xc7XL
    • By gamender
      Can not get the system to shutdown correctly, screen will go black but the fans keep running and power light stays on. Same happens when I attempt to sleep.
      Any Help would be appreciated.
       
    • By coscos
      I recently set up my hackintosh. Everything else works fine, the only issue is my monitor cannot come back from sleep.
      Symptom: 
      If I click the "sleep" menu manually, the system goes to sleep fine. After the system sleeps for a while (more than a few mins, I guess it's called "deep sleep"), when I try to wake it up, the monitor wakes up but stays black screen. The machine is on. If I leave the system to time out and sleep by itself, only the monitor goes off; when I try to wake it up, same symptom as above.
      What I have tried (but none worked):
      additional boot flag: ngfxpatch=pikera additional boot flag: darkwake = 0 Customize EDID
      Specs:
      Motherboard: Gigabyte Z77x-UD5H BIOS: F16j CPU: Ivy Bridge i5-3570K CPU @ 3.40GHz (quad core) Graphics: Nvidia GTX 1050 Monitor: Dell P2715Q @ 4k / 60Hz, Display Port Wifi / Bluetooth: BCM94360CS with PCIE Onboard GPU: disabled OS: High Sierra 10.13.3
      Please see attached for following files:
      EFI zip file: https://www.dropbox.com/s/8nun37msu9b1bva/EFI.zip?dl=0 I generated my own SSDT.aml using ssdtPRGen.sh; Other SSDT patches are copied from this repository: https://github.com/VoiletDragon/Z77X-UD5H-Clover-Hotpatch-Patches ioreg dump: https://www.dropbox.com/s/5a10k82guczaaws/macchiato.ioreg.zip?dl=0 result from following command: https://www.dropbox.com/s/0b22qcw79ovnjdg/kext-touch.txt.zip?dl=0 kextstat|grep -y acpiplat kextstat|grep -y appleintelcpu kextstat|grep -y applelpc kextstat|grep -y applehda sudo touch /System/Library/Extensions && sudo kextcache -u /
      I am looking forward to your suggestions. Thanks.
×