Browse Source

Option to remove the self-installed ReaR cron task

By default, the ReaR rpm installs a cronjob on /etc/cron.d/rear with
a default programming. This programming runs a backup job at
1:30AM every day. During this automatic backup, the services are not
appropiately paused. This causes the created backup to have non-valid
data.

As the most recent backup overwrites the older ones, this deletes
the "good" backup taken at operator's discretion with a new one
that cannot be used to restore the control plane state.

This change aims to optionally disable this default rpm behaviour.

Closes-Bug: #1912764
Change-Id: I2582c1ba74ae115a94ecb4524ba34e79ea5b43e8
changes/51/772351/2
Juan Larriba 1 year ago
parent
commit
f0acda953c
  1. 3
      tripleo_ansible/roles/backup_and_restore/defaults/main.yml
  2. 9
      tripleo_ansible/roles/backup_and_restore/tasks/setup_rear.yml

3
tripleo_ansible/roles/backup_and_restore/defaults/main.yml

@ -72,3 +72,6 @@ tripleo_backup_and_restore_ceph_path: "/var/lib/ceph"
# If there is a firewalld active, setup the zone where the NFS server ports need to be opened
tripleo_backup_and_restore_firewalld_zone: "libvirt"
# The ReaR rpm installs a cronjob at 1:30 each day by default. This variable deactivate that behaviour.
tripleo_backup_and_restore_remove_default_cronjob: true

9
tripleo_ansible/roles/backup_and_restore/tasks/setup_rear.yml

@ -40,6 +40,15 @@
tags:
- bar_setup_rear
- name: Remove ReaR rpm default cron programming
become: true
file:
path: /etc/cron.d/rear
state: absent
when: tripleo_backup_and_restore_remove_default_cronjob | bool
tags:
- bar_setup_rear
- name: Get local hostname
command: hostname
register: tripleo_backup_and_restore_hostname

Loading…
Cancel
Save