MacOS – Power Manager not working (Connection Disrupted: Unable to connect to this Mac’s Scheduler at: Service unavailable via Bonjour (dns-sd))

dnshigh sierramacosNetworkpower-management

I had recently installed the most recent version of Power Manager, but after installing the launchdaemon/agent jobs opening the application gives me the error message "Connection Disrupted: Unable to connect to this Mac's Scheduler at: Service unavailable via Bonjour (dns-sd)"enter image description here
I tried various way to fix this problem:

  • Follow the "learn more" instructions, none of them worked;
  • installing various older versions, none of them worked;
  • Reading the logs: nothing interesting:
# log stream --style syslog --info --debug --predicate 'senderImagePath ENDSWITH "pmd"'

Filtering the log data using "senderImagePath ENDSWITH "pmd""
Timestamp                       (process)[PID]    
2021-01-17 16:05:31.083372+0800  localhost uk.co.dssw.powermanager.pmd[1181]: Starting engine
2021-01-17 16:05:31.084062+0800  localhost uk.co.dssw.powermanager.pmd[1181]: Assertion tripped [60] 2   uk.co.dssw.powermanager.pmd         0x000000010015eada uk.co.dssw.powermanager.pmd + 15066
2021-01-17 16:05:31.085011+0800  localhost uk.co.dssw.powermanager.pmd[1181]: Dequeued 0 associated triggers
2021-01-17 16:05:31.085267+0800  localhost uk.co.dssw.powermanager.pmd[1181]: Trigger 2b2c21cc94f06ac079c89290949a5fb3-00-30f1f6ca32b52e28aa0c284c441e9867 fired
2021-01-17 16:05:31.085367+0800  localhost uk.co.dssw.powermanager.pmd[1181]: Event DE5C8F94-631E-495F-8A27-211EE3A820DB's trigger 2b2c21cc94f06ac079c89290949a5fb3-00-30f1f6ca32b52e28aa0c284c441e9867 enqueued
2021-01-17 16:05:31.085470+0800  localhost uk.co.dssw.powermanager.pmd[1181]: Dequeued 0 associated triggers
2021-01-17 16:05:31.085761+0800  localhost uk.co.dssw.powermanager.pmd[1181]: Trigger 161fb7287e2eabcfc7a44b866a4fc4d8-00-f298156b6fd41228a77b86192b98e4e5 fired
2021-01-17 16:05:31.085837+0800  localhost uk.co.dssw.powermanager.pmd[1181]: Event 29ECE534-4135-403B-8762-44A6EA936BDE's trigger 161fb7287e2eabcfc7a44b866a4fc4d8-00-f298156b6fd41228a77b86192b98e4e5 enqueued
2021-01-17 16:05:31.086039+0800  localhost uk.co.dssw.powermanager.pmd[1181]: Dequeued 0 associated triggers
2021-01-17 16:05:31.086180+0800  localhost uk.co.dssw.powermanager.pmd[1181]: Trigger 618242d5b70eda65e90390f8c54a34cc-00-30f1f6ca32b52e28aa0c284c441e9867 fired
2021-01-17 16:05:31.086244+0800  localhost uk.co.dssw.powermanager.pmd[1181]: Event 04A6BA3C-6F81-4FA0-91AD-201FD5DF719C's trigger 618242d5b70eda65e90390f8c54a34cc-00-30f1f6ca32b52e28aa0c284c441e9867 enqueued
2021-01-17 16:05:31.086293+0800  localhost uk.co.dssw.powermanager.pmd[1181]: Dequeued 0 associated triggers
2021-01-17 16:05:31.086396+0800  localhost uk.co.dssw.powermanager.pmd[1181]: Trigger c896189e421da0e3d6518c1dd88ebbd1-00-f298156b6fd41228a77b86192b98e4e5 fired
2021-01-17 16:05:31.086440+0800  localhost uk.co.dssw.powermanager.pmd[1181]: Event 784F7AD3-5871-4904-BE8E-52701E3AAAA0's trigger c896189e421da0e3d6518c1dd88ebbd1-00-f298156b6fd41228a77b86192b98e4e5 enqueued
2021-01-17 16:05:31.293819+0800  localhost uk.co.dssw.powermanager.pmd[1181]: Assertion tripped [377] 2   uk.co.dssw.powermanager.pmd         0x00000001001676d0 uk.co.dssw.powermanager.pmd + 50896
2021-01-17 16:05:31.305077+0800  localhost uk.co.dssw.powermanager.pmd[1181]: Assertion tripped [377] 2   uk.co.dssw.powermanager.pmd         0x00000001001676d0 uk.co.dssw.powermanager.pmd + 50896
2021-01-17 16:05:31.319013+0800  localhost uk.co.dssw.powermanager.pmd[1181]: Assertion tripped [377] 2   uk.co.dssw.powermanager.pmd         0x00000001001676d0 uk.co.dssw.powermanager.pmd + 50896
2021-01-17 16:05:31.340668+0800  localhost uk.co.dssw.powermanager.pmd[1181]: Assertion tripped [377] 2   uk.co.dssw.powermanager.pmd         0x00000001001676d0 uk.co.dssw.powermanager.pmd + 50896
2021-01-17 16:05:31.360198+0800  localhost uk.co.dssw.powermanager.pmd[1181]: Assertion tripped [377] 2   uk.co.dssw.powermanager.pmd         0x00000001001676d0 uk.co.dssw.powermanager.pmd + 50896
2021-01-17 16:05:31.367058+0800  localhost uk.co.dssw.powermanager.pmd[1181]: Assertion tripped [377] 2   uk.co.dssw.powermanager.pmd         0x00000001001676d0 uk.co.dssw.powermanager.pmd + 50896
2021-01-17 16:05:31.367187+0800  localhost uk.co.dssw.powermanager.pmd[1181]: Starting engine
2021-01-17 16:05:31.367951+0800  localhost uk.co.dssw.powermanager.pmd[1181]: Assertion tripped [736] 2   uk.co.dssw.powermanager.pmd         0x0000000100191269 uk.co.dssw.powermanager.pmd + 221801
2021-01-17 16:05:31.368356+0800  localhost uk.co.dssw.powermanager.pmd[1181]: Assertion tripped [715] 2   uk.co.dssw.powermanager.pmd         0x00000001001925fe uk.co.dssw.powermanager.pmd + 226814
2021-01-17 16:07:17.658311+0800  localhost uk.co.dssw.powermanager.pmd[1181]: Stopping after signal "kSignalControllerNotificationDidSignalTERM"
2021-01-17 16:07:17.658448+0800  localhost uk.co.dssw.powermanager.pmd[1181]: Stopping engine
2021-01-17 16:07:17.665745+0800  localhost uk.co.dssw.powermanager.pmd[1181]: Assertion tripped [377] 2   uk.co.dssw.powermanager.pmd         0x00000001001676d0 uk.co.dssw.powermanager.pmd + 50896
2021-01-17 16:07:17.669941+0800  localhost uk.co.dssw.powermanager.pmd[1181]: Assertion tripped [377] 2   uk.co.dssw.powermanager.pmd         0x00000001001676d0 uk.co.dssw.powermanager.pmd + 50896
2021-01-17 16:07:17.677982+0800  localhost uk.co.dssw.powermanager.pmd[1181]: Assertion tripped [377] 2   uk.co.dssw.powermanager.pmd         0x00000001001676d0 uk.co.dssw.powermanager.pmd + 50896
2021-01-17 16:07:17.686746+0800  localhost uk.co.dssw.powermanager.pmd[1181]: Assertion tripped [377] 2   uk.co.dssw.powermanager.pmd         0x00000001001676d0 uk.co.dssw.powermanager.pmd + 50896
2021-01-17 16:07:17.691554+0800  localhost uk.co.dssw.powermanager.pmd[1181]: Assertion tripped [377] 2   uk.co.dssw.powermanager.pmd         0x00000001001676d0 uk.co.dssw.powermanager.pmd + 50896
2021-01-17 16:07:17.698198+0800  localhost uk.co.dssw.powermanager.pmd[1181]: Assertion tripped [377] 2   uk.co.dssw.powermanager.pmd         0x00000001001676d0 uk.co.dssw.powermanager.pmd + 50896
2021-01-17 16:07:56.197333+0800  localhost uk.co.dssw.powermanager.pmd[1276]: Starting engine
2021-01-17 16:07:56.197903+0800  localhost uk.co.dssw.powermanager.pmd[1276]: Assertion tripped [60] 2   uk.co.dssw.powermanager.pmd         0x000000010d5faada uk.co.dssw.powermanager.pmd + 15066
2021-01-17 16:07:56.198552+0800  localhost uk.co.dssw.powermanager.pmd[1276]: Dequeued 0 associated triggers
2021-01-17 16:07:56.198755+0800  localhost uk.co.dssw.powermanager.pmd[1276]: Trigger 2b2c21cc94f06ac079c89290949a5fb3-00-30f1f6ca32b52e28aa0c284c441e9867 fired
2021-01-17 16:07:56.198804+0800  localhost uk.co.dssw.powermanager.pmd[1276]: Event DE5C8F94-631E-495F-8A27-211EE3A820DB's trigger 2b2c21cc94f06ac079c89290949a5fb3-00-30f1f6ca32b52e28aa0c284c441e9867 enqueued
2021-01-17 16:07:56.198854+0800  localhost uk.co.dssw.powermanager.pmd[1276]: Dequeued 0 associated triggers
2021-01-17 16:07:56.199198+0800  localhost uk.co.dssw.powermanager.pmd[1276]: Trigger 618242d5b70eda65e90390f8c54a34cc-00-30f1f6ca32b52e28aa0c284c441e9867 fired
2021-01-17 16:07:56.199318+0800  localhost uk.co.dssw.powermanager.pmd[1276]: Event 04A6BA3C-6F81-4FA0-91AD-201FD5DF719C's trigger 618242d5b70eda65e90390f8c54a34cc-00-30f1f6ca32b52e28aa0c284c441e9867 enqueued
2021-01-17 16:07:56.199475+0800  localhost uk.co.dssw.powermanager.pmd[1276]: Dequeued 0 associated triggers
2021-01-17 16:07:56.199690+0800  localhost uk.co.dssw.powermanager.pmd[1276]: Trigger 161fb7287e2eabcfc7a44b866a4fc4d8-00-f298156b6fd41228a77b86192b98e4e5 fired
2021-01-17 16:07:56.199760+0800  localhost uk.co.dssw.powermanager.pmd[1276]: Event 29ECE534-4135-403B-8762-44A6EA936BDE's trigger 161fb7287e2eabcfc7a44b866a4fc4d8-00-f298156b6fd41228a77b86192b98e4e5 enqueued
2021-01-17 16:07:56.199817+0800  localhost uk.co.dssw.powermanager.pmd[1276]: Dequeued 0 associated triggers
2021-01-17 16:07:56.200096+0800  localhost uk.co.dssw.powermanager.pmd[1276]: Trigger c896189e421da0e3d6518c1dd88ebbd1-00-f298156b6fd41228a77b86192b98e4e5 fired
2021-01-17 16:07:56.200149+0800  localhost uk.co.dssw.powermanager.pmd[1276]: Event 784F7AD3-5871-4904-BE8E-52701E3AAAA0's trigger c896189e421da0e3d6518c1dd88ebbd1-00-f298156b6fd41228a77b86192b98e4e5 enqueued
2021-01-17 16:07:56.578808+0800  localhost uk.co.dssw.powermanager.pmd[1276]: Assertion tripped [377] 2   uk.co.dssw.powermanager.pmd         0x000000010d6036d0 uk.co.dssw.powermanager.pmd + 50896
2021-01-17 16:07:56.585252+0800  localhost uk.co.dssw.powermanager.pmd[1276]: Assertion tripped [377] 2   uk.co.dssw.powermanager.pmd         0x000000010d6036d0 uk.co.dssw.powermanager.pmd + 50896
2021-01-17 16:07:56.594312+0800  localhost uk.co.dssw.powermanager.pmd[1276]: Assertion tripped [377] 2   uk.co.dssw.powermanager.pmd         0x000000010d6036d0 uk.co.dssw.powermanager.pmd + 50896
2021-01-17 16:07:56.606385+0800  localhost uk.co.dssw.powermanager.pmd[1276]: Assertion tripped [377] 2   uk.co.dssw.powermanager.pmd         0x000000010d6036d0 uk.co.dssw.powermanager.pmd + 50896
2021-01-17 16:07:56.614845+0800  localhost uk.co.dssw.powermanager.pmd[1276]: Assertion tripped [377] 2   uk.co.dssw.powermanager.pmd         0x000000010d6036d0 uk.co.dssw.powermanager.pmd + 50896
2021-01-17 16:07:56.624424+0800  localhost uk.co.dssw.powermanager.pmd[1276]: Assertion tripped [377] 2   uk.co.dssw.powermanager.pmd         0x000000010d6036d0 uk.co.dssw.powermanager.pmd + 50896
2021-01-17 16:07:56.624471+0800  localhost uk.co.dssw.powermanager.pmd[1276]: Starting engine
2021-01-17 16:07:56.625281+0800  localhost uk.co.dssw.powermanager.pmd[1276]: Assertion tripped [736] 2   uk.co.dssw.powermanager.pmd         0x000000010d62d269 uk.co.dssw.powermanager.pmd + 221801
2021-01-17 16:07:56.625651+0800  localhost uk.co.dssw.powermanager.pmd[1276]: Assertion tripped [715] 2   uk.co.dssw.powermanager.pmd         0x000000010d62e5fe uk.co.dssw.powermanager.pmd + 226814
# sudo launchctl list | grep uk\.co\.dssw\.powermanager
-   0   uk.co.dssw.powermanager.installer
118 0   uk.co.dssw.powermanager.pmd
# lsof -i | grep uk\.co
[0|1]#
# dns-sd -B _pm._tcp.
Browsing for _pm._tcp.
DATE: ---Sun 21 Mar 2021---
19:40:41.477  ...STARTING...
// stuck here indefinitely

