nova/doc/source/admin/services.rst
Dmitry Tantsur be221ecb0f Correct examples in "Manage Compute services" documentation
* "compute service set" command requires a host, not a zone
* the --disable-reason flag's argument has to be quoted

Change-Id: Iaf58d702b1619a66f97553cf2e47eb8c85166bf6
2017-09-04 15:49:33 +02:00

3.8 KiB

Manage Compute services

You can enable and disable Compute services. The following examples disable and enable the nova-compute service.

  1. List the Compute services:

    $ openstack compute service list
    +----+--------------+------------+----------+---------+-------+--------------+
    | ID | Binary       | Host       | Zone     | Status  | State | Updated At   |
    +----+--------------+------------+----------+---------+-------+--------------+
    |  4 | nova-        | controller | internal | enabled | up    | 2016-12-20T0 |
    |    | consoleauth  |            |          |         |       | 0:44:48.0000 |
    |    |              |            |          |         |       | 00           |
    |  5 | nova-        | controller | internal | enabled | up    | 2016-12-20T0 |
    |    | scheduler    |            |          |         |       | 0:44:48.0000 |
    |    |              |            |          |         |       | 00           |
    |  6 | nova-        | controller | internal | enabled | up    | 2016-12-20T0 |
    |    | conductor    |            |          |         |       | 0:44:54.0000 |
    |    |              |            |          |         |       | 00           |
    |  9 | nova-compute | compute    | nova     | enabled | up    | 2016-10-21T0 |
    |    |              |            |          |         |       | 2:35:03.0000 |
    |    |              |            |          |         |       | 00           |
    +----+--------------+------------+----------+---------+-------+--------------+
  2. Disable a nova service:

    $ openstack compute service set --disable --disable-reason "trial log" compute nova-compute
    +----------+--------------+----------+-------------------+
    | Host     | Binary       | Status   | Disabled Reason   |
    +----------+--------------+----------+-------------------+
    | compute  | nova-compute | disabled | trial log         |
    +----------+--------------+----------+-------------------+
  3. Check the service list:

    $ openstack compute service list
    +----+--------------+------------+----------+---------+-------+--------------+
    | ID | Binary       | Host       | Zone     | Status  | State | Updated At   |
    +----+--------------+------------+----------+---------+-------+--------------+
    |  4 | nova-        | controller | internal | enabled | up    | 2016-12-20T0 |
    |    | consoleauth  |            |          |         |       | 0:44:48.0000 |
    |    |              |            |          |         |       | 00           |
    |  5 | nova-        | controller | internal | enabled | up    | 2016-12-20T0 |
    |    | scheduler    |            |          |         |       | 0:44:48.0000 |
    |    |              |            |          |         |       | 00           |
    |  6 | nova-        | controller | internal | enabled | up    | 2016-12-20T0 |
    |    | conductor    |            |          |         |       | 0:44:54.0000 |
    |    |              |            |          |         |       | 00           |
    |  9 | nova-compute | compute    | nova     | disabled| up    | 2016-10-21T0 |
    |    |              |            |          |         |       | 2:35:03.0000 |
    |    |              |            |          |         |       | 00           |
    +----+--------------+------------+----------+---------+-------+--------------+
  4. Enable the service:

    $ openstack compute service set --enable compute nova-compute
    +----------+--------------+---------+
    | Host     | Binary       | Status  |
    +----------+--------------+---------+
    | compute  | nova-compute | enabled |
    +----------+--------------+---------+