1

I ran the following command:

launchctl load -w /Library/LaunchAgents/...plist

The plist file has the following values:

<key>KeepAlive</key>
        <true/>
        <key>StandardErrorPath</key>
        <string>/dev/null</string>
        <key>StandardOutPath</key>
        <string>/dev/null</string>
        <key>LimitLoadToSessionType</key>
        <string>Aqua</string>
        <key>ProcessType</key>
        <string>Interactive</string>

When I run:

sudo launchctl bootstrap gui/501 /Library/LaunchAgents/...plist` 

I got

/Applications/...app/Contents/scripts/...plist: Service is disabled

And then I ran:

launchctl load -w /Library/LaunchAgents/...plist 

with the error:

Service cannot load in requested session
0

1 Answer 1

0
iMac-de-Imac:~ imac$ echo $(id -u)
501

iMac-de-Imac:~ imac$ sudo launchctl enable gui/$(idu)/com.piriform.ccleaner
Password:

iMac-de-Imac:~ imac$

iMac-de-Imac:~ imac$ sudo launchctl bootstrap gui/$(id -u) /Library/LaunchAgents/com.piriform.ccleaner.plist

Password:
/Applications/CCleaner.app/Contents/scripts/com.piriform.ccleaner.plist: Service is disabled

iMac-de-Imac:~ imac$

When I try to open the CCleaner program in the System.log, the following appears:

Jan  9 10:51:24 iMac-de-Imac com.apple.xpc.launchd[1
(com.piriform.ccleaner.1944[550]): Service exited with abnormal code: 1

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .