]> git.apps.os.sepia.ceph.com Git - ceph-ansible.git/commitdiff
ceph-osd: simply the regex to check the device
authorSébastien Han <seb@redhat.com>
Thu, 11 Feb 2016 21:51:23 +0000 (22:51 +0100)
committerSébastien Han <seb@redhat.com>
Thu, 11 Feb 2016 21:51:23 +0000 (22:51 +0100)
Signed-off-by: Sébastien Han <seb@redhat.com>
roles/ceph-osd/tasks/check_devices.yml

index d38869606549aef61059d89044a9e946d2290978..7721046d219539bffa317117b0d16822cdd0d100 100644 (file)
@@ -11,7 +11,7 @@
 # for SSD journals.
 
 - name: check if the device is a partition
-  shell: "echo '{{ item }}' | egrep '/dev/(sd[a-z]{1,2}|hd[a-z]{1,2}|cciss/c[0-9]d[0-9]p|nvme[0-9]n[0-9]p)[0-9]{1,2}$'"
+  shell: "echo '{{ item }}' | egrep '/dev/({h,s,v}d[a-z]{1,2}|cciss/c[0-9]d[0-9]p|nvme[0-9]n[0-9]p)[0-9]{1,2}$'"
   with_items: devices
   changed_when: false
   failed_when: false
@@ -19,7 +19,7 @@
   when: not osd_auto_discovery
 
 - name: check if the device is a partition (autodiscover disks)
-  shell: "echo '/dev/{{ item.key }}' | egrep '/dev/(sd[a-z]{1,2}|hd[a-z]{1,2}|cciss/c[0-9]d[0-9]p|nvme[0-9]n[0-9]p)[0-9]{1,2}$'"
+  shell: "echo '/dev/{{ item.key }}' | egrep '/dev/({h,s,v}d[a-z]{1,2}|cciss/c[0-9]d[0-9]p|nvme[0-9]n[0-9]p)[0-9]{1,2}$'"
   with_dict: ansible_devices
   changed_when: false
   failed_when: false