Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

Donnation

Suspended
Nov 2, 2014
1,686
2,083
That isn't the correct command. Instead, use: 'pmset -b tcpkeepalive 0'

This will set tcpkeepalive to 0 for battery mode. Replace '-b' with '-c' to set tcpkeepalive for charging mode. I personally leave it on in charging mode, and only set it for battery.

To see a list of the configurable power settings, use: 'pmset -g'. I recommend reading the man page for more information.

I realize this thread is a little older, but I wanted to thank you. I purchased a new mid 2015 MacBook Pro 15" and this battery drain while sleeping was driving me insane. After searching and searching I finally came across this thread and it fixed it for me. Thanks so much.
 

navier

macrumors regular
Aug 4, 2011
221
230
Germany
I realize this thread is a little older, but I wanted to thank you. I purchased a new mid 2015 MacBook Pro 15" and this battery drain while sleeping was driving me insane. After searching and searching I finally came across this thread and it fixed it for me. Thanks so much.

But the changes aren't permanent, I mean, somewhat still draining
 

SamVilde

macrumors regular
Oct 18, 2008
169
80
New York City
I picked up a refurbished 2017 tbMBP in August, and was pleasantly surprised to have no significant battery drain. I had seen this thread, and had been planning on following the advice here, but happily - it wasn't necessary.

But I have felt like battery drain has gotten worse lately, so I paid attention today. The computer went from 27% to 15% sitting closed on the desk over ten hours today, all apps closed out.

Since it was good, and is now bad - what gives? Is something new and worse in High Sierra? What's the latest recommendation for a fix? Simple would be helpful - I've never used Terminal before and tinkering makes me a little nervous.

Thanks.
 

yoursen

macrumors newbie
Nov 28, 2017
1
0
Last week I've worked on resolving this 10% battery consuming during night with closed lid on my MBP 2016. So I've tried disabling keep alive during sleep, reseting SMC, and even reinstalling Hight Sierra. Nothing helps me, but one day I left MacBook with closed Skype. And it works for me, 0-1% of battery usage per night.
 

precision01

macrumors regular
Oct 16, 2014
110
83
After updating to high sierra a few weeks ago my late 2016 15” MBP is being plagued with this issue again, and more severily this time: battery in being completely drained in 36 - 40 hours. And MBP is always hot.
Every do not disturb option is configurated as it should to not wake up, but I’m still suffering from that issue, what makes me have to keep charging cable always connected.
 

deepakvrao

macrumors 6502
Oct 16, 2011
335
29
India
I know it's an old thread, but tried everything here, and my new 2017 12" MB drains 10% over 6 hours at night. At the same time, my wife 2011 showed no drain at all.

Any other suggestions?
 

Mixolyd

macrumors member
Original poster
Jul 10, 2014
74
32
Oregon
I know it's an old thread, but tried everything here, and my new 2017 12" MB drains 10% over 6 hours at night. At the same time, my wife 2011 showed no drain at all.

Any other suggestions?
Go to Apple store Genius Bar and let us know what they say? My issue came back and I’m losing about 10% overnight. No idea how to fix it. I’m thinking it’s just how their batteries are. Pmset is no longer showing constant wakes during sleep but drain still occurs. It even still drains when shut down for me
 

deepakvrao

macrumors 6502
Oct 16, 2011
335
29
India
Go to Apple store Genius Bar and let us know what they say? My issue came back and I’m losing about 10% overnight. No idea how to fix it. I’m thinking it’s just how their batteries are. Pmset is no longer showing constant wakes during sleep but drain still occurs. It even still drains when shut down for me

No Genius Bar where I live. India.
 

Furzul

macrumors 6502a
Jan 13, 2013
778
399
Derbyshire, England
I know it's an old thread, but tried everything here, and my new 2017 12" MB drains 10% over 6 hours at night. At the same time, my wife 2011 showed no drain at all.

