Bug 1591908
| Summary: | [RFE] remove cp_event table, collection and Change endpoints that return events to return empty lists. | ||||||
|---|---|---|---|---|---|---|---|
| Product: | Red Hat Satellite | Reporter: | Mike McCune <mmccune> | ||||
| Component: | Candlepin | Assignee: | Eko <hsun> | ||||
| Status: | CLOSED ERRATA | QA Contact: | Eko <hsun> | ||||
| Severity: | high | Docs Contact: | |||||
| Priority: | high | ||||||
| Version: | Unspecified | CC: | andrew.schofield, bcourt, bkearney, ekirby, fgarciad, hsun, janarula, khowell, ktordeur, mcorr, molasaga, nmoumoul, pcreech, pgervase, rjerrido, spetrosi, sthirugn, wpinheir | ||||
| Target Milestone: | 6.7.0 | Keywords: | FutureFeature, PrioBumpField, Triaged | ||||
| Target Release: | Unused | ||||||
| Hardware: | Unspecified | ||||||
| OS: | Unspecified | ||||||
| Whiteboard: | |||||||
| Fixed In Version: | candlepin-2.7.1-1 | Doc Type: | Removed functionality | ||||
| Doc Text: |
To improve performance and prevent the storage of unnecessary data, which led to reported problems with disk overflow, the `cp_events` table has been removed from the Candlepin database. The corresponding *Events* tab that was located in the Satellite web UI at *Hosts* > *Content Hosts* > *_hostname_* > *Subscriptions* has been removed.
|
Story Points: | --- | ||||
| Clone Of: | |||||||
| : | 1698614 (view as bug list) | Environment: | |||||
| Last Closed: | 2020-04-14 13:22:58 UTC | Type: | Bug | ||||
| Regression: | --- | Mount Type: | --- | ||||
| Documentation: | --- | CRM: | |||||
| Verified Versions: | Category: | --- | |||||
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||
| Cloudforms Team: | --- | Target Upstream Version: | |||||
| Embargoed: | |||||||
| Bug Depends On: | 1698614, 1709892 | ||||||
| Bug Blocks: | 1545876 | ||||||
| Attachments: |
|
||||||
WORKAROUND: This will delete all data older than 14 days as anything beyond a week isn't needed. # echo "delete from cp_event where timestamp < now() - interval '14 days';" | sudo -u postgres psql -d candlepin ADDITIONAL WORKAROUND: This will setup a weekly cron to ensure continuous cleanup. 1) Download cp_event_cleanup from this Bugzilla 2) Copy to /etc/cron.weekly/ 3) chmod +x /etc/cron.weekly/cp_event_cleanup Created attachment 1482482 [details]
cp_event_cleanup
Kevin, Rich, Lets get rid of this data entirely. It is not valuable or worth collecting and setting up policy on retention. All, I reworded this RFE to state our intentions to just cease collection of the data in the cp_event table and also remove any functionality in the Satellite 6 UI that references the Events tab in the Content Host UI. Assigning the bug to me since I'm the owner for aha card: SAT-E-342, 343. According to the comments in aha card, the first part of this feature can be verified: SAT-E-342: Upgrade Sat6.5 to Sat6.6 [VERIFIED] 1). The 'cp_event' table is still existing, but it will stop writing new data to the table. 2). The 'Events' element is still existing in WebUI, but the table is null. The second part of this feature is still developing (SAT-E-343) [Ready to develop] Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHSA-2020:1454 |
This table grows unbound over time resulting in gigabytes of largely unecessary data. From an example customer who has a 2Y old Satellite installation with 20,000 consumers/hosts table_name | total | index | toast | table --------------------------------+------------+------------+------------+------------ cp_event | 12 GB | 5682 MB | 8192 bytes | 6484 MB select count(*) from cp_event; count ---------- 25,017,125 We need a policy and procedure in place to delete anything in this table over ~7 Days (or configurable value) as it is no longer something that needs to be stored.