/usr/lib/python2.6/site-packages/salt/states/service.py

这个模块用于启动或重启服务和后台进程

starting or restarting of services and daemons
==============================================

Services are defined as system daemons typically started with system init or
rc scripts, services can be defined as running or dead.

.. code-block:: yaml

    httpd:
      service:
        - running

The service can also be set to be started at runtime via the enable option:

.. code-block:: yaml

    open***:
      service:
        - running
        - enable: True

By default if a service is triggered to refresh due to a watch statement the
service is by default restarted. If the desired behavior is to reload the
service, then set the reload value to True:

.. code-block:: yaml

    redis:
      service:
        - running
        - enable: True
        - reload: True
        - watch:
          - pkg: redis

.. note::

    More details regarding ``watch`` can be found in the
    :doc:`Requisites </ref/states/requisites>` documentation.

'''


主要使用到两个状态running和dead