]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
ceph-volume: add explicit mixed-type functional tests
authorJan Fajerski <jfajerski@suse.com>
Wed, 16 Jan 2019 12:48:25 +0000 (13:48 +0100)
committerJan Fajerski <jfajerski@suse.com>
Mon, 28 Jan 2019 16:14:24 +0000 (17:14 +0100)
Signed-off-by: Jan Fajerski <jfajerski@suse.com>
30 files changed:
src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-dmcrypt-explicit/Vagrantfile [new symlink]
src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-dmcrypt-explicit/group_vars/all [new file with mode: 0644]
src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-dmcrypt-explicit/hosts [new file with mode: 0644]
src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-dmcrypt-explicit/setup.yml [new symlink]
src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-dmcrypt-explicit/test.yml [new symlink]
src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-dmcrypt-explicit/test_zap.yml [new symlink]
src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-dmcrypt-explicit/vagrant_variables.yml [new file with mode: 0644]
src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-explicit/Vagrantfile [new symlink]
src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-explicit/group_vars/all [new file with mode: 0644]
src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-explicit/hosts [new file with mode: 0644]
src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-explicit/setup.yml [new symlink]
src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-explicit/test.yml [new symlink]
src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-explicit/test_zap.yml [new symlink]
src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-explicit/vagrant_variables.yml [new file with mode: 0644]
src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-dmcrypt-explicit/Vagrantfile [new symlink]
src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-dmcrypt-explicit/group_vars/all [new file with mode: 0644]
src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-dmcrypt-explicit/hosts [new file with mode: 0644]
src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-dmcrypt-explicit/setup.yml [new symlink]
src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-dmcrypt-explicit/test.yml [new symlink]
src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-dmcrypt-explicit/test_zap.yml [new symlink]
src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-dmcrypt-explicit/vagrant_variables.yml [new file with mode: 0644]
src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-explicit/Vagrantfile [new symlink]
src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-explicit/group_vars/all [new file with mode: 0644]
src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-explicit/hosts [new file with mode: 0644]
src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-explicit/setup.yml [new symlink]
src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-explicit/test.yml [new symlink]
src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-explicit/test_zap.yml [new symlink]
src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-explicit/vagrant_variables.yml [new file with mode: 0644]
src/ceph-volume/ceph_volume/tests/functional/batch/playbooks/test_explicit.yml [new file with mode: 0644]
src/ceph-volume/ceph_volume/tests/functional/batch/tox.ini

diff --git a/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-dmcrypt-explicit/Vagrantfile b/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-dmcrypt-explicit/Vagrantfile
new file mode 120000 (symlink)
index 0000000..16076e4
--- /dev/null
@@ -0,0 +1 @@
+../../../../Vagrantfile
\ No newline at end of file
diff --git a/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-dmcrypt-explicit/group_vars/all b/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-dmcrypt-explicit/group_vars/all
new file mode 100644 (file)
index 0000000..ae65f9b
--- /dev/null
@@ -0,0 +1,33 @@
+---
+
+ceph_dev: True
+cluster: test
+public_network: "192.168.3.0/24"
+cluster_network: "192.168.4.0/24"
+monitor_interface: eth1
+osd_objectstore: "bluestore"
+osd_scenario: lvm
+dmcrypt: true
+num_osds: 2
+ceph_origin: 'repository'
+ceph_repository: 'dev'
+copy_admin_key: false
+devices:
+  - /dev/sdb
+  - /dev/sdc
+  - /dev/nvme0n1
+  - /dev/nvme1n1
+os_tuning_params:
+  - { name: kernel.pid_max, value: 4194303 }
+  - { name: fs.file-max, value: 26234859 }
+ceph_conf_overrides:
+  global:
+    osd_pool_default_pg_num: 8
+    osd_pool_default_size: 1
+
+# The following is only needed for testing purposes and is not part of
+# ceph-ansible supported variables
+
+osd_ids:
+  - 0
+  - 1
diff --git a/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-dmcrypt-explicit/hosts b/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-dmcrypt-explicit/hosts
new file mode 100644 (file)
index 0000000..e1c1de6
--- /dev/null
@@ -0,0 +1,8 @@
+[mons]
+mon0
+
+[osds]
+osd0
+
+[mgrs]
+mon0
diff --git a/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-dmcrypt-explicit/setup.yml b/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-dmcrypt-explicit/setup.yml
new file mode 120000 (symlink)
index 0000000..8cf11d4
--- /dev/null
@@ -0,0 +1 @@
+../../../playbooks/setup_mixed_type.yml
\ No newline at end of file
diff --git a/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-dmcrypt-explicit/test.yml b/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-dmcrypt-explicit/test.yml
new file mode 120000 (symlink)
index 0000000..66d44c7
--- /dev/null
@@ -0,0 +1 @@
+../../../playbooks/test_explicit.yml
\ No newline at end of file
diff --git a/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-dmcrypt-explicit/test_zap.yml b/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-dmcrypt-explicit/test_zap.yml
new file mode 120000 (symlink)
index 0000000..cb969fa
--- /dev/null
@@ -0,0 +1 @@
+../../../playbooks/test_zap.yml
\ No newline at end of file
diff --git a/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-dmcrypt-explicit/vagrant_variables.yml b/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-dmcrypt-explicit/vagrant_variables.yml
new file mode 100644 (file)
index 0000000..7d1a444
--- /dev/null
@@ -0,0 +1,56 @@
+---
+
+# DEFINE THE NUMBER OF VMS TO RUN
+mon_vms: 1
+osd_vms: 1
+mds_vms: 0
+rgw_vms: 0
+nfs_vms: 0
+rbd_mirror_vms: 0
+client_vms: 0
+iscsi_gw_vms: 0
+mgr_vms: 0
+
+# SUBNETS TO USE FOR THE VMS
+public_subnet: 192.168.3
+cluster_subnet: 192.168.4
+
+# MEMORY
+# set 1024 for CentOS
+memory: 512
+
+# Ethernet interface name
+# use eth1 for libvirt and ubuntu precise, enp0s8 for CentOS and ubuntu xenial
+eth: 'eth1'
+
+
+# VAGRANT BOX
+# Ceph boxes are *strongly* suggested. They are under better control and will
+# not get updated frequently unless required for build systems. These are (for
+# now):
+#
+# * ceph/ubuntu-xenial
+#
+# Ubuntu: ceph/ubuntu-xenial bento/ubuntu-16.04 or ubuntu/trusty64 or ubuntu/wily64
+# CentOS: bento/centos-7.1 or puppetlabs/centos-7.0-64-puppet
+# libvirt CentOS: centos/7
+# parallels Ubuntu: parallels/ubuntu-14.04
+# Debian: deb/jessie-amd64 - be careful the storage controller is named 'SATA Controller'
+# For more boxes have a look at:
+#   - https://atlas.hashicorp.com/boxes/search?utf8=✓&sort=&provider=virtualbox&q=
+#   - https://download.gluster.org/pub/gluster/purpleidea/vagrant/
+vagrant_box: centos/7
+#ssh_private_key_path: "~/.ssh/id_rsa"
+# The sync directory changes based on vagrant box
+# Set to /home/vagrant/sync for Centos/7, /home/{ user }/vagrant for openstack and defaults to /vagrant
+#vagrant_sync_dir: /home/vagrant/sync
+#vagrant_sync_dir: /
+# Disables synced folder creation. Not needed for testing, will skip mounting
+# the vagrant directory on the remote box regardless of the provider.
+vagrant_disable_synced_folder: true
+# VAGRANT URL
+# This is a URL to download an image from an alternate location.  vagrant_box
+# above should be set to the filename of the image.
+# Fedora virtualbox: https://download.fedoraproject.org/pub/fedora/linux/releases/22/Cloud/x86_64/Images/Fedora-Cloud-Base-Vagrant-22-20150521.x86_64.vagrant-virtualbox.box
+# Fedora libvirt: https://download.fedoraproject.org/pub/fedora/linux/releases/22/Cloud/x86_64/Images/Fedora-Cloud-Base-Vagrant-22-20150521.x86_64.vagrant-libvirt.box
+# vagrant_box_url: https://download.fedoraproject.org/pub/fedora/linux/releases/22/Cloud/x86_64/Images/Fedora-Cloud-Base-Vagrant-22-20150521.x86_64.vagrant-virtualbox.box
diff --git a/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-explicit/Vagrantfile b/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-explicit/Vagrantfile
new file mode 120000 (symlink)
index 0000000..16076e4
--- /dev/null
@@ -0,0 +1 @@
+../../../../Vagrantfile
\ No newline at end of file
diff --git a/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-explicit/group_vars/all b/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-explicit/group_vars/all
new file mode 100644 (file)
index 0000000..c2e356f
--- /dev/null
@@ -0,0 +1,34 @@
+---
+
+ceph_dev: True
+cluster: test
+public_network: "192.168.3.0/24"
+cluster_network: "192.168.4.0/24"
+monitor_interface: eth1
+osd_objectstore: "bluestore"
+osd_scenario: lvm
+num_osds: 2
+ceph_origin: 'repository'
+ceph_repository: 'dev'
+copy_admin_key: false
+devices:
+  - /dev/sdb
+  - /dev/sdc
+  - /dev/nvme0n1
+  - /dev/nvme1n1
+os_tuning_params:
+  - { name: kernel.pid_max, value: 4194303 }
+  - { name: fs.file-max, value: 26234859 }
+ceph_conf_overrides:
+  global:
+    osd_pool_default_pg_num: 8
+    osd_pool_default_size: 1
+# 9GB in bytes
+block_db_size: 9663676416
+
+# The following is only needed for testing purposes and is not part of
+# ceph-ansible supported variables
+
+osd_ids:
+  - 0
+  - 1
diff --git a/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-explicit/hosts b/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-explicit/hosts
new file mode 100644 (file)
index 0000000..e1c1de6
--- /dev/null
@@ -0,0 +1,8 @@
+[mons]
+mon0
+
+[osds]
+osd0
+
+[mgrs]
+mon0
diff --git a/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-explicit/setup.yml b/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-explicit/setup.yml
new file mode 120000 (symlink)
index 0000000..8cf11d4
--- /dev/null
@@ -0,0 +1 @@
+../../../playbooks/setup_mixed_type.yml
\ No newline at end of file
diff --git a/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-explicit/test.yml b/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-explicit/test.yml
new file mode 120000 (symlink)
index 0000000..66d44c7
--- /dev/null
@@ -0,0 +1 @@
+../../../playbooks/test_explicit.yml
\ No newline at end of file
diff --git a/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-explicit/test_zap.yml b/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-explicit/test_zap.yml
new file mode 120000 (symlink)
index 0000000..cb969fa
--- /dev/null
@@ -0,0 +1 @@
+../../../playbooks/test_zap.yml
\ No newline at end of file
diff --git a/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-explicit/vagrant_variables.yml b/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/bluestore/mixed-type-explicit/vagrant_variables.yml
new file mode 100644 (file)
index 0000000..7d1a444
--- /dev/null
@@ -0,0 +1,56 @@
+---
+
+# DEFINE THE NUMBER OF VMS TO RUN
+mon_vms: 1
+osd_vms: 1
+mds_vms: 0
+rgw_vms: 0
+nfs_vms: 0
+rbd_mirror_vms: 0
+client_vms: 0
+iscsi_gw_vms: 0
+mgr_vms: 0
+
+# SUBNETS TO USE FOR THE VMS
+public_subnet: 192.168.3
+cluster_subnet: 192.168.4
+
+# MEMORY
+# set 1024 for CentOS
+memory: 512
+
+# Ethernet interface name
+# use eth1 for libvirt and ubuntu precise, enp0s8 for CentOS and ubuntu xenial
+eth: 'eth1'
+
+
+# VAGRANT BOX
+# Ceph boxes are *strongly* suggested. They are under better control and will
+# not get updated frequently unless required for build systems. These are (for
+# now):
+#
+# * ceph/ubuntu-xenial
+#
+# Ubuntu: ceph/ubuntu-xenial bento/ubuntu-16.04 or ubuntu/trusty64 or ubuntu/wily64
+# CentOS: bento/centos-7.1 or puppetlabs/centos-7.0-64-puppet
+# libvirt CentOS: centos/7
+# parallels Ubuntu: parallels/ubuntu-14.04
+# Debian: deb/jessie-amd64 - be careful the storage controller is named 'SATA Controller'
+# For more boxes have a look at:
+#   - https://atlas.hashicorp.com/boxes/search?utf8=✓&sort=&provider=virtualbox&q=
+#   - https://download.gluster.org/pub/gluster/purpleidea/vagrant/
+vagrant_box: centos/7
+#ssh_private_key_path: "~/.ssh/id_rsa"
+# The sync directory changes based on vagrant box
+# Set to /home/vagrant/sync for Centos/7, /home/{ user }/vagrant for openstack and defaults to /vagrant
+#vagrant_sync_dir: /home/vagrant/sync
+#vagrant_sync_dir: /
+# Disables synced folder creation. Not needed for testing, will skip mounting
+# the vagrant directory on the remote box regardless of the provider.
+vagrant_disable_synced_folder: true
+# VAGRANT URL
+# This is a URL to download an image from an alternate location.  vagrant_box
+# above should be set to the filename of the image.
+# Fedora virtualbox: https://download.fedoraproject.org/pub/fedora/linux/releases/22/Cloud/x86_64/Images/Fedora-Cloud-Base-Vagrant-22-20150521.x86_64.vagrant-virtualbox.box
+# Fedora libvirt: https://download.fedoraproject.org/pub/fedora/linux/releases/22/Cloud/x86_64/Images/Fedora-Cloud-Base-Vagrant-22-20150521.x86_64.vagrant-libvirt.box
+# vagrant_box_url: https://download.fedoraproject.org/pub/fedora/linux/releases/22/Cloud/x86_64/Images/Fedora-Cloud-Base-Vagrant-22-20150521.x86_64.vagrant-virtualbox.box
diff --git a/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-dmcrypt-explicit/Vagrantfile b/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-dmcrypt-explicit/Vagrantfile
new file mode 120000 (symlink)
index 0000000..16076e4
--- /dev/null
@@ -0,0 +1 @@
+../../../../Vagrantfile
\ No newline at end of file
diff --git a/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-dmcrypt-explicit/group_vars/all b/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-dmcrypt-explicit/group_vars/all
new file mode 100644 (file)
index 0000000..006e9b8
--- /dev/null
@@ -0,0 +1,33 @@
+---
+
+ceph_dev: True
+cluster: test
+public_network: "192.168.3.0/24"
+cluster_network: "192.168.4.0/24"
+monitor_interface: eth1
+osd_objectstore: "filestore"
+osd_scenario: lvm
+dmcrypt: true
+ceph_origin: 'repository'
+ceph_repository: 'dev'
+copy_admin_key: false
+num_osds: 2
+devices:
+  - /dev/sdb
+  - /dev/sdc
+  - /dev/nvme0n1
+  - /dev/nvme1n1
+os_tuning_params:
+  - { name: kernel.pid_max, value: 4194303 }
+  - { name: fs.file-max, value: 26234859 }
+ceph_conf_overrides:
+  global:
+    osd_pool_default_pg_num: 8
+    osd_pool_default_size: 1
+
+# The following is only needed for testing purposes and is not part of
+# ceph-ansible supported variables
+
+osd_ids:
+  - 0
+  - 1
diff --git a/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-dmcrypt-explicit/hosts b/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-dmcrypt-explicit/hosts
new file mode 100644 (file)
index 0000000..e1c1de6
--- /dev/null
@@ -0,0 +1,8 @@
+[mons]
+mon0
+
+[osds]
+osd0
+
+[mgrs]
+mon0
diff --git a/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-dmcrypt-explicit/setup.yml b/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-dmcrypt-explicit/setup.yml
new file mode 120000 (symlink)
index 0000000..8cf11d4
--- /dev/null
@@ -0,0 +1 @@
+../../../playbooks/setup_mixed_type.yml
\ No newline at end of file
diff --git a/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-dmcrypt-explicit/test.yml b/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-dmcrypt-explicit/test.yml
new file mode 120000 (symlink)
index 0000000..66d44c7
--- /dev/null
@@ -0,0 +1 @@
+../../../playbooks/test_explicit.yml
\ No newline at end of file
diff --git a/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-dmcrypt-explicit/test_zap.yml b/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-dmcrypt-explicit/test_zap.yml
new file mode 120000 (symlink)
index 0000000..cb969fa
--- /dev/null
@@ -0,0 +1 @@
+../../../playbooks/test_zap.yml
\ No newline at end of file
diff --git a/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-dmcrypt-explicit/vagrant_variables.yml b/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-dmcrypt-explicit/vagrant_variables.yml
new file mode 100644 (file)
index 0000000..7d1a444
--- /dev/null
@@ -0,0 +1,56 @@
+---
+
+# DEFINE THE NUMBER OF VMS TO RUN
+mon_vms: 1
+osd_vms: 1
+mds_vms: 0
+rgw_vms: 0
+nfs_vms: 0
+rbd_mirror_vms: 0
+client_vms: 0
+iscsi_gw_vms: 0
+mgr_vms: 0
+
+# SUBNETS TO USE FOR THE VMS
+public_subnet: 192.168.3
+cluster_subnet: 192.168.4
+
+# MEMORY
+# set 1024 for CentOS
+memory: 512
+
+# Ethernet interface name
+# use eth1 for libvirt and ubuntu precise, enp0s8 for CentOS and ubuntu xenial
+eth: 'eth1'
+
+
+# VAGRANT BOX
+# Ceph boxes are *strongly* suggested. They are under better control and will
+# not get updated frequently unless required for build systems. These are (for
+# now):
+#
+# * ceph/ubuntu-xenial
+#
+# Ubuntu: ceph/ubuntu-xenial bento/ubuntu-16.04 or ubuntu/trusty64 or ubuntu/wily64
+# CentOS: bento/centos-7.1 or puppetlabs/centos-7.0-64-puppet
+# libvirt CentOS: centos/7
+# parallels Ubuntu: parallels/ubuntu-14.04
+# Debian: deb/jessie-amd64 - be careful the storage controller is named 'SATA Controller'
+# For more boxes have a look at:
+#   - https://atlas.hashicorp.com/boxes/search?utf8=✓&sort=&provider=virtualbox&q=
+#   - https://download.gluster.org/pub/gluster/purpleidea/vagrant/
+vagrant_box: centos/7
+#ssh_private_key_path: "~/.ssh/id_rsa"
+# The sync directory changes based on vagrant box
+# Set to /home/vagrant/sync for Centos/7, /home/{ user }/vagrant for openstack and defaults to /vagrant
+#vagrant_sync_dir: /home/vagrant/sync
+#vagrant_sync_dir: /
+# Disables synced folder creation. Not needed for testing, will skip mounting
+# the vagrant directory on the remote box regardless of the provider.
+vagrant_disable_synced_folder: true
+# VAGRANT URL
+# This is a URL to download an image from an alternate location.  vagrant_box
+# above should be set to the filename of the image.
+# Fedora virtualbox: https://download.fedoraproject.org/pub/fedora/linux/releases/22/Cloud/x86_64/Images/Fedora-Cloud-Base-Vagrant-22-20150521.x86_64.vagrant-virtualbox.box
+# Fedora libvirt: https://download.fedoraproject.org/pub/fedora/linux/releases/22/Cloud/x86_64/Images/Fedora-Cloud-Base-Vagrant-22-20150521.x86_64.vagrant-libvirt.box
+# vagrant_box_url: https://download.fedoraproject.org/pub/fedora/linux/releases/22/Cloud/x86_64/Images/Fedora-Cloud-Base-Vagrant-22-20150521.x86_64.vagrant-virtualbox.box
diff --git a/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-explicit/Vagrantfile b/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-explicit/Vagrantfile
new file mode 120000 (symlink)
index 0000000..16076e4
--- /dev/null
@@ -0,0 +1 @@
+../../../../Vagrantfile
\ No newline at end of file
diff --git a/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-explicit/group_vars/all b/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-explicit/group_vars/all
new file mode 100644 (file)
index 0000000..0b287c5
--- /dev/null
@@ -0,0 +1,32 @@
+---
+
+ceph_dev: True
+cluster: test
+public_network: "192.168.3.0/24"
+cluster_network: "192.168.4.0/24"
+monitor_interface: eth1
+osd_objectstore: "filestore"
+osd_scenario: lvm
+ceph_origin: 'repository'
+ceph_repository: 'dev'
+copy_admin_key: false
+num_osds: 2
+devices:
+  - /dev/sdb
+  - /dev/sdc
+  - /dev/nvme0n1
+  - /dev/nvme1n1
+os_tuning_params:
+  - { name: kernel.pid_max, value: 4194303 }
+  - { name: fs.file-max, value: 26234859 }
+ceph_conf_overrides:
+  global:
+    osd_pool_default_pg_num: 8
+    osd_pool_default_size: 1
+
+# The following is only needed for testing purposes and is not part of
+# ceph-ansible supported variables
+
+osd_ids:
+  - 0
+  - 1
diff --git a/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-explicit/hosts b/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-explicit/hosts
new file mode 100644 (file)
index 0000000..e1c1de6
--- /dev/null
@@ -0,0 +1,8 @@
+[mons]
+mon0
+
+[osds]
+osd0
+
+[mgrs]
+mon0
diff --git a/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-explicit/setup.yml b/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-explicit/setup.yml
new file mode 120000 (symlink)
index 0000000..8cf11d4
--- /dev/null
@@ -0,0 +1 @@
+../../../playbooks/setup_mixed_type.yml
\ No newline at end of file
diff --git a/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-explicit/test.yml b/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-explicit/test.yml
new file mode 120000 (symlink)
index 0000000..66d44c7
--- /dev/null
@@ -0,0 +1 @@
+../../../playbooks/test_explicit.yml
\ No newline at end of file
diff --git a/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-explicit/test_zap.yml b/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-explicit/test_zap.yml
new file mode 120000 (symlink)
index 0000000..cb969fa
--- /dev/null
@@ -0,0 +1 @@
+../../../playbooks/test_zap.yml
\ No newline at end of file
diff --git a/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-explicit/vagrant_variables.yml b/src/ceph-volume/ceph_volume/tests/functional/batch/centos7/filestore/mixed-type-explicit/vagrant_variables.yml
new file mode 100644 (file)
index 0000000..7d1a444
--- /dev/null
@@ -0,0 +1,56 @@
+---
+
+# DEFINE THE NUMBER OF VMS TO RUN
+mon_vms: 1
+osd_vms: 1
+mds_vms: 0
+rgw_vms: 0
+nfs_vms: 0
+rbd_mirror_vms: 0
+client_vms: 0
+iscsi_gw_vms: 0
+mgr_vms: 0
+
+# SUBNETS TO USE FOR THE VMS
+public_subnet: 192.168.3
+cluster_subnet: 192.168.4
+
+# MEMORY
+# set 1024 for CentOS
+memory: 512
+
+# Ethernet interface name
+# use eth1 for libvirt and ubuntu precise, enp0s8 for CentOS and ubuntu xenial
+eth: 'eth1'
+
+
+# VAGRANT BOX
+# Ceph boxes are *strongly* suggested. They are under better control and will
+# not get updated frequently unless required for build systems. These are (for
+# now):
+#
+# * ceph/ubuntu-xenial
+#
+# Ubuntu: ceph/ubuntu-xenial bento/ubuntu-16.04 or ubuntu/trusty64 or ubuntu/wily64
+# CentOS: bento/centos-7.1 or puppetlabs/centos-7.0-64-puppet
+# libvirt CentOS: centos/7
+# parallels Ubuntu: parallels/ubuntu-14.04
+# Debian: deb/jessie-amd64 - be careful the storage controller is named 'SATA Controller'
+# For more boxes have a look at:
+#   - https://atlas.hashicorp.com/boxes/search?utf8=✓&sort=&provider=virtualbox&q=
+#   - https://download.gluster.org/pub/gluster/purpleidea/vagrant/
+vagrant_box: centos/7
+#ssh_private_key_path: "~/.ssh/id_rsa"
+# The sync directory changes based on vagrant box
+# Set to /home/vagrant/sync for Centos/7, /home/{ user }/vagrant for openstack and defaults to /vagrant
+#vagrant_sync_dir: /home/vagrant/sync
+#vagrant_sync_dir: /
+# Disables synced folder creation. Not needed for testing, will skip mounting
+# the vagrant directory on the remote box regardless of the provider.
+vagrant_disable_synced_folder: true
+# VAGRANT URL
+# This is a URL to download an image from an alternate location.  vagrant_box
+# above should be set to the filename of the image.
+# Fedora virtualbox: https://download.fedoraproject.org/pub/fedora/linux/releases/22/Cloud/x86_64/Images/Fedora-Cloud-Base-Vagrant-22-20150521.x86_64.vagrant-virtualbox.box
+# Fedora libvirt: https://download.fedoraproject.org/pub/fedora/linux/releases/22/Cloud/x86_64/Images/Fedora-Cloud-Base-Vagrant-22-20150521.x86_64.vagrant-libvirt.box
+# vagrant_box_url: https://download.fedoraproject.org/pub/fedora/linux/releases/22/Cloud/x86_64/Images/Fedora-Cloud-Base-Vagrant-22-20150521.x86_64.vagrant-virtualbox.box
diff --git a/src/ceph-volume/ceph_volume/tests/functional/batch/playbooks/test_explicit.yml b/src/ceph-volume/ceph_volume/tests/functional/batch/playbooks/test_explicit.yml
new file mode 100644 (file)
index 0000000..853f6a1
--- /dev/null
@@ -0,0 +1,63 @@
+
+- hosts: osds
+  become: yes
+  tasks:
+
+    - name: stop ceph-osd daemons
+      service:
+        name: "ceph-osd@{{ item }}"
+        state: stopped
+      with_items: "{{ osd_ids }}"
+
+
+- hosts: mons
+  become: yes
+  tasks:
+
+    - name: purge osds
+      command: "ceph --cluster {{ cluster }} osd purge osd.{{ item }} --yes-i-really-mean-it"
+      with_items: "{{ osd_ids }}"
+
+
+- hosts: osds
+  become: yes
+  tasks:
+
+    - name: zap devices used for OSDs
+      command: "ceph-volume --cluster {{ cluster }} lvm zap {{ item }} --destroy"
+      with_items: "{{ devices }}"
+      environment:
+        CEPH_VOLUME_DEBUG: 1
+
+    - name: batch create devices again
+      command: "ceph-volume --cluster {{ cluster }} lvm batch --yes --{{ osd_objectstore|default('bluestore') }} {{ '--dmcrypt' if dmcrypt|default(false) else '' }} {{ devices[:2] | join(' ') }} --db-devices {{ devices[2:] | join(' ') }}"
+      environment:
+        CEPH_VOLUME_DEBUG: 1
+
+    - name: ensure batch create is idempotent
+      command: "ceph-volume --cluster {{ cluster }} lvm batch --yes --{{ osd_objectstore|default('bluestore') }} {{ '--dmcrypt' if dmcrypt|default(false) else '' }} {{ devices[:2] | join(' ') }} --db-devices {{ devices[2:] | join(' ') }}"
+      register: batch_cmd
+      failed_when: false
+      environment:
+        CEPH_VOLUME_DEBUG: 1
+
+    - name: check batch idempotency
+      fail:
+        msg: "lvm batch failed idempotency check"
+      when:
+         - batch_cmd.rc != 0
+         - "'strategy changed' not in batch_cmd.stdout"
+
+    - name: run batch --report to see if devices get filtered
+      command: "ceph-volume --cluster {{ cluster }} lvm batch --report --format=json --{{ osd_objectstore|default('bluestore') }} {{ '--dmcrypt' if dmcrypt|default(false) else '' }} {{ devices[:2] | join(' ') }} --db-devices {{ devices[2:] | join(' ') }}"
+      register: report_cmd
+      failed_when: false
+      environment:
+        CEPH_VOLUME_DEBUG: 1
+
+    - name: check batch --report idempotency
+      fail:
+        msg: "lvm batch --report failed idempotency check"
+      when:
+         - batch_cmd.rc != 0
+         - "'strategy changed' not in batch_cmd.stdout"
index 4c3af68115702ea7e12ef89c8304a50bf9261857..7e1ae2a79ee1dac6cff4f92a75d2ab54d17dc56c 100644 (file)
@@ -1,5 +1,5 @@
 [tox]
