Editing Launchctl load

Jump to navigation Jump to search

Warning: You are not logged in. Your IP address will be publicly visible if you make any edits. If you log in or create an account, your edits will be attributed to your username, along with other benefits.

The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then save the changes below to finish undoing the edit.

Latest revision Your text
Line 1: Line 1:
 
{{lc}}
 
{{lc}}
* <code>[[launchctl]] load  [[/System/Library/LaunchDaemons/com.apple.screensharing.plist]]</code>
+
* <code>launchctl load  [[/System/Library/LaunchDaemons/com.apple.screensharing.plist]]</code>
* <code>[[launchctl load -w /System/Library/LaunchDaemons/ssh.plist]]</code>
+
* <code>launchctl load -w /System/Library/LaunchDaemons/ssh.plist</code>
 
 
<pre>
 
launchctl load --help
 
Usage: launchctl load <service-path, service-path2, ...>
 
        -w      If the service is disabled, it will be enabled. In previous
 
                versions of launchd, being disabled meant that a service was
 
                not loaded. Now, services are always loaded. If a service is
 
                disabled, launchd does not advertise its service endpoints
 
                (sockets, Mach ports, etc.).
 
        -F      Forcibly load the service. This flag will ignore the service's
 
                disabled state. In previous versions of launchd, this flag
 
                would also ignore the ownership and permissions of the
 
                specified launchd.plist. This is no longer the case. Note that,
 
                unlike the -w flag, this flag will not  modify the service's
 
                disabled state; it will instead only ignore it for the load
 
                operation.
 
        -S <session>
 
                This flag takes a single argument which is the name of a
 
                session and may only be used when loading agents. All daemons
 
                exist within the same session, which is the system session.
 
                Agents may designate which sessions they can be loaded in with
 
                the LimitLoadToSessionType key.
 
        -D <domain>
 
                Loads launchd.plist(5) files from the specified domain.
 
                Depending on the current execution context, launchctl will look
 
                in a LaunchDaemons or LaunchAgents directory for
 
                launchd.plists. When running in the system's execution context
 
                (i.e. when run as root via a root shell or with sudo), the
 
                LaunchDaemons directory is searched. When running in a user's
 
                context (i.e. run normally from a shell), the LaunchAgents
 
                directory is searched. Valid domains are:
 
                system
 
                Searches /System/Library for either daemons or agents.
 
 
 
                local
 
                Searches /Library for either daemons or agents.
 
 
 
                network
 
                Searches /Network. This session type is no longer valid.
 
 
 
                user
 
                Searches the home directory of the calling user for agents
 
                only. Daemons may not be loaded from this
 
                domain.
 
</pre>
 
  
 
== See also ==
 
== See also ==

Please note that all contributions to wikieduonline may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see Wikieduonline:Copyrights for details). Do not submit copyrighted work without permission!

Cancel Editing help (opens in new window)

Templates used on this page:

Advertising: