使用cinder service-list可以查到cinder的服务状态和信息,有时会有一些不用的状态是down,以前是通过修改数据库删除这些down掉的服务。
社区中增加了命令:cinder-manage service remove <binary> <host>可以删除那些down掉的服务。
示例:
# cinder service-list
+------------------+-------------------+------+---------+-------+----------------------------+-----------------+
| Binary | Host | Zone | Status | State | Updated_at | Disabled Reason |
+------------------+-------------------+------+---------+-------+----------------------------+-----------------+
| cinder-scheduler | 2c510cg | nova | enabled | down | 2017-05-18T05:48:49.000000 | - |
| cinder-scheduler | cinder | nova | enabled | up | 2017-05-18T08:20:13.000000 | - |
| cinder-volume | [email protected]_FCSAN | nova | enabled | down | 2017-05-12T07:39:40.000000 | - |
| cinder-volume | [email protected] | nova | enabled | down | 2017-05-08T00:57:57.000000 | - |
| cinder-volume | [email protected]_FCSAN | nova | enabled | down | 2017-05-18T05:48:42.000000 | - |
| cinder-volume | [email protected] | nova | enabled | up | 2017-05-18T08:20:06.000000 | - |
+------------------+-------------------+------+---------+-------+----------------------------+-----------------+
# cinder-manage service remove cinder-volume [email protected]_FCSAN
# cinder-manage service remove cinder-volume [email protected]
# cinder service-list
+------------------+------------------+------+---------+-------+----------------------------+-----------------+
| Binary | Host | Zone | Status | State | Updated_at | Disabled Reason |
+------------------+------------------+------+---------+-------+----------------------------+-----------------+
| cinder-scheduler | 2c510cg | nova | enabled | down | 2017-05-18T05:48:49.000000 | - |
| cinder-scheduler | cinder | nova | enabled | up | 2017-05-18T08:20:53.000000 | - |
| cinder-volume | [email protected]_FCSAN | nova | enabled | down | 2017-05-18T05:48:42.000000 | - |
| cinder-volume | [email protected] | nova | enabled | up | 2017-05-18T08:20:56.000000 | - |
+------------------+------------------+------+---------+-------+----------------------------+-----------------+