-envlist = {centos7,xenial}-{bluestore,filestore}-{single_type,single_type_dmcrypt},centos7-{bluestore,filestore}-{mixed_type, mixed_type_dmcrypt}
+envlist = {centos7,xenial}-{bluestore,filestore}-{single_type,single_type_dmcrypt},centos7-{bluestore,filestore}-{mixed_type,mixed_type_dmcrypt,mixed_type_explicit, mixed_type_dmcrypt_explicit}
 skipsdist = True
 
 [testenv]
@@ -22,17 +22,21 @@ changedir=
   centos7-filestore-single_type_dmcrypt: {toxinidir}/centos7/filestore/single-type-dmcrypt
   centos7-filestore-mixed_type: {toxinidir}/centos7/filestore/mixed-type
   centos7-filestore-mixed_type_dmcrypt: {toxinidir}/centos7/filestore/mixed-type-dmcrypt
+  centos7-filestore-mixed_type_explicit: {toxinidir}/centos7/filestore/mixed-type-explicit
+  centos7-filestore-mixed_type_dmcrypt_explicit: {toxinidir}/centos7/filestore/mixed-type-dmcrypt-explicit
   centos7-bluestore-single_type: {toxinidir}/centos7/bluestore/single-type
   centos7-bluestore-single_type_dmcrypt: {toxinidir}/centos7/bluestore/single-type-dmcrypt
   centos7-bluestore-mixed_type: {toxinidir}/centos7/bluestore/mixed-type
   centos7-bluestore-mixed_type_dmcrypt: {toxinidir}/centos7/bluestore/mixed-type-dmcrypt
+  centos7-bluestore-mixed_type_explicit: {toxinidir}/centos7/bluestore/mixed-type-explicit
+  centos7-bluestore-mixed_type_dmcrypt_explicit: {toxinidir}/centos7/bluestore/mixed-type-dmcrypt-explicit
   xenial-filestore-single_type: {toxinidir}/xenial/filestore/single-type
   xenial-filestore-single_type_dmcrypt: {toxinidir}/xenial/filestore/single-type-dmcrypt
   xenial-bluestore-single_type: {toxinidir}/xenial/bluestore/single-type
   xenial-bluestore-single_type_dmcrypt: {toxinidir}/xenial/bluestore/single-type-dmcrypt
 commands=
   git clone -b {env:CEPH_ANSIBLE_BRANCH:master} --single-branch https://github.com/ceph/ceph-ansible.git {envdir}/tmp/ceph-ansible
-  pip install -r {envdir}/tmp/ceph-ansible/tests/requirements.txt
+  python -m pip install -r {envdir}/tmp/ceph-ansible/tests/requirements.txt
 
   bash {toxinidir}/../scripts/vagrant_up.sh {env:VAGRANT_UP_FLAGS:"--no-provision"} {posargs:--provider=virtualbox}
   bash {toxinidir}/../scripts/generate_ssh_config.sh {changedir}