What else might have caused this behavior? How can I troubleshoot this?

Potentially relevant actions: I replaced /var/db/dslocal from an earlier backup due to slow login, and the issue disappears. However, I think data inconsistency might still be present but hidden because I only restored some but not all of the system preferences/data. I don't have time (yet) to do a clean reinstall.

Update:

# kextstat | grep -v 'com.apple.'

Index Refs Address            Size       Wired      Name (Version) UUID <Linked Against>
  142    0 0xffffff7f80b4d000 0x5000     0x5000     com.Cycling74.driver.Soundflower (2) 2D779840-7439-31E5-8A66-D786C3F47B75 <119 5 4 3>
  164    0 0xffffff7f83443000 0x19000    0x19000    com.github.osxfuse.filesystems.osxfuse (3.10.4) 184072A6-C133-38A8-84A5-E8A3BC937ADD <7 5 4 3 1>
# networksetup -listallnetworkservices

An asterisk (*) denotes that a network service is disabled.
Belkin USB-C LAN
USB 10/100/1000 LAN
Wi-Fi
Bluetooth PAN
freevpn.pw
freevpn.pw
Parallels Host-Only #1
# pmctl log.setfilterlevel "level=debug"
No output, exit code 1

# pmctl log.filterlevel
No output, exit code 1
# dns-sd -B
Browsing for _http._tcp
DATE: ---Sun 21 Mar 2021---
20:23:49.416  ...STARTING...
Timestamp     A/R    Flags  if Domain               Service Type         Instance Name
20:23:49.611  Add        2   7 local.               _http._tcp.          jin

