Jump to content

Wake reason: RTC (Alarm) - how to deactivate?

wake RTC (Alarm) ethernet network access sleep RTC

Best Answer mnfesq, 19 October 2014 - 04:23 PM

My laptop was waking up every two hours like everyone else's here so I used the mdnsresponder files and launch daemons that I downloaded from this thread (post 33), unloaded and then reloaded the mdnsresponder and discoveryd files and it worked well. I got my internet back on and no longer have the laptop waking up on its own. Thanks mcdougal33.

 

However, I was unable to upgrade to Yosemite so I downloaded the full 5 GB installer and installed the final version of 10.10 and, with a few quirks in the installation process, it installed correctly.  But I had no internet.  I couldn't remember where the mdnsresponder files go (usr/sbin) and I couldn't remember the terminal commands for unloading and reloading the mdnsresponder and discoveryd files. (Fortunately, I had done it fairly recently so I could use my up arrow in terminal to find them and rerun them.)  But it occurred to me that there should be instructions with the files to explain how to install them so that someone who needs that information and finds that they can't access the internet can get it.  I took the liberty to put one together and add it to the mdnsresponder files that mcdougal33 uploaded in post 33 of this thread.

 

[attachment=150733:mDNSResponder with Instructions.zip]

 

EDIT - The instructions have been modified to conform to the comments regarding the original instructions below.

Go to the full post


  • Please log in to reply
214 replies to this topic

#1
VirusX

VirusX

    InsanelyMac Sage

  • Donators
  • 466 posts
  • Gender:Male
  • Location:Germany

Hi guys, 

 

