From a98ae5d88d3aba2d3e11f540a6b9d759308231a5 Mon Sep 17 00:00:00 2001 From: Alfredo Deza Date: Mon, 10 Dec 2018 14:38:02 -0500 Subject: [PATCH] ceph-volume tests.functional set root:root in OSDs in bluestore To make sure that ceph-volume will be able to set the right permissions when trying to activate Signed-off-by: Alfredo Deza (cherry picked from commit 98631fdeeb6dbe765d3eb80c5c1800946735f2a2) --- .../lvm/playbooks/test_bluestore.yml | 31 +++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/src/ceph-volume/ceph_volume/tests/functional/lvm/playbooks/test_bluestore.yml b/src/ceph-volume/ceph_volume/tests/functional/lvm/playbooks/test_bluestore.yml index 1828a1525aac..353df127cb75 100644 --- a/src/ceph-volume/ceph_volume/tests/functional/lvm/playbooks/test_bluestore.yml +++ b/src/ceph-volume/ceph_volume/tests/functional/lvm/playbooks/test_bluestore.yml @@ -62,6 +62,37 @@ environment: CEPH_VOLUME_DEBUG: 1 + - name: find all OSD directories + find: + paths: /var/lib/ceph/osd + recurse: no + file_type: directory + register: osd_directories + + - name: find all OSD symlinks + find: + paths: /var/lib/ceph/osd + recurse: yes + depth: 2 + file_type: link + register: osd_symlinks + + # set the OSD dir and the block/block.db links to root:root permissions, to + # ensure that the OSD will be able to activate regardless + - file: + path: "{{ item.path }}" + owner: root + group: root + with_items: + - "{{ osd_directories.files }}" + + - file: + path: "{{ item.path }}" + owner: root + group: root + with_items: + - "{{ osd_symlinks.files }}" + - name: activate all to start the previously prepared osd.0 command: "ceph-volume lvm activate --all" environment: -- 2.47.3