Best Answer

Based on the results of the network guide commands:

% sudo launchctl list | grep uk\.co\.dssw\.powermanager
-   0   uk.co.dssw.powermanager.installer
118 0   uk.co.dssw.powermanager.pmd

This shows that the expected launchd jobs are present. ….installer is a one time task used during installation and ….pmd is the background daemon process responsible for performing your schedule.

% lsof -i | grep uk\.co
[0|1]#

This shows that there are no network sockets or ports open by any software including uk.co in the name. This is unexpected.

% dns-sd -B _pm._tcp.
Browsing for _pm._tcp.
DATE: ---Sun 21 Mar 2021---
19:40:41.477  ...STARTING...

This shows that no local services of type _pm._tcp are being advertised on your computer. This means there is no Power Manager service available.

Networking at Fault

The lack of listening network ports and advertised service suggests the network layer is the problem.

Check what third party kernel extensions you are running:

kextstat | grep -v 'com.apple.'

This command will list lines that do not include com.apple from the kextstat command. Do you recognise the extensions shown?

Do you have a working network?

networksetup -listallnetworkservices

Are any Bonjour/ZeroConf services available?

dns-sd -B

Use +. to exit the above command.

Restart pmd

You can force restart the ….pmd process using the command below:

sudo killall uk.co.dssw.powermanager.pmd

This will tear down pmd and launchd will dutifully relaunch the process. On launch pmd will attempt to set up networking and advertise its services.

Try restarting pmd and seeing if this restores the connection. This is not a solution but an experiment.

Default macOS

Potentially relevant actions: I replaced /var/db/dslocal from an earlier backup due to slow login, and the issue disappears. However, I think data inconsistency might still be present but hidden because I only restored some but not all of the system preferences/data. I don't have time (yet) to do a clean reinstall.

Given the above and that Power Manager previously worked, it suggests the replacement of /var/db/dslocal may be the cause of the problem.

The best solution is to install a clean copy of macOS.

Removal and Reinstall

We do not recommend running Power Manager without the supporting agents and applications. Doing so means no warnings, no user interface, and many events will not perform as expected. The agents use the same mechanism as the application to talk to each other; if the application encounters disrupted connections, so will the assisting agents.

You can easily remove Power Manager. If you then want to try again, you can re-install using the packaged edition. This will ensure Power Manager is correctly installed.