Project

General

Profile

Actions

Feature #17398

closed

Fix counts while upgrading Satellite

Added by Stephen Benjamin almost 8 years ago. Updated about 6 years ago.

Status:
Rejected
Priority:
Low
Assignee:
-
Category:
Installer
Target version:
Difficulty:
Triaged:
Fixed in Releases:
Found in Releases:

Description

Cloned from https://bugzilla.redhat.com/show_bug.cgi?id=1395797
Description of problem:
It seems that in older version of Satellite, a situation could create a negative count , and this negative counts still persist after upgrading. It can be fix manually by running this:
  1. foreman-rake fix_cached_counters

As a RFE, this actions could be done when upgrading, or in a cron managed by Satellite.

Steps to Reproduce:
1.Modify the count from the database via foreman db, example:
update operatingsystems SET hosts_count = hosts_count -1 WHERE id = '2';

2. Validation the wrong count though the WebUI
Hosts > Operating Systems
Under "Hosts" column, the negative "-1" should be seen
3. Run this command
  1. foreman-rake fix_cached_counters

4. Count in the database and webui will now display to good number.

Expected results:
Have an automated process that fix the counters via cron or uprade process.

Actions

Also available in: Atom PDF