my Yosemite works fine on my old rig (specs see signature) and sleep works perfect. My problem is that Yosemite wakes up automatically roughly every 2 hours for a minute and then goes back to sleep. It sounds like the PowerNap feature, but I have not activated that (it doesn't show up in Energy Saver preferences anyway).

Here's my log from last night:

8/5/14 2:24:48.000 AM kernel[0]: Wake reason: RTC (Alarm)
8/5/14 4:13:43.000 AM kernel[0]: Wake reason: RTC (Alarm)
8/5/14 6:02:38.000 AM kernel[0]: Wake reason: RTC (Alarm)
8/5/14 6:02:50.445 AM ntpd[212]: ntpd: wake time set +0.141756 s
8/5/14 7:51:33.000 AM kernel[0]: Wake reason: RTC (Alarm)
8/5/14 7:51:44.938 AM ntpd[212]: ntpd: wake time set +0.196362 s
8/5/14 9:40:28.000 AM kernel[0]: Wake reason: RTC (Alarm)
8/5/14 9:40:39.638 AM ntpd[212]: ntpd: wake time set +0.255238 s
8/5/14 11:29:23.000 AM kernel[0]: Wake reason: RTC (Alarm)
8/5/14 11:29:34.247 AM ntpd[212]: ntpd: wake time set +0.309745 s
8/5/14 11:59:41.000 AM kernel[0]: Wake reason: USB1
8/5/14 11:59:41.000 AM kernel[0]: The USB device WirelessControllerDevice (Port 1 of Hub at 0x3d000000) may have caused a wake by issuing a remote wakeup (2)
8/5/14 11:59:41.000 AM kernel[0]: full wake promotion (reason 1) 338 ms
8/5/14 11:59:41.513 AM WindowServer[170]: CGXDisplayDidWakeNotification [25968432798537]: posting kCGSDisplayDidWake
8/5/14 11:59:48.996 AM discoveryd[49]: Basic DNSResolver UDNSServer:: PowerState is Wakeup
8/5/14 11:59:52.230 AM ntpd[212]: ntpd: wake time set -0.403636 s

The last wake obviously was me waking my computer with my trackpad.

As you can see on the attached screen shot, 'Wake for Ethernet network access' is deactivated and no schedule is set - those settings are not causing the RTC wake up. 

From my google research, those were the common reasons for my problem. I found another article about a similar problem and that guy fixed it with changing some bonjour settings (NoMulticastAdvertisements) but I didn't try that yet because I think the problem is somewhere else.

I am _not_ using any NullCPUPowerManagement.kext. I have only FakeSMC and my network kext in my clover kexts folder.

 

Do you have any clues how I can deactivate those RTC Alarm wakes? Also what is that 'ntpd: wake time set'?

 

Thanks!

-Maxim

 

PS: Sleep works fine in Mavericks without any RTC Alarm wake ups with basically the same clover & system set up.

Attached Files



#2
StephanCA

StephanCA

    InsanelyMac Protégé

  • Members
  • PipPip
  • 54 posts

It looks like the setting is ignored, my computer wakes up every 2 hours too. I'm on Yosemite beta 1, hope next update will fix it.



#3
linzhouyu

linzhouyu

    InsanelyMac Protégé

  • Members
  • Pip
  • 2 posts
  • Gender:Male

Try to turn all sharing off, including the file sharing.



#4
VirusX

VirusX

    InsanelyMac Sage

  • Donators
  • 466 posts
  • Gender:Male
  • Location:Germany

all sharing is turned off, but thanks for the suggestion.

 

I will install DP5 later, maybe that helps. I'll report back



#5
joejoethedogfaceboy

joejoethedogfaceboy

    InsanelyMac Protégé

  • Members
  • Pip
  • 2 posts

Having the same issue here, but I've already updated to DP5 with no change.  Also did the NoMulticastAdvertisements with no change.  :-(

 

Found a post on the Apple forums the other day from someone with a non-Hack having the same issue.  



#6
StephanCA

StephanCA

    InsanelyMac Protégé

  • Members
  • PipPip
  • 54 posts

I think this setting may be controlled by /Library/Preferences/SystemConfiguration/com.apple.PowerManagement.plist

 

I will play with it for a bit to see how it can be disabled.



#7
charliebounce

charliebounce

    InsanelyMac Protégé

  • Donators
  • 44 posts
  • Gender:Male
  • Location:United Kingdom

Try forcing a different darkwake(PowerNap) setting to the kernel like this:

 

<key>Boot</key>

<dict>
<key>Arguments</key>
<string>darkwake=10</string>
etc......
 
You can use "darkwake=0" instead to completely disable PowerNap. I use "darkwake=10" because it allows my system to wake hourly to do backups and check emails, updates etc. without waking the screen or the system fans. 
Your SMBIOS also have an influence on how PowerNap behaves.
 
 
Good Hack!


#8
VirusX

VirusX

    InsanelyMac Sage

  • Donators
  • 466 posts
  • Gender:Male
  • Location:Germany

I installed DP5 last night but it didn't change anything. Even worse, after waking up at night, the system crashed while going back to sleep so I had to get up and manually turn off the computer to get back to sleep... I know, I could just shut down the computer over night but I'm lazy haha.

 

I attached a screenshot of my /Library/Preferences/SystemConfiguration/com.apple.PowerManagement.plist down below but as far as I can see, wake on LAN is set to 0 (=off) which is what we want. I don't know what else to change, because the other settings look fine to me as well.

 

I will have to look into the darkwave stages. I difficult to test because when I change a setting I have to put the system to sleep and not touch it for a couple of hours which is nearly impossible when I'm at home and not asleep ;)

But on the first look, the darkwave options could be the solution. If my system woke up without turning the fans back on, I could deal with it.

My SMBIOS is set by clover automatically so far (iMac late 2009) - I guess this is why the power nap option is not available because my computer is 'too old'?

 

Thanks for your help so far!

Attached Files



#9
StephanCA

StephanCA

    InsanelyMac Protégé

  • Members
  • PipPip
  • 54 posts

darkwake=0 doesn't work for me.



#10
VirusX

VirusX

    InsanelyMac Sage

  • Donators
  • 466 posts
  • Gender:Male
  • Location:Germany

StephanCA, what do you mean by 'doesn't work for me'? Does you system crash / sleep stops working anymore? Or do you mean you still have the problem?

I haven't gotten around to try the dark wave states yet but I will report back asap



#11
StephanCA

StephanCA

    InsanelyMac Protégé

  • Members
  • PipPip
  • 54 posts

VirusX, there is no changes, it still wakes up every 2 hours.



#12
kjp4756

kjp4756

    InsanelyMac Geek

  • Members
  • PipPipPip
  • 149 posts
  • Gender:Male
  • Location:Canada

I was having the exact same problem.  You could try adding -DisableSleepProxyClient to the program arguments in /System/Library/LaunchDaemons/com.apple.mDNSResponder.plist  

 

You may also have to turn on mdnsresponder.  For some reason it's turned off in yosemite beta. 

 

'sudo launchctl load -w /System/Library/LaunchDaemons/com.apple.mDNSResponder.plist"



#13
VirusX

VirusX

    InsanelyMac Sage

  • Donators
  • 466 posts
  • Gender:Male
  • Location:Germany

thank you for your input mcdougal33. I tried what you suggested but it broke my internet. Well, to be precise: my system log is flooded with DNS errors and nothing loads anymore because of timeout errors. I probably added the -DisableSleepProxyClient at the wrong spot?

This is what my mDNSResponder.plist looked like:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
	<key>Label</key>
	<string>com.apple.networking.mDNSResponder</string>
    <key>Disabled</key>
    <true/>
	<key>OnDemand</key>
	<false/>
	<key>InitGroups</key>
	<false/>
	<key>UserName</key>
	<string>_mdnsresponder</string>
	<key>GroupName</key>
	<string>_mdnsresponder</string>
	<key>ProgramArguments</key>
	<array>
		<string>/usr/sbin/mDNSResponder -DisableSleepProxyClient </string>
	</array>
	<key>MachServices</key>
	<dict>
		<key>com.apple.mDNSResponder</key>
		<true/>
               <key>com.apple.mDNSResponder.dnsproxy</key>
               <true/>
	</dict>
	<key>Sockets</key>
	<dict>
		<key>Listeners</key>
		<dict>
			<key>SockFamily</key>
			<string>Unix</string>
			<key>SockPathName</key>
			<string>/var/run/mDNSResponder</string>
			<key>SockPathMode</key>
			<integer>438</integer>
		</dict>
	</dict>
	<key>EnableTransactions</key>
	<true/>
	<key>BeginTransactionAtShutdown</key>
	<true/>
	<key>POSIXSpawnType</key>
	<string>Interactive</string>
</dict>
</plist>

I also added that -DisableSleepProxyClient argument as new string at the program arguments. Same problem. I guess you have to tell me exactly what to do...  :rolleyes:

 

Also, is there a way to find out if that mdnsresponder service launched correctly?

 

Thanks for your help.

 

 



#14
kjp4756

kjp4756

    InsanelyMac Geek

  • Members
  • PipPipPip
  • 149 posts
  • Gender:Male
  • Location:Canada

thank you for your input mcdougal33. I tried what you suggested but it broke my internet. Well, to be precise: my system log is flooded with DNS errors and nothing loads anymore because of timeout errors. I probably added the -DisableSleepProxyClient at the wrong spot?
This is what my mDNSResponder.plist looked like:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
	<key>Label</key>
	<string>com.apple.networking.mDNSResponder</string>
    <key>Disabled</key>
    <true/>
	<key>OnDemand</key>
	<false/>
	<key>InitGroups</key>
	<false/>
	<key>UserName</key>
	<string>_mdnsresponder</string>
	<key>GroupName</key>
	<string>_mdnsresponder</string>
	<key>ProgramArguments</key>
	<array>
		<string>/usr/sbin/mDNSResponder -DisableSleepProxyClient </string>
	</array>
	<key>MachServices</key>
	<dict>
		<key>com.apple.mDNSResponder</key>
		<true/>
               <key>com.apple.mDNSResponder.dnsproxy</key>
               <true/>
	</dict>
	<key>Sockets</key>
	<dict>
		<key>Listeners</key>
		<dict>
			<key>SockFamily</key>
			<string>Unix</string>
			<key>SockPathName</key>
			<string>/var/run/mDNSResponder</string>
			<key>SockPathMode</key>
			<integer>438</integer>
		</dict>
	</dict>
	<key>EnableTransactions</key>
	<true/>
	<key>BeginTransactionAtShutdown</key>
	<true/>
	<key>POSIXSpawnType</key>
	<string>Interactive</string>
</dict>
</plist>
I also added that -DisableSleepProxyClient argument as new string at the program arguments. Same problem. I guess you have to tell me exactly what to do...  :rolleyes:
 
Also, is there a way to find out if that mdnsresponder service launched correctly?
 
Thanks for your help.

 

 
Well it turns out I'm still having the same problem.  Computer wakes every 2 hours.  I ended up having to disable mdnsresponder due to an error I get when waking from sleep; "local host name already in use....".
 
On 10.9 I use darkwake=8 in conjunction with the mdnsresponder plist changes and sleep works perfectly there.  Without the plist changes the computer would wake up every 2 hours to announce itself to the sleep proxy server.
 
Currently on 10.10 I don't use any darkwake kernel parameters but I still have the plist change done.  If I use darkwake=8 on 10.10 the computer will wake up at its first 2 hour wake up and stay awake.
 
Anyway, here is my com.apple.mdnsresponder.plist.  You did put the -DisableSleepProxyClient in the wrong spot.

 

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>BeginTransactionAtShutdown</key>
<true/>
<key>Disabled</key>
<true/>
<key>EnableTransactions</key>
<true/>
<key>GroupName</key>
<string>_mdnsresponder</string>
<key>InitGroups</key>
<false/>
<key>Label</key>
<string>com.apple.networking.mDNSResponder</string>
<key>MachServices</key>
<dict>
<key>com.apple.mDNSResponder</key>
<true/>
<key>com.apple.mDNSResponder.dnsproxy</key>
<true/>
</dict>
<key>OnDemand</key>
<false/>
<key>POSIXSpawnType</key>
<string>Interactive</string>
<key>ProgramArguments</key>
<array>
<string>/usr/sbin/mDNSResponder</string>
<string>-DisableSleepProxyClient</string>
</array>
<key>Sockets</key>
<dict>
<key>Listeners</key>
<dict>
<key>SockFamily</key>
<string>Unix</string>
<key>SockPathMode</key>
<integer>438</integer>
<key>SockPathName</key>
<string>/var/run/mDNSResponder</string>
</dict>
</dict>
<key>UserName</key>
<string>_mdnsresponder</string>
</dict>
</plist>

 

Sorry for the bad formatting.  I can't figure out how to keep things indented properly when pasting.



#15
VirusX

VirusX

    InsanelyMac Sage

  • Donators
  • 466 posts
  • Gender:Male
  • Location:Germany

RAWR - that forum is so slow and has connection errors and just deleted my nice long answer. So here's the short version:

 

Your suggestion didn't work for me:

8/27/14 2:38:04.000 PM kernel[0]: Wake reason: RTC (Alarm)
8/27/14 4:26:59.000 PM kernel[0]: Wake reason: RTC (Alarm)
8/27/14 4:27:11.698 PM ntpd[213]: wake time set +0.495133 s
8/27/14 4:46:18.000 PM kernel[0]: Wake reason: USB1

- how can I check if mDNSRepsonder service is working? I have started it once with your command but I don't know if I have to do that after every boot?

 

I guess we have to wait for the final Yosemite version and hope for a fix... :/



#16
kjp4756

kjp4756

    InsanelyMac Geek

  • Members
  • PipPipPip
  • 149 posts
  • Gender:Male
  • Location:Canada

RAWR - that forum is so slow and has connection errors and just deleted my nice long answer. So here's the short version:

 

Your suggestion didn't work for me:

8/27/14 2:38:04.000 PM kernel[0]: Wake reason: RTC (Alarm)
8/27/14 4:26:59.000 PM kernel[0]: Wake reason: RTC (Alarm)
8/27/14 4:27:11.698 PM ntpd[213]: wake time set +0.495133 s
8/27/14 4:46:18.000 PM kernel[0]: Wake reason: USB1

- how can I check if mDNSRepsonder service is working? I have started it once with your command but I don't know if I have to do that after every boot?

 

I guess we have to wait for the final Yosemite version and hope for a fix... :/

Yeah it's not working for me either like I thought it was.  Mine still wakes every 2 hours. I can live with it for now though.  At least it wakes up and then goes back to sleep on its own.

 

You can check and see if mdnsresponder is running by doing a 'ps -ax | grep -i mdns' in terminal (without quotes).  You should see this:

 

1444   ??  Ss     0:00.03 /usr/sbin/mDNSResponder -DisableSleepProxyClient


#17
kjp4756

kjp4756

    InsanelyMac Geek

  • Members
  • PipPipPip
  • 149 posts
  • Gender:Male
  • Location:Canada

One other thing; when you enable mdnsresponder using the launchctl command I posted earlier, you'll need to reboot.  As you've discovered you'll lose internet access.  Once you reboot internet will work again.



#18
aphex6b

aphex6b

    InsanelyMac Geek

  • Members
  • PipPipPip
  • 123 posts
  • Gender:Male

There is a new kind of mDNS daemon in Yosemite located in /usr/libexec called discoveryd what seems to use UDP sockets and what i think replaces mDNSResponder.



#19
iFIRE

iFIRE

    InsanelyMacaholic

  • Banned
  • PipPipPipPipPipPipPipPipPipPipPip
  • 3,807 posts
  • Gender:Male
  • Location:Bcn-Spain

 the solution is to disable “Wake on Network Access” in the Energy Saving options  :P 



#20
kjp4756

kjp4756

    InsanelyMac Geek

  • Members
  • PipPipPip
  • 149 posts
  • Gender:Male
  • Location:Canada

 the solution is to disable “Wake on Network Access” in the Energy Saving options  :P 

Not for me it isn't.  I use wake on lan to remotely wake my computer when I am not home.







Also tagged with one or more of these keywords: wake, RTC (Alarm), ethernet network access, sleep, RTC


0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users

© 2017 InsanelyMac  |   News  |   Forum  |   Downloads  |   OSx86 Wiki  |   Designed by Ed Gain  |   Logo by irfan  |   Privacy Policy