To make sure that ceph-volume will be able to set the right permissions
when trying to activate
Signed-off-by: Alfredo Deza <adeza@redhat.com>
(cherry picked from commit
503396f685f6a93e0c63e97477677b7145f96c26)
environment:
CEPH_VOLUME_DEBUG: 1
+ - name: find all OSD paths
+ find:
+ paths: /var/lib/ceph/osd
+ recurse: no
+ file_type: directory
+ register: osd_paths
+
+ # set all OSD paths to root:rootto ensure that the OSD will be able to
+ # activate regardless
+ - name: mangle permissions to root
+ file:
+ path: "{{ item.path }}"
+ owner: root
+ group: root
+ recurse: yes
+ with_items:
+ - "{{ osd_paths.files }}"
+
- name: activate all to start the previously prepared osd.0
command: "ceph-volume lvm activate --filestore --all"
environment: