mirror of https://github.com/ceph/ceph-ansible.git
cephadm_adopt: fetch and write ceph minimal config
This commit makes the playbook fetch the minimal current ceph
configuration and write it later on monitoring nodes so `cephadm` can
proceed with the adoption.
When a monitoring stack was deployed on a dedicated node, it means no
`ceph.conf` file was written, `cephadm` requires a `ceph.conf` in order
to adopt the daemon present on the node.
Closes: https://bugzilla.redhat.com/show_bug.cgi?id=1939887
Signed-off-by: Guillaume Abrioux <gabrioux@redhat.com>
(cherry picked from commit b445df0479
)
pull/6400/head
parent
80bf7030f7
commit
f42ee9f940
|
@ -118,6 +118,8 @@
|
|||
serial: 1
|
||||
become: True
|
||||
tasks:
|
||||
- name: upgrade ceph mon cluster
|
||||
block:
|
||||
- name: remove ceph aliases
|
||||
file:
|
||||
path: /etc/profile.d/ceph-aliases.sh
|
||||
|
@ -256,6 +258,22 @@
|
|||
delay: "{{ health_mon_check_delay }}"
|
||||
when: containerized_deployment | bool
|
||||
|
||||
rescue:
|
||||
- name: unmask the mon service
|
||||
systemd:
|
||||
name: ceph-mon@{{ item }}
|
||||
enabled: yes
|
||||
masked: no
|
||||
with_items:
|
||||
- "{{ ansible_facts['hostname'] }}"
|
||||
- "{{ ansible_facts['fqdn'] }}"
|
||||
|
||||
- name: unmask the mgr service
|
||||
systemd:
|
||||
name: ceph-mgr@{{ ansible_facts['hostname'] }}
|
||||
masked: no
|
||||
when: inventory_hostname in groups[mgr_group_name] | default([])
|
||||
or groups[mgr_group_name] | default([]) | length == 0
|
||||
|
||||
- name: reset mon_host
|
||||
hosts: "{{ mon_group_name|default('mons') }}"
|
||||
|
|
Loading…
Reference in New Issue