Tricky question on safe sleep when hibernatemode is 0 for charger and 3 for battery

Discussion in 'macOS' started by ordiple, Jul 15, 2013.

  1. ordiple macrumors newbie

    Feb 8, 2009
    // Also posted this in Apple's official forum...

    Hi folks,

    I've just replaced the HDD with a Samsung 830 series 512GB SSD in my 2010 15' Macbook Pro and done some pretty routine optimizations (e.g., trim on, localbackup off, sms off, etc.).

    However when it comes to energy saver settings, it starts to look a bit hard to fit my needs:

    1) I DO want it to sleep whenever possible regardless of the power source type (charger or battery).
    2) In charger mode, I DON'T want it to dump the ram image to disk before sleeping.
    3) In battery mode, I PREFER not dumping (but OKAY with it) before sleeping.
    4) In battery mode, I DO want it to dump the ram image when the battery runs low.

    Please note that this is a 2010 MBP, no support for the "standby"/"standbydelay" feature which can be found in later models. So if you set hibernatemode to 3, it will dump the whole 8GB ram image to disk every time RIGHT BEFORE it enters sleep mode. Every time, literally, even if you just let it sleep for only 20 seconds. This could be a nightmare for a SSD, so I definately don't want it unless I'm on battery (5% of my time).

    So my choice is to set (via pmset) hibernatemode to 0 for charger mode, and 3 for battery mode and enable sleep in both modes. And that seems to satisfy the above 1), 2), and 3). But I'm not so sure if 4) is 100% supported, consider the below scenario:

    a) The MBP is connected to a charger, now let it enter sleep mode. No ram image is written to disk because hibernatemode = 0.
    b) Now you unplug the charger, it will continue sleeping, but on battery power. From now on, hibernatemode = 3.
    c) Eventually the battery power will run low... What will it do? I doubt it will get a chance to dump the ram image although hibernatemode = 3, because it is still sleeping, right?

    Unfortunately, it would take maybe 4 or 5 days to experiment with the above scenario (depending on how long it can sleep on battery power ) so I don't think I am allowed to do that myself.

    Does anyone has any knowledge regarding MBP's behavior in this specific case? Thank you.
  2. benwiggy macrumors 68020

    Jun 15, 2012
    You've got a 512GB SSD. So you've got no worries about the size taken up by the sleep image.

    Modern SSDs can cope with the repeated saving of a large file like this. You are going to use up all your precious writes. The SSD will, probably, outlast your usage of the MBP. The days of having to guard against using your SSD whenever possible to preserve it are gone.

    So, why do you want to alter this?

Share This Page