Project

General

Profile

Bug #23647

katello-remove-orphans in cron.daily can clash with katello-backup

Added by Christine Fouant about 3 years ago. Updated about 3 years ago.

Status:
Closed
Priority:
High
Category:
Backup & Restore
Target version:
Difficulty:
Triaged:
Yes
Bugzilla link:

Description

Cloned from https://bugzilla.redhat.com/show_bug.cgi?id=1478047

Description of problem:

`katello-remove-orphans` and `katello-clean-empty-puppet-environments` can clash with `katello-backup` depending on the schedule, causing incomplete `pulp` backup data being saved away.

We have seen issues, when `katello-backup` and `katello-remove-orphans` run at the same time. It causes `backup_pulp_online` to run multiple times https://github.com/Katello/katello-packaging/blob/KATELLO-3.3/katello/katello-backup#L53 which will produce a almost empty `pulp_data.tar` as `--listed-incremental=.pulp.snar` is used for the first but more important the second run.

Having `katello-remove-orphans` and `katello-clean-empty-puppet-environments` in `cron.d` would allow more flexibility and control when it actually runs. It would also be easier to adjust the timing if clash between `katello-backup` and `katello-remove-orphans` are about to be expected.

Thus changing https://github.com/Katello/katello-packaging/blob/e34a02227e537b293590dc13df06e16ecd4dba76/katello/katello.spec#L84-L85 (including https://github.com/Katello/katello-packaging/blob/e34a02227e537b293590dc13df06e16ecd4dba76/katello/katello.spec#L136-L137) as well as https://github.com/Katello/katello-packaging/blob/e34a02227e537b293590dc13df06e16ecd4dba76/katello/katello-remove-orphans and https://github.com/Katello/katello-packaging/blob/e34a02227e537b293590dc13df06e16ecd4dba76/katello/katello-clean-empty-puppet-environments to actually reflect the requirements and implementation for `cron.d` would be greatly appreciated and add the required/expected flexibility.

Version-Release number of selected component (if applicable):

- katello-common-3.0.0-21.el7sat.noarch

How reproducible:

- Always

Steps to Reproduce:
1. Sync Red Hat and EPEL repository
2. Run katello-backup --online-backup /backup
3. Make sure it runs at the same time when `katello-remove-orphans` is executed via `cron.weekly`

Actual results:

Almost empty `pulp_data.tar` one the backup finished

Expected results:

Full backup of `/var/lib/pulp` to be available

Additional info:

History

#1 Updated by The Foreman Bot about 3 years ago

  • Status changed from New to Ready For Testing
  • Pull request https://github.com/theforeman/foreman-packaging/pull/2505 added

#2 Updated by Jonathon Turel about 3 years ago

  • Legacy Backlogs Release (now unused) set to 338

#3 Updated by The Foreman Bot about 3 years ago

  • Pull request https://github.com/theforeman/foreman-packaging/pull/2644 added

#4 Updated by Justin Sherrill about 3 years ago

  • Triaged set to No
  • Status changed from Ready For Testing to Closed

Also available in: Atom PDF