From: Dimitri Savineau Date: Mon, 9 Sep 2019 15:23:47 +0000 (-0400) Subject: ceph-handler: Fix osd restart condition X-Git-Tag: v4.0.0rc16~5 X-Git-Url: http://git.apps.os.sepia.ceph.com/?a=commitdiff_plain;h=b50fa236304737812e0a15329f2ddd0752e3bf92;p=ceph-ansible.git ceph-handler: Fix osd restart condition In containerized deployment, the restart OSD handler couldn't be triggered in most ansible execution. This is due to the usage of run_once + a condition on the inventory hostname and the last filter. The run_once is triggered first so ansible will pick a node in the osd group to execute the restart task. But if this node isn't the last one in the osd group then the task is ignored. There's more probability that the task will be ignored than executed. Signed-off-by: Dimitri Savineau (cherry picked from commit 5b1c15653fcb4772f0839f3a57f7e36ba1b86f49) --- diff --git a/roles/ceph-handler/handlers/main.yml b/roles/ceph-handler/handlers/main.yml index d4d53a3a2..59e7fc5af 100644 --- a/roles/ceph-handler/handlers/main.yml +++ b/roles/ceph-handler/handlers/main.yml @@ -104,7 +104,6 @@ # except when a crush location is specified. ceph-disk will start the osds before the osd crush location is specified - osd_group_name in group_names - containerized_deployment | bool - - inventory_hostname == groups.get(osd_group_name) | last - ceph_osd_container_stat.get('rc') == 0 - ceph_osd_container_stat.get('stdout_lines', [])|length != 0 - handler_health_osd_check | bool