Any other suggestions?
What OSX are you on. Mine did the same (drain around 10% overnight.
Updated to High Sierra last September. Now over night it does not drop at all.
 

MrGuder

macrumors 68040
Nov 30, 2012
3,030
2,014
Yeah my drain is back as well, 2017 MBP 15" I'm on the latest Sierra update but have not jumped over to High Sierra yet, I wonder if that will solve the issue?
 

deepakvrao

macrumors 6502
Oct 16, 2011
335
29
India
What OSX are you on. Mine did the same (drain around 10% overnight.
Updated to High Sierra last September. Now over night it does not drop at all.

Brand new MacBook 12 running the latest update of High Sierra.

Funny, I loaded the same on my wife's 2011 air, and it shows no battery loss overnight, or at most 1-2%.
 

deepakvrao

macrumors 6502
Oct 16, 2011
335
29
India
Yeah my drain is back as well, 2017 MBP 15" I'm on the latest Sierra update but have not jumped over to High Sierra yet, I wonder if that will solve the issue?
What OSX are you on. Mine did the same (drain around 10% overnight.
Updated to High Sierra last September. Now over night it does not drop at all.


This I 'think' has solved my problem. Set to hibernate mode 25, and it takes a while to wake, but over 2 hours at least not seen any battery loss, AND the log shows no wake episodes, which I was having every few minutes earlier.

https://computers.tutsplus.com/tutorials/how-to-hibernate-a-mac--cms-23235
 

MrGuder

macrumors 68040
Nov 30, 2012
3,030
2,014
^^I haven't read the whole article yet but I will later but doesn't using hibernation create more wear and tear on your MacBook every night vs just putting it in sleep mode?
 

deepakvrao

macrumors 6502
Oct 16, 2011
335
29
India
^^I haven't read the whole article yet but I will later but doesn't using hibernation create more wear and tear on your MacBook every night vs just putting it in sleep mode?

Why should it?

Have noticed that it takes a while, maybe about 20-30 seconds for me to be able to start working when I wake up the MB from there hibernate 25 mode, but I guess thats to be expected. If I save huge battery when it is asleep, I'm ok with it.
 

damant

macrumors 6502
Feb 14, 2010
295
22
FYI,
latest HS is well behaved on MBP 2017... about 2% overnight .
I'm perfectly happy with that :)
 

Charlie7

macrumors newbie
May 18, 2018
3
1
FYI,
latest HS is well behaved on MBP 2017... about 2% overnight .
I'm perfectly happy with that :)

Just want to share, Before I updated to HS 10.13.4 there was no batt drain at all using "TCPalive 0" method. Recently I updated to latest HS and security "stupid' update for 1GB and it caused my MBP drain 2-6% overnight. Really not happy at all.....I'm on MBP 2017 non touch.
 

andrit

macrumors newbie
Sep 14, 2018
6
0
Just want to share, Before I updated to HS 10.13.4 there was no batt drain at all using "TCPalive 0" method. Recently I updated to latest HS and security "stupid' update for 1GB and it caused my MBP drain 2-6% overnight. Really not happy at all.....I'm on MBP 2017 non touch.

Did the update revert your tcpkeepalive setting maybe?
 

empty spaces

macrumors newbie
Jan 27, 2019
1
0
Update: I no longer recommend using this fix. Something changed in 10.12.4. After redoing the steps outlined, I saw that the drain was about the same as without the fix, but then for the next days saw that it actually was worse. One night my battery dropped 10% overnight, and pmset showed no wakes. Very odd. I had to revert to a Time Machine backup because simply undoing the steps by changing the text does not revert this for whatever reason. So my suggestion is that if you are on 10.12.4 then do not follow this guide and learn to live with the slight drain that occurs. I'm not aware of any fix at the moment. Note this is with a 2016 MBP nTB so it may be different with 2015 or the regular MB.

Just wanted to report that the fix worked for a rMBP 13" 2015 on Mojave (10.14.3). No wakes for 8 hours:
Code:
~> pmset -g log | egrep "Sleep state|Wake from"
....
2019-01-27 05:19:49 +0300 Sleep                   Entering Sleep state due to 'Clamshell Sleep': Using AC (Charge:100%) 28008 secs
2019-01-27 13:06:37 +0300 Wake                    Wake from Safe Sleep [CDNVA] due to EC.LidOpen/Lid Open: Using BATT (Charge:100%)

Was like 10-20% battery drain overnight before the fix, now it's 0-2%
 

jjojeda98

macrumors newbie
Mar 31, 2019
1
0
Just wanted to report that the fix worked for a rMBP 13" 2015 on Mojave (10.14.3). No wakes for 8 hours:
Code:
~> pmset -g log | egrep "Sleep state|Wake from"
....
2019-01-27 05:19:49 +0300 Sleep                   Entering Sleep state due to 'Clamshell Sleep': Using AC (Charge:100%) 28008 secs
2019-01-27 13:06:37 +0300 Wake                    Wake from Safe Sleep [CDNVA] due to EC.LidOpen/Lid Open: Using BATT (Charge:100%)

Was like 10-20% battery drain overnight before the fix, now it's 0-2%
Is this still working for you after the 10.14.4 update? It was working great for 10.14.3 but after the update it doesn't seem to work anymore and I cannot revert the settings by undoing the steps, like OP said. My energy saver settings seem to be stuck with these settings as well and I can't get them back to how they were before (included power nap feature and only one slider per tab, not two)
 

Attachments

  • Screen Shot 2019-03-31 at 5.00.25 PM.png
    Screen Shot 2019-03-31 at 5.00.25 PM.png
    387.4 KB · Views: 314

saskeirik

macrumors newbie
Jun 9, 2019
1
2
Is this still working for you after the 10.14.4 update? It was working great for 10.14.3 but after the update it doesn't seem to work anymore and I cannot revert the settings by undoing the steps, like OP said. My energy saver settings seem to be stuck with these settings as well and I can't get them back to how they were before (included power nap feature and only one slider per tab, not two)


Just wanted to chime in and let everyone know I followed the advice in the original post and I'm no longer experiencing excessive wakes.

Recently purchased a 13in rMBP used. I was experiencing dark wakes that would last for 45 seconds, but I would get one every minute. So the Macbook was writing its ram into the SSD every. single. time. and also running super hot and draining the battery. I tried the Hibernate 25 trick. Also disabling wifi on sleep. Nothing really worked.

Then I tried this hack. Turned off SIP, went into the my file and deleted the four entries, rebooted and found that the Macbook wasn't waking randomly anymore.

Just out of curiosity, has anyone figured out why the Macs are waking up constantly? What are they trying to do? Reach back out to the mothership? I could never track down the app or process that was waking the Mac. Of course I'm new to Mac, so I'm still learning things. For instance how to use the terminal lol.

**edit I'm on 10.14.5
 
Last edited:

MrGuder

macrumors 68040
Nov 30, 2012
3,030
2,014
Mine started doing this again, I never do a full shut down just close lid and at night I could have 28% battery and when I open the lid the next day I’m at 12% can’t figure why it’s using so much battery over night when it’s not in use.
 

throwthedice

macrumors 6502
Aug 27, 2015
267
87
<Mods: Apologies for bumping an old thread.>

I recently updated my MBP early 2015 to Mojave 10.14.6 and I've noticed this battery drain. I tried a few things already - manually change to DND overnight, tried some of the commands that changed the pmset values. The drain reduced a bit, but not as much as I would have liked. I've come across this thread and wanted to post somethings I'm seeing now.

Code:
$ioreg -l | grep IOPlatformFeatureDefaults
    | | |   "IOPlatformFeatureDefaults" = {"TCPKeepAliveDuringSleep"=Yes,"DNDWhileDisplaySleeps"=No,"TCPKeepAliveExpirationTimeout"=43200,"NotificationWake"=Yes}


Code:
$ pmset -g
System-wide power settings:
Currently in use:
 lidwake              1
 autopoweroff         1
 standbydelayhigh     3600
 autopoweroffdelay    3600
 proximitywake        0
 standby              1
 standbydelaylow      3600
 ttyskeepawake        0
 highstandbythreshold 50
 powernap             0
 gpuswitch            2
 hibernatefile        /var/vm/sleepimage
 hibernatemode        3
 displaysleep         1
 sleep                1
 tcpkeepalive         0
 halfdim              1
 acwake               0
 disksleep            10

The output of the two commands is so contradictory as far as "tcpkeepalive" parameters are concerned. I've done the usual SMC reset etc., and this is now becoming an annoyance.

Has anyone been able to figure this out?
 

MrGuder

macrumors 68040
Nov 30, 2012
3,030
2,014
My 2017 MBP 15” is still draining bad overnight. I’m still on original OS Sierra. I might as well just update it to Mojave if that’s draining too. Lol
 

throwthedice

macrumors 6502
Aug 27, 2015
267
87
@MrGuder If you haven't already, try manually turning off wifi before you close the lid every time. This has been helping me avoid serious drain overnight (30%+).
 
  • Like
Reactions: MrGuder
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.