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

maccan

macrumors regular
Original poster
Feb 22, 2019
100
41
Hi,

I'm running macos Ventura 13.1 on a MacPro 2019.
Since upgrading from Monterey 12.6.1, I get wakeups from sleep due to scheduled power events I did not really defined intentionally:

From Terminal, "pmset -g sched" lists the following:

Scheduled power events:
[0] wake at 12/15/2022 16:04:26 by 'com.apple.alarm.user-visible-com.apple.CalendarNotification.EKTravelEngine.periodicRefreshTimer'
[1] wake at 12/16/2022 12:06:52 by 'com.apple.alarm.user-visible-com.apple.acmd.alarm'

You can cancel these events using the Terminal command "sudo pmset schedule cancelall"
However, within a few hours, some "ghost process" reschedules these events again at random times, causing the Mac to wake from sleep!

There are some discussions on the internet how to get rid of this upredictable behaviour.
At first hand, I did not found any discussion about this here, so I decided to post.

Does anybody knows how to get rid of these mysterious power events scheduling?
Which application(s) / processes cause it?
How can it be switched off permanently?

Best regards
 
Hi
Check your Power Nap option (should be off) + Prevent sleep at System Settings -> Power
 
Hi
Check your Power Nap option (should be off) + Prevent sleep at System Settings -> Power
"Enable Power Nap" is already off.

Below, my settings from "pmset -g"
System-wide power settings:
Currently in use:
autorestart 0
Sleep On Power Button 1
hibernatefile /var/vm/sleepimage
powernap 0
gpuswitch 2
networkoversleep 0
disksleep 10
sleep 1 (sleep prevented by AddressBookSourceSync, powerd)
hibernatemode 0
ttyskeepawake 1
displaysleep 15
tcpkeepalive 0
womp 0

I also did
launchctl unload -w /System/Library/LaunchAgents/com.apple.AddressBook.SourceSync.plist

This was successful in Monterey.
It seems in every major update you have to figure out some tricks to successfully sleep your mac.
 
  • Like
Reactions: appltech
Maybe Console can show where to dig? I mean to check logs right after those events were resurrected.
Thinking about those smart notifications (or how they called)
Heck, this can take a lot of time, but maybe temporary network disable, or iCloud sync.

And you don't have a printer or other devices connected, yes? Sometimes my PC will turn on automatically (Windows) when somebody lurking or accessing NAS on local network
 
The setup of my peripherals did not change.
In fact I do not have anything directly connected to the Mac. The printer is wired through ethernet.
I use cable mouse and keyboard. Everything is wired. Bluetooth and Wifi are always turned off.

In Monterey the machine was sleeping without any random wakeups regardless how long the sleep time was.

I assume nearly all Mac users running Ventura have thee random wakeups - most may not be aware of it.
In some cases the wakeups may result in problems if the Mac does not go back to sleep causing battery drains on laptops.

After searching some more time on the internet, I found other threads dealing with this. Even here on macrumors! Sorry for double posting this topic - I did not realized when starting this thread:

The other thread is

To summarize them all:
Nobody seems to know which process is scheduling these mysterious power events in MacOS Ventura:

I wonder how many mac users running MacOS Ventura (up to 13.1) have these power events constantly re-scheduled.
Just do "pmset -g sched"

This is my result:
-----------------------------
Scheduled power events:

[0] wake at 12/16/2022 16:28:44 by 'com.apple.alarm.user-visible-com.apple.CalendarNotification.EKTravelEngine.periodicRefreshTimer'

[1] wake at 12/17/2022 08:15:59 by 'com.apple.alarm.user-visible-com.apple.acmd.alarm'
----------------------------
 
In the meantime I found a solution to get rid of the power events. By "I found" I mean actually I found this thread:

Reminders app waking mac from sleep - Apple Community

So I tried it!

Behaviour before the fix:

  • "pmset -g sched" reports our beloved friends
[0] wake at 12/17/2022 00:41:44 by 'com.apple.alarm.user-visible-

com.apple.CalendarNotification.EKTravelEngine.periodicRefreshTimer'.

[1] wake at 12/17/2022 19:23:54 by 'com.apple.alarm.user-visible-com.apple.acm

  • "sudo pmset schedule cancelall"
  • "pmset -g sched" -> all good!
  • put Mac to sleep
  • wake it up by keystroke
  • "pmset -g sched" -> bad again


Now the fix:

"sudo pmset sched cancelall"

AND

"sudo chflags schg /Library/Preferences/SystemConfiguration/com.apple.AutoWake.plist"



"This prevents the system from updating the file and my MacBook no longer wakes to reminder events. Needles to mention that it prevents all scheduled system events like sleep, power-on and such."



"I recommend removing the flag before a system update:"

"sudo chflags noschg /Library/Preferences/SystemConfiguration/com.apple.AutoWake.plist"



Behaviour AFTER the fix:

  • "pmset -g sched" -> all good!
  • put Mac to sleep
  • wakeup Mac by keystroke
  • "pmset -g sched" -> all good and hope it remains as it is...


Will see tomorrow what "pmset -g log" reports...



Good luck to all...
 
  • Love
Reactions: mrwuf
Thanks for posting this. I also have the same issue on my 24" iMac and actually it also happened on my old 27" running Ventura.

I notice it because I have a QNAP TR-002 with two HDDs (RAID0) connected via USB attached to the iMac.

Each time the iMac wakes up, USB is enabled and the external HDD spins up., and then after short while it returns to sleep. External HDDs like a WD Mybook are not power on btw.

I think I saw mDNSResponder in the log file, isn't that the Bonjour service ? Can that be the cause ?
 
Thanks for posting this. I also have the same issue on my 24" iMac and actually it also happened on my old 27" running Ventura.

I notice it because I have a QNAP TR-002 with two HDDs (RAID0) connected via USB attached to the iMac.

Each time the iMac wakes up, USB is enabled and the external HDD spins up., and then after short while it returns to sleep. External HDDs like a WD Mybook are not power on btw.

I think I saw mDNSResponder in the log file, isn't that the Bonjour service ? Can that be the cause ?
Yes to your questioning! This is why over the years as network AdministratorI always turned off the service to all of our Macs when they came onto our network!
 
Hello @maccan ,
Thanks to you, I was able to cancel all scheduled events with the command "sudo chflags schg"

However I still have the same issue since I am losing around 10% of battery during the night, lid closed.
I just bought a MacBook Pro 14, fresh install, no restore from Time Machine Backup, Ventura 13.1

Did you manage to resolve the issue ?
 
Hello @maccan ,
Thanks to you, I was able to cancel all scheduled events with the command "sudo chflags schg"

However I still have the same issue since I am losing around 10% of battery during the night, lid closed.
I just bought a MacBook Pro 14, fresh install, no restore from Time Machine Backup, Ventura 13.1

Did you manage to resolve the issue ?
Hi,

Yes, after "sudo chflags schg /Library/Preferences/SystemConfiguration/com.apple.AutoWake.plist" my system is sleeping properly.

Over the weekend for example, there is not a single wakeup! The system is sleeping fine until it is waked up by a keystroke or mouse-klick.

I can check that with "pmset -g log". In this log-file I can the entry when the system was going to sleep and the next entry is reporting the time and cause when the system was waked up. So over the weekend, there absolutely is nothing going on the machine for 2 days.
 
  • Like
Reactions: Salazes123
In the meantime I found a solution to get rid of the power events. By "I found" I mean actually I found this thread:

Reminders app waking mac from sleep - Apple Community

So I tried it!

Behaviour before the fix:

  • "pmset -g sched" reports our beloved friends
[0] wake at 12/17/2022 00:41:44 by 'com.apple.alarm.user-visible-

com.apple.CalendarNotification.EKTravelEngine.periodicRefreshTimer'.

[1] wake at 12/17/2022 19:23:54 by 'com.apple.alarm.user-visible-com.apple.acm

  • "sudo pmset schedule cancelall"
  • "pmset -g sched" -> all good!
  • put Mac to sleep
  • wake it up by keystroke
  • "pmset -g sched" -> bad again


Now the fix:

"sudo pmset sched cancelall"

AND

"sudo chflags schg /Library/Preferences/SystemConfiguration/com.apple.AutoWake.plist"



"This prevents the system from updating the file and my MacBook no longer wakes to reminder events. Needles to mention that it prevents all scheduled system events like sleep, power-on and such."



"I recommend removing the flag before a system update:"

"sudo chflags noschg /Library/Preferences/SystemConfiguration/com.apple.AutoWake.plist"



Behaviour AFTER the fix:

  • "pmset -g sched" -> all good!
  • put Mac to sleep
  • wakeup Mac by keystroke
  • "pmset -g sched" -> all good and hope it remains as it is...


Will see tomorrow what "pmset -g log" reports...



Good luck to all...
Thanks, I had this problem as well, which may also be driving up my TBW on an 8 GB MBA M1.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.