From 70e2787fe2970f4e255d013cd51658ebf3125ea3 Mon Sep 17 00:00:00 2001 From: Guillaume Abrioux Date: Wed, 4 Oct 2017 23:10:10 +0200 Subject: [PATCH 1/3] docker: fix keyrings copied on all nodes All keyring are getting copied to all nodes. This commit fixes a leftover from a previous code refactor. Closes: https://bugzilla.redhat.com/show_bug.cgi?id=1498583 Signed-off-by: Guillaume Abrioux --- .../ceph-docker-common/tasks/create_configs.yml | 1 - .../ceph-docker-common/tasks/fetch_configs.yml | 17 ----------------- roles/ceph-docker-common/tasks/main.yml | 3 --- roles/ceph-mon/tasks/docker/copy_configs.yml | 1 - .../ceph-nfs/tasks/pre_requisite_container.yml | 1 - roles/ceph-osd/tasks/copy_configs.yml | 6 +++--- 6 files changed, 3 insertions(+), 26 deletions(-) delete mode 100644 roles/ceph-docker-common/tasks/create_configs.yml delete mode 100644 roles/ceph-docker-common/tasks/fetch_configs.yml diff --git a/roles/ceph-docker-common/tasks/create_configs.yml b/roles/ceph-docker-common/tasks/create_configs.yml deleted file mode 100644 index ed97d539c..000000000 --- a/roles/ceph-docker-common/tasks/create_configs.yml +++ /dev/null @@ -1 +0,0 @@ ---- diff --git a/roles/ceph-docker-common/tasks/fetch_configs.yml b/roles/ceph-docker-common/tasks/fetch_configs.yml deleted file mode 100644 index cd186a5c7..000000000 --- a/roles/ceph-docker-common/tasks/fetch_configs.yml +++ /dev/null @@ -1,17 +0,0 @@ ---- -- name: include stat_ceph_files.yml - include: stat_ceph_files.yml - -- name: try to fetch ceph config and keys - copy: - src: "{{ fetch_directory }}/{{ fsid }}/{{ item.0 }}" - dest: "{{ item.0 }}" - owner: root - group: root - mode: 0600 - changed_when: false - with_together: - - "{{ ceph_config_keys }}" - - "{{ statconfig.results | default([]) }}" - when: - - item.1.stat.exists == true diff --git a/roles/ceph-docker-common/tasks/main.yml b/roles/ceph-docker-common/tasks/main.yml index c27a6791d..81e95704b 100644 --- a/roles/ceph-docker-common/tasks/main.yml +++ b/roles/ceph-docker-common/tasks/main.yml @@ -104,9 +104,6 @@ - name: include dirs_permissions.yml include: dirs_permissions.yml -- name: include create_configs.yml - include: create_configs.yml - - name: include selinux.yml include: selinux.yml when: diff --git a/roles/ceph-mon/tasks/docker/copy_configs.yml b/roles/ceph-mon/tasks/docker/copy_configs.yml index 2e04a94cf..dad616f61 100644 --- a/roles/ceph-mon/tasks/docker/copy_configs.yml +++ b/roles/ceph-mon/tasks/docker/copy_configs.yml @@ -8,7 +8,6 @@ - /var/lib/ceph/bootstrap-osd/{{ cluster }}.keyring - /var/lib/ceph/bootstrap-rgw/{{ cluster }}.keyring - /var/lib/ceph/bootstrap-mds/{{ cluster }}.keyring - - /var/lib/ceph/bootstrap-rbd/{{ cluster }}.keyring - name: register rbd bootstrap key set_fact: diff --git a/roles/ceph-nfs/tasks/pre_requisite_container.yml b/roles/ceph-nfs/tasks/pre_requisite_container.yml index 2b3e52312..3ee0e94fb 100644 --- a/roles/ceph-nfs/tasks/pre_requisite_container.yml +++ b/roles/ceph-nfs/tasks/pre_requisite_container.yml @@ -2,7 +2,6 @@ - name: set config and keys paths set_fact: ceph_config_keys: - - /etc/ceph/{{ cluster }}.client.admin.keyring - /var/lib/ceph/bootstrap-rgw/{{ cluster }}.keyring - name: stat for config and keys diff --git a/roles/ceph-osd/tasks/copy_configs.yml b/roles/ceph-osd/tasks/copy_configs.yml index 93572b75c..616e6d28c 100644 --- a/roles/ceph-osd/tasks/copy_configs.yml +++ b/roles/ceph-osd/tasks/copy_configs.yml @@ -5,7 +5,7 @@ - /var/lib/ceph/bootstrap-osd/{{ cluster }}.keyring - name: wait for ceph.conf and keys - local_action: wait_for path={{ fetch_directory }}/{{ fsid }}/{{ item.0 }} + local_action: wait_for path={{ fetch_directory }}/{{ fsid }}/{{ item }} become: false with_items: "{{ ceph_config_keys }}" @@ -20,8 +20,8 @@ - name: try to copy ceph config and keys copy: - src: "{{ fetch_directory }}/{{ fsid }}/{{ item.0 }}" - dest: "{{ item.0 }}" + src: "{{ fetch_directory }}/{{ fsid }}/{{ item }}" + dest: "{{ item }}" owner: root group: root mode: 0644 From 4135091c9852b00d2f2dbb7ef6e11cdc0783da52 Mon Sep 17 00:00:00 2001 From: Guillaume Abrioux Date: Thu, 5 Oct 2017 11:03:41 +0200 Subject: [PATCH 2/3] tests: fix broken osd test for xenial_cluster the path `/dev/disk/by-path/pci-0000:00:01.1-ata-1.0` doesn't exist. it has to be changed to `/dev/disk/by-path/pci-0000:00:01.1-ata-1` Signed-off-by: Guillaume Abrioux --- tests/functional/ubuntu/16.04/cluster/group_vars/all | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/functional/ubuntu/16.04/cluster/group_vars/all b/tests/functional/ubuntu/16.04/cluster/group_vars/all index d189e1eca..9548e2293 100644 --- a/tests/functional/ubuntu/16.04/cluster/group_vars/all +++ b/tests/functional/ubuntu/16.04/cluster/group_vars/all @@ -9,7 +9,7 @@ monitor_interface: eth1 radosgw_interface: eth1 journal_size: 100 devices: - - '/dev/disk/by-path/pci-0000:00:01.1-ata-1.0' + - '/dev/disk/by-path/pci-0000:00:01.1-ata-1' - '/dev/sdb' dedicated_devices: - '/dev/sdc' From 635111bf6a40741de18216546c7b5df40a4dac85 Mon Sep 17 00:00:00 2001 From: Guillaume Abrioux Date: Thu, 5 Oct 2017 12:59:29 +0200 Subject: [PATCH 3/3] tests: add ceph-override.json for ubuntu/cluster in addition to 18e2ab4d this commit adds the same file for ubuntu testing scenario. Signed-off-by: Guillaume Abrioux --- tests/functional/ubuntu/16.04/cluster/ceph-override.json | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100644 tests/functional/ubuntu/16.04/cluster/ceph-override.json diff --git a/tests/functional/ubuntu/16.04/cluster/ceph-override.json b/tests/functional/ubuntu/16.04/cluster/ceph-override.json new file mode 100644 index 000000000..9a3af9436 --- /dev/null +++ b/tests/functional/ubuntu/16.04/cluster/ceph-override.json @@ -0,0 +1,7 @@ +{ + "ceph_conf_overrides": { + "global": { + "osd_pool_default_pg_num": 12 + } + } +}