ceph-ansible/infrastructure-playbooks
Dimitri Savineau 33f74771d2 switch2container: disable ceph-osd enabled-runtime
When deploying the ceph OSD via the packages then the ceph-osd@.service
unit is configured as enabled-runtime.
This means that each ceph-osd service will inherit from that state.
The enabled-runtime systemd state doesn't survive after a reboot.
For non containerized deployment the OSD are still starting after a
reboot because there's the ceph-volume@.service and/or ceph-osd.target
units that are doing the job.

$ systemctl list-unit-files|egrep '^ceph-(volume|osd)'|column -t
ceph-osd@.service     enabled-runtime
ceph-volume@.service  enabled
ceph-osd.target       enabled

When switching to containerized deployment we are stopping/disabling
ceph-osd@XX.servive, ceph-volume and ceph.target and then removing the
systemd unit files.
But the new systemd units for containerized ceph-osd service will still
inherit from ceph-osd@.service unit file.

As a consequence, if an OSD host is rebooting after the playbook execution
then the ceph-osd service won't come back because they aren't enabled at
boot.

This patch also adds a reboot and testinfra run after running the switch
to container playbook.

Closes: https://bugzilla.redhat.com/show_bug.cgi?id=1881288

Signed-off-by: Dimitri Savineau <dsavinea@redhat.com>
(cherry picked from commit fa2bb3af86)
2020-11-12 21:08:32 +01:00
..
untested-by-ci ansible: use 'bool' filter on boolean conditionals 2019-06-07 16:05:51 +02:00
vars osd: remove variable osd_scenario 2019-04-12 00:45:21 +00:00
README.md doc: update infra playbooks statements 2020-03-16 14:43:35 +01:00
add-mon.yml facts: explicitly disable facter and ohai 2020-07-20 21:23:48 +02:00
add-osd.yml facts: explicitly disable facter and ohai 2020-07-20 21:23:48 +02:00
ceph-keys.yml rename docker_exec_cmd variable 2019-05-17 16:05:58 +02:00
docker-to-podman.yml ceph-crash: introduce new role ceph-crash 2020-09-10 20:35:04 -04:00
filestore-to-bluestore.yml fs2bs: support `osd_auto_discovery` scenario 2020-09-29 10:48:36 -04:00
gather-ceph-logs.yml remove ceph restapi references 2019-06-20 15:15:10 -04:00
lv-create.yml lv-create: fix a typo 2019-09-26 16:21:54 +02:00
lv-teardown.yml improve coding style 2019-05-06 15:09:06 +00:00
purge-cluster.yml purge: remove potential socket leftover 2020-09-14 16:51:00 -04:00
purge-container-cluster.yml purge: remove potential socket leftover 2020-09-14 16:51:00 -04:00
purge-docker-cluster.yml purge: rename playbook (container) 2019-12-04 09:12:41 -05:00
purge-iscsi-gateways.yml purge/update: remove backward compatibility legacy 2020-02-03 09:33:05 -05:00
rgw-add-users-buckets.yml Example ceph_add_users_buckets playbook 2018-12-20 14:23:25 +01:00
rolling_update.yml rolling_update: use ceph health instead of ceph -s 2020-11-03 14:38:49 -05:00
shrink-mds.yml shrink-mds: use mds_to_kill_hostname instead 2020-08-18 15:10:06 -04:00
shrink-mgr.yml shrink-mgr: fix systemd condition 2020-03-03 15:19:45 +01:00
shrink-mon.yml monitor: use quorum_status instead of ceph status 2020-11-03 14:38:49 -05:00
shrink-osd.yml common: don't enable debug log on ceph-volume calls by default 2020-08-13 14:21:44 +02:00
shrink-rbdmirror.yml rgw/rbdmirror: use service dump instead of ceph -s 2020-11-03 14:38:49 -05:00
shrink-rgw.yml rgw/rbdmirror: use service dump instead of ceph -s 2020-11-03 14:38:49 -05:00
storage-inventory.yml common: don't enable debug log on ceph-volume calls by default 2020-08-13 14:21:44 +02:00
switch-from-non-containerized-to-containerized-ceph-daemons.yml switch2container: disable ceph-osd enabled-runtime 2020-11-12 21:08:32 +01:00
take-over-existing-cluster.yml remove ceph-agent role and references 2019-06-17 15:56:00 -04:00

README.md

Infrastructure playbooks

This directory contains a variety of playbooks that can be used independently of the Ceph roles we have. They aim to perform infrastructure related tasks that would help use managing a Ceph cluster or performing certain operational tasks.

To use them, run ansible-playbook infrastructure-playbooks/<playbook>.