root is special, because it is used to control the
Shepherd itself. It has an alias
shepherd. It provides the
following actions (in addition to
restart which do not make sense here).
Displays which services are started and which ones are not.
Displays detailed information about every registered service.
Evaluate in the
shepherd process the Scheme code in
file, in a fresh module that uses the
module—as with the
--config option of
Likewise, evaluate Scheme expression exp in a fresh module with all the necessary bindings. Here is a couple of examples:
# herd eval root "(+ 2 2)" 4 # herd eval root "(getpid)" 1 # herd eval root "(lookup-running 'xorg-server)" (service (version 0) (provides (xorg-server)) …)
Attempt to remove the service identified by service-name.
shepherd will first stop the service, if necessary, and then
remove it from the list of registered services. Any services
depending upon service-name will be stopped as part of this
If service-name simply does not exist, output a warning and do
nothing. If it exists, but is provided by several services, output a
warning and do nothing. This latter case might occur for instance with
the fictional service
web-server, which might be provided by both
nginx. If service-name is the special
all, attempt to remove all services except for the Shepherd
Unload all known optional services using unload’s
then load file-name using
load functionality. If
file-name does not exist or
load encounters an error, you may
end up with no defined services. As these can be reloaded at a later
stage this is not considered a problem. If the
reload will not attempt to load file-name.
Fork and go into the background. This should be called before
respawnable services are started, as otherwise we would not get the
SIGCHLD signals when they terminate.