service manual


SERVICE(8)                  System Manager's Manual                 SERVICE(8)


NAME

     service -- manage services


SYNOPSIS

     service [operation] [service | all]


DESCRIPTION

     Most of the options accept either the service name or the special keyword
     "all", which applies the operation to all the related services.

     Operation names can be abbreviated to the shortest distinctive form, eg.
     instead of activated, one can use ad, but not act, as that is the abbre-
     viation for activate.  The parts which can be omitted are given here in
     brackets.

           service a(ctivate) [service | all]
                       activates the service "service".

           service a(ctivate)d [service | all]
                       checks if the service "service" is activated in
                       /bin/svc.d/run.

           service d(eactivate) [service | all]
                       deactivates the service "service".

           service l(ist)
                       lists all available (not necessarily activated) ser-
                       vices in the directory /bin/svc.d/avail.

           service re(start) [service | all]
                       restarts the service.

           service ru(nning) [service | all]
                       checks if the service "service" is running.

           service sta(rt) [service | all]
                       starts the service.

           service sto(p) [service | all]
                       stops the service.


ENVIRONMENT

     STATUSDELAY  Delay between issuing `service start all' and `service
                  running all', in seconds.  Default value is 1.  Adjust as
                  necessary to leave time for services to start before query-
                  ing their status.


FILES

     /bin/svc.d/avail  service scripts which are available for activation.

     /bin/svc.d/default
                       service configuration files.

     /bin/svc.d/run    symlinks to activated service scripts.


STATUS ABBREVIATIONS

     When outputting service status, various four-letter-maximum abbreviations
     will be printed on the right:

           OK      the operation was successful.

           FAIL    the operation has failed.

           YE      the service is running.

           NO      the service isn't running.

           1-ST    the service is "one-shot", so the running operation doesn't
                   apply.

           RNNG    the service is already running.

           NOTR    the service already isn't running.


EXIT STATUS

     svc(8), service and service scripts themselves should set the exit status
     to one of the following:

           0       success.

           1       redundancy; for example, if starting the service was at-
                   tempted when the service is already running.

           2       general error.


SEE ALSO

     svc(8)


HISTORY

     svc(8) and related commands were made by Cristoph Lohmann in 2012.  The
     version used in Galeb is heavily modified and documented by Strahinya
     Radich in 2022.


AUTHORS

     Cristoph Lohmann <20h@r-36.net>, 2012-2014, original author
     Strahinya Radich <contact@strahinja.org>, 2022, reorganized svc(8) and
     created the manpage.

Galeb 2.2                       April 17, 2023                       Galeb 2.2