]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph-ansible.git/commitdiff
osd: add possibility to exclude device in osd_auto_discovery
authorGuillaume Abrioux <gabrioux@redhat.com>
Mon, 11 Feb 2019 12:52:37 +0000 (13:52 +0100)
committerGuillaume Abrioux <gabrioux@redhat.com>
Mon, 9 Dec 2019 08:32:55 +0000 (09:32 +0100)
Add a new `osd_auto_discovery_exclude` to give the possibility of
excluding some devices in auto_discovery scenario.

Signed-off-by: Guillaume Abrioux <gabrioux@redhat.com>
(cherry picked from commit 83d7ef777ec19eb5f96c553d869ec8ad90fd5061)

group_vars/all.yml.sample
group_vars/rhcs.yml.sample
roles/ceph-defaults/defaults/main.yml
roles/ceph-facts/tasks/facts.yml

index c6338a68f449db96d6cbae8876d8c6ca740a13a3..7aae6828e7934d59d4a04662ce59b88d8ff07978 100644 (file)
@@ -372,6 +372,9 @@ dummy:
 #osd_mount_options_xfs: noatime,largeio,inode64,swalloc
 #osd_objectstore: bluestore
 
+# Any device containing these patterns in their path will be excluded.
+#osd_auto_discovery_exclude: ['dm-', 'loop']
+
 # xattrs. by default, 'filestore xattr use omap' is set to 'true' if
 # 'osd_mkfs_type' is set to 'ext4'; otherwise it isn't set. This can
 # be set to 'true' or 'false' to explicitly override those
index 829f2e01203fb441711439a0aaa94bdc177176db..75474ac299cbdbf5216af01572922053e128db90 100644 (file)
@@ -372,6 +372,9 @@ ceph_rhcs_version: 3
 #osd_mount_options_xfs: noatime,largeio,inode64,swalloc
 #osd_objectstore: bluestore
 
+# Any device containing these patterns in their path will be excluded.
+#osd_auto_discovery_exclude: ['dm-', 'loop']
+
 # xattrs. by default, 'filestore xattr use omap' is set to 'true' if
 # 'osd_mkfs_type' is set to 'ext4'; otherwise it isn't set. This can
 # be set to 'true' or 'false' to explicitly override those
index f0a22e4719e25b959637ecec6e13e8b0f1ee5017..e65cbf266400040a08ef9c8c05025248873d23f0 100644 (file)
@@ -364,6 +364,9 @@ osd_mkfs_options_xfs: -f -i size=2048
 osd_mount_options_xfs: noatime,largeio,inode64,swalloc
 osd_objectstore: bluestore
 
+# Any device containing these patterns in their path will be excluded.
+osd_auto_discovery_exclude: ['dm-', 'loop']
+
 # xattrs. by default, 'filestore xattr use omap' is set to 'true' if
 # 'osd_mkfs_type' is set to 'ext4'; otherwise it isn't set. This can
 # be set to 'true' or 'false' to explicitly override those
index 4798b0a0ef61da971cd23e3efac913b007c14a6a..f723f8d2addcf0912ee2bd482a1d54f2f0db25fd 100644 (file)
     - item.value.sectors != "0"
     - item.value.partitions|count == 0
     - item.value.holders|count == 0
-    - "'dm-' not in item.key"
+    - item.key not in osd_auto_discovery_exclude
 
 - name: set_fact ceph_uid for debian based system - non container
   set_fact: