]> git.apps.os.sepia.ceph.com Git - ceph-ansible.git/commitdiff
rolling_update: move osd flag section
authorSébastien Han <seb@redhat.com>
Wed, 16 May 2018 14:02:41 +0000 (16:02 +0200)
committerSébastien Han <seb@redhat.com>
Thu, 17 May 2018 09:54:15 +0000 (11:54 +0200)
During a minor update from a jewel to a higher jewel version (10.2.9 to
10.2.10 for example) osd flags don't get applied because they were done
in the mgr section which is skipped in jewel since this daemons does not
exist.
Moving the set flag section after all the mons have been updated solves
that problem.

Closes: https://bugzilla.redhat.com/show_bug.cgi?id=1548071
Co-authored-by: Tomas Petr <tpetr@redhat.com>
Signed-off-by: Sébastien Han <seb@redhat.com>
(cherry picked from commit d80a871a078a175d0775e91df00baf625dc39725)

infrastructure-playbooks/rolling_update.yml

index 9216184cd5c1d9e7b641ff8ea9760b1c8de4fe94..5dbd3eea6d63538af7f2dc25214c00607e4b20f3 100644 (file)
       when:
         - containerized_deployment
 
+    - name: set osd flags
+      command: ceph --cluster {{ cluster }} osd set {{ item }}
+      with_items:
+        - noout
+        - noscrub
+        - nodeep-scrub
+      delegate_to: "{{ mon_host }}"
+      when: not containerized_deployment
+
+    - name: set containerized osd flags
+      command: |
+        docker exec ceph-mon-{{ hostvars[mon_host]['ansible_hostname'] }} ceph --cluster {{ cluster }} osd set {{ item }}
+      with_items:
+        - noout
+        - noscrub
+        - nodeep-scrub
+      delegate_to: "{{ mon_host }}"
+      when: containerized_deployment
+
 
 - name: upgrade ceph mgr node
 
       when:
         - containerized_deployment
 
-    - name: set osd flags
-      command: ceph --cluster {{ cluster }} osd set {{ item }}
-      with_items:
-        - noout
-        - noscrub
-        - nodeep-scrub
-      delegate_to: "{{ groups[mon_group_name][0] }}"
-      when: not containerized_deployment
-
-    - name: set containerized osd flags
-      command: |
-        docker exec ceph-mon-{{ hostvars[groups[mon_group_name][0]]['ansible_hostname'] }} ceph --cluster {{ cluster }} osd set {{ item }}
-      with_items:
-        - noout
-        - noscrub
-        - nodeep-scrub
-      delegate_to: "{{ groups[mon_group_name][0] }}"
-      when: containerized_deployment
-
 
 - name: upgrade ceph osds cluster