RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 1841903 - Include Data Maintenance related data in sosreport/foreman-debug
Summary: Include Data Maintenance related data in sosreport/foreman-debug
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: Red Hat Enterprise Linux 8
Classification: Red Hat
Component: sos
Version: 8.3
Hardware: All
OS: Linux
high
high
Target Milestone: rc
: 8.4
Assignee: Pavel Moravec
QA Contact: Upgrades and Supportability
URL:
Whiteboard:
Depends On:
Blocks: 1853235
TreeView+ depends on / blocked
 
Reported: 2020-05-29 18:46 UTC by Mike McCune
Modified: 2021-11-29 07:27 UTC (History)
5 users (show)

Fixed In Version: sos-4.0-2.el8
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 1853235 (view as bug list)
Environment:
Last Closed: 2021-11-29 07:27:04 UTC
Type: Bug
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github sosreport sos pull 2117 0 None closed [foreman] collects stats of some tables from foreman DB 2020-10-29 11:20:46 UTC

Internal Links: 1853235

Description Mike McCune 2020-05-29 18:46:48 UTC
In the KCS here we have common cleanup recommendations:

https://access.redhat.com/solutions/4797161

We unfortunately do not collect the data required to determine if cleanup is required.

We need to add a series of queries and data to every foreman-debug/sosreport:

1) SQL tablesizes: https://github.com/RedHatSatellite/satellite-support/blob/master/postgres-size-report

2) fact_names query:

# su - postgres -c "psql foreman -c \"select name from fact_names;\"" > pg_fact_names.log
# awk -F "::" '{ print $1 }' pg_fact_names.log | sort | uniq -c | sort -nr | head -n5

3) Size of audits, logs and cp_events tables:

su - postgres -c "psql foreman -c \"select count(*) from audits;\"" > audits_table_count.log

su - postgres -c "psql foreman -c \"select count(*) from logs;\"" > logs_table_count.log

su - postgres -c "psql candlepin -c \"select count(*) from cp_event;\"" > cp_event_table_count.log

Comment 1 Mike McCune 2020-05-29 20:46:21 UTC
I realize cp_event is gone in 6.7+ but since sosreport runs on older versions of Satellite there is still value in including this check for our existing 6.6 and prior customers.

Comment 5 Pavel Moravec 2020-06-17 21:21:47 UTC
Thanks for the feedback. I raised https://github.com/sosreport/sos/pull/2117 in sos upstream.

Some subtle changes:
- limit 100 applied to the fact_names query
- cp_events counts not collected (as this wont be backported to 7.9 due to the progress of the release, hence RHEL8 backport only, hence Sat7 only, where the table is missing)
- I named the files to be written as 'audits_table_count', 'logs_table_count' and 'fact_names_prefixes' - neither sounds me like a great name, I would appreciate if one comes with something better
  - see https://github.com/sosreport/sos/pull/2117/files#diff-9417b117c132fe3ae34b5c209183facfR226-R228

Comment 6 Pavel Moravec 2020-07-02 08:24:13 UTC
The fix will be delivered in sosreport, hence reassinging to proper product and component.

Mike, could you please verify the fix, once a candidate build available (I guess once for RHEL7.* and then for 8.4, when Sat will be available there)? To grant OtherQE..

Comment 13 RHEL Program Management 2021-11-29 07:27:04 UTC
After evaluating this issue, there are no plans to address it further or fix it in an upcoming release.  Therefore, it is being closed.  If plans change such that this issue will be fixed in an upcoming release, then the bug can be reopened.


Note You need to log in before you can comment on or make changes to this bug.