]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph-ansible.git/commitdiff
osd: make the 'wait for all osd to be up' task configurable v3.2.6
authorGuillaume Abrioux <gabrioux@redhat.com>
Wed, 20 Feb 2019 15:24:25 +0000 (16:24 +0100)
committermergify[bot] <mergify[bot]@users.noreply.github.com>
Wed, 20 Feb 2019 16:53:06 +0000 (16:53 +0000)
introduce two new variables to make the check that 'wait for all osd to
be up' configurable.
It's possible that for some deployments, OSDs can take longer to be seen
as UP and IN.

Closes: https://bugzilla.redhat.com/show_bug.cgi?id=1676763
Signed-off-by: Guillaume Abrioux <gabrioux@redhat.com>
(cherry picked from commit 21e5db8982afd6e075541e7fc88620d59a1df498)

group_vars/osds.yml.sample
roles/ceph-osd/defaults/main.yml
roles/ceph-osd/tasks/openstack_config.yml

index c9bc1b21fadb87b729053bdc084767acbcdd84c4..02e8685839f0a8440d8494562152d5c69b9d6d42 100644 (file)
@@ -271,3 +271,10 @@ dummy:
 #  Service:
 #    PrivateDevices: False
 
+
+###########
+#  CHECK  #
+###########
+
+#nb_retry_wait_osd_up: 60
+#delay_wait_osd_up: 10
index 33c84bff3d20d85ba7bb1544a09092d5042697a8..0292e69e3027cfc195297b136d0f13b18649be7f 100644 (file)
@@ -262,3 +262,11 @@ ceph_osd_docker_run_script_path: "/usr/share" # script called by systemd to run
 #ceph_osd_systemd_overrides:
 #  Service:
 #    PrivateDevices: False
+
+
+###########
+#  CHECK  #
+###########
+
+nb_retry_wait_osd_up: 60
+delay_wait_osd_up: 10
\ No newline at end of file
index 10e4657dc1327e648cab0ebb59124def85002fb6..a72d5ab8f1107ba03a4ff86b5f63178f1547a4f3 100644 (file)
@@ -5,8 +5,9 @@
     test "$({{ hostvars[groups[mon_group_name][0]]['docker_exec_cmd'] | default('') }} ceph --cluster {{ cluster }} -s -f json | python -c 'import sys, json; print(json.load(sys.stdin)["osdmap"]["osdmap"]["num_osds"])')" =
     "$({{ hostvars[groups[mon_group_name][0]]['docker_exec_cmd'] | default('') }} ceph --cluster {{ cluster }} -s -f json | python -c 'import sys, json; print(json.load(sys.stdin)["osdmap"]["osdmap"]["num_up_osds"])')"
   register: wait_for_all_osds_up
-  retries: 30
-  delay: 10
+  retries: "{{ nb_retry_wait_osd_up }}"
+  delay: "{{ delay_wait_osd_up }}"
+  changed_when: false
   delegate_to: "{{ groups[mon_group_name][0] }}"
   until: wait_for_all_osds_up.